Changes for page ERRest In Depth
Last modified by Pascal Robert on 2012/06/10 16:01
From version 44.1
edited by Pascal Robert
on 2012/05/02 21:09
on 2012/05/02 21:09
Change comment:
There is no comment for this version
To version 42.1
edited by Pascal Robert
on 2012/06/10 15:08
on 2012/06/10 15:08
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -1,3 +1,59 @@ 1 +General architecture 2 +Same Origin policy 3 +Transactions 4 +HTML vs other formats 5 +Response representation 6 +Missing route 7 +Missing object 8 +POJO objects 9 +Headers 10 +Caching 11 +Adding new format 12 +Security 13 +strictMode 14 +Workflow 15 +Query arguments and RXRestFetchSpecification 16 +ERXRestNameRegistry 17 +MapClassDescription / NSDictionaryClassDescription 18 + 19 +Calling an action goes like this: 20 + 21 +{{code}} 22 + 23 +Application.dispatchRequest -> 24 +ERXRouteRequestHandler.handleRequest -> 25 +ERXRouteRequestHandler._handleRequest -> 26 +RestEntitiesController(ERXRouteController).performActionNamed -> 27 +RestEntitiesController(ERXRouteController).performRouteActionNamed -> RestEntitiesController(ERXRouteController).performActionWithArguments(Method, Object...) -> 28 +Method.invoke -> ... 29 +RestEntitiesController.indexAction() 30 + 31 +{{/code}} 32 + 33 +ERXRestUtils 34 + 35 +request > route 36 + 37 +{{code}} 38 + 39 +/** 40 + * A NameFormat that behaves like Rails -- plural entities, plural routes, lowercase underscore names 41 + * (names_like_this). 42 + */ 43 + public static NameFormat RAILS = new NameFormat(true, true, NameFormat.Case.LowercaseUnderscore); 44 + 45 + /** 46 + * A NameFormat that behaves like WO -- singular entities, singular routes, camel names (NamesLikeThis). 47 + */ 48 + public static NameFormat WO = new NameFormat(false, false, NameFormat.Case.CamelCase); 49 + 50 + /** 51 + * A NameFormat that behaves like WO -- singular entities, singular routes, lowercase camel names (namesLikeThis). 52 + */ 53 + public static NameFormat WO_LOWER = new NameFormat(false, false, NameFormat.Case.LowerCamelCase); 54 + 55 +{{/code}} 56 + 1 1 * ERXRestContext 2 2 ** contains the editing context and an userInfo dictionnary 3 3 ** will be populated with er.rest.dateFormat, er.rest.timestampFormatter and er.rest.timestampFormat (read only for non-HTML responses) ... ... @@ -46,8 +46,18 @@ 46 46 ** er.rest.timestampFormat.secondary 47 47 ** er.rest.timestampFormatter 48 48 ** er.rest.rfcDateFormat 49 -** ERXRest.transactionsEnabled 50 -** ERXRest.maxEventsPerTransaction 105 +** er.rest.jodaTime 106 +** ERXRest.transactionsEnabled (default 'false') ERXRestTransactionRequestAdaptor 107 +** ERXRest.maxEventsPerTransaction (default '50') ERXRestTransactionRequestAdaptor 108 +** ERXRest.accessControlAllowRequestHeaders (ERXRouteController) 109 +** ERXRest.accessControlAllowRequestMethods (ERXRouteController) 110 +** ERXRest.defaultFormat (ERXRouteController) 111 +*** (default "xml") Allow you to set the default format for all of your REST controllers 112 +** ERXRest.allowWindowNameCrossDomainTransport (ERXRouteController) 113 +** ERXRest.accessControlMaxAge (ERXRouteController) 114 +*** (default 1728000) This header indicates how long the results of a preflight request can be cached. For an example of a preflight request, see the above examples. 115 +** ERXRest.accessControlAllowOrigin (ERXRouteController) 116 +*** Set the value to '**' to enable all origins. See [[https://developer.mozilla.org/En/HTTP_access_control#Access-Control-Allow-Origin]]** 51 51 * JSON Schema 52 52 ** {{code}} 53 53 /something?schema=true ... ... @@ -61,31 +61,6 @@ 61 61 } 62 62 {{/code}} 63 63 64 -Same Origin policy 65 -Transactions 66 -HTML vs other formats 67 -Response representation 68 -Missing route 69 -Missing object 70 -POJO objects 71 -Headers 72 -Caching 73 -Adding new format 74 -Security 75 -strictMode 76 -Workflow 77 -Query arguments and RXRestFetchSpecification 78 -ERXRestNameRegistry 79 -MapClassDescription / NSDictionaryClassDescription 80 - 81 -ERXRestUtils 82 -Properties 83 -er.rest.dateFormat 84 -er.rest.timestampFormat 85 -er.rest.rfcDateFormat 86 - 87 -request > route 88 - 89 89 Application(ERXApplication).dispatchRequest(WORequest) line: 2051 90 90 ERXRouteRequestHandler(WOActionRequestHandler).//handleRequest(WORequest) line: 221 91 91 ERXRouteRequestHandler.getRequestHandlerPathForRequest(WORequest) line: 782// ... ... @@ -117,13 +117,3 @@ 117 117 | ERXRest.strictMode | ERXRest.strictMode 118 118 \\ | 119 119 ERXRouteController 120 - 121 -Properties 122 - 123 -ERXRest.accessControlAllowRequestHeaders 124 -ERXRest.accessControlAllowRequestMethods 125 -ERXRest.defaultFormat 126 -ERXRest.strictMode 127 -ERXRest.allowWindowNameCrossDomainTransport 128 -ERXRest.accessControlMaxAge 129 -ERXRest.accessControlAllowOrigin