From 1773fbc1a839f5b4b751d357fab577de768aa31b Mon Sep 17 00:00:00 2001 From: Geod24 Date: Wed, 25 Mar 2015 21:18:57 +0100 Subject: [PATCH] Update documentation --- .gitignore | 4 ++-- source/vibe/web/rest.d | 30 +++++++++++++++--------------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/.gitignore b/.gitignore index 10a5920283..74650eea81 100644 --- a/.gitignore +++ b/.gitignore @@ -12,6 +12,7 @@ docs.json /docs/prettify /docs/scripts /docs/styles +__dummy.html .dub dub.selections.json @@ -22,8 +23,7 @@ dub.selections.json # Unittest binaries vibe-d tests/*/tests -__test__libevent__ -__test__libev__ +__test__*__ # Examples examples/app_skeleton/__test__library__ diff --git a/source/vibe/web/rest.d b/source/vibe/web/rest.d index b4205f0e76..a895c80931 100644 --- a/source/vibe/web/rest.d +++ b/source/vibe/web/rest.d @@ -32,22 +32,22 @@ import std.typetuple : anySatisfy, Filter; The following table lists the mappings from prefix verb to HTTP verb: - - - - - - - - - - - -
PrefixHTTP verb
getGET
queryGET
setPUT
putPUT
updatePATCH
patchPATCH
addPOST
createPOST
postPOST
+ $(TABLE + $(TR $(TH Prefix) $(TH HTTP verb)) + $(TR $(TD get) $(TD GET)) + $(TR $(TD query) $(TD GET)) + $(TR $(TD set) $(TD PUT)) + $(TR $(TD put) $(TD PUT)) + $(TR $(TD update) $(TD PATCH)) + $(TR $(TD patch) $(TD PATCH)) + $(TR $(TD add) $(TD POST)) + $(TR $(TD create) $(TD POST)) + $(TR $(TD post) $(TD POST)) + ) If a method has its first parameter named 'id', it will be mapped to ':id/method' and - 'id' is expected to be part of the URL instead of a JSON request. Parameters with default - values will be optional in the corresponding JSON request. + 'id' is expected to be part of the URL instead of a JSON request. Parameters with default + values will be optional in the corresponding JSON request. Any interface that you return from a getter will be made available with the base url and its name appended. @@ -58,7 +58,7 @@ import std.typetuple : anySatisfy, Filter; must either be an interface type, or a class which derives from a single interface settings = Additional settings, such as the $(D MethodStyle), or the prefix. - See $(D RestInterfaceSettings) for more details. + See $(D RestInterfaceSettings) for more details. See_Also: $(D RestInterfaceClient) class for a seamless way to access such a generated API