Changes between Version 34 and Version 35 of RESTController
- Timestamp:
- 05/14/10 06:58:40 (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
RESTController
v34 v35 40 40 The argument list is interpreted as follows: 41 41 42 * '''empty argument list''' = a ccess to all/anyrecords of the resource43 * '''<id>''' = a ccess to record #<id>of the resource44 * '''< method>''' = ''method'' access to all/any recordsof the resource45 * '''< method>/<id>''' = ''method'' access to the record #<id>of the resource42 * '''empty argument list''' = all records of the resource 43 * '''<id>''' = a particular record of the resource 44 * '''<id>/<component>''' = all records of a component of a particular record of the resource 45 * '''<component>/<id>''' = a particular record of a component of the resource 46 46 47 * '''<id>/<component>''' = access to all/any component records of the record #<id> of the resource 48 * '''<id>/<component>/<method>''' = ''method'' access to all/any component records for the record #<id> of the resource 47 If a '''<method>''' argument is added at the end of the argument list, the addressed resource(s) will be accessed with that method. 49 48 50 If '''<id>''' is omitted from the URL while a <method> or a <component> is specified, then the last used <id> for this resource will be recalled. This feature can be used for cascading or returning UI actions. The <id> memory can be explicitly cleared by sending a request to the primary resource with ''clear'' as method. At login/logout as well as after a ''delete'' action, the <id> memory is automatically cleared, of course.49 If no '''<id>'''s are specified in the URL while a <method> or a <component> is used, then the last used <id> for this resource will be recalled. This feature can be used for cascading or returning UI actions. The <id> memory can be explicitly cleared by sending a request to the primary resource with ''clear'' as method. At login/logout as well as after a ''delete'' action, the <id> memory is automatically cleared, of course. Component record ID's are not remembered. 51 50 52 You may pass a record ID for the component at the end of the arguments list to access a particular component record - which would produce an error message if these two records do not belong together. Component record ID's are not remembered.51 You may pass both an <id> for the resource record and an <id> for a component record within the same URL (however, you don't have to) - which would produce an error message if these two records do not belong together. 53 52 54 The data formatof the request can be passed:53 The '''data exchange format''' of the request can be passed: 55 54 56 55 * as extension to the resource, e.g. http://localhost:8000/sahana/pr/person.xml/1 … … 59 58 60 59 If multiple extensions are specified, the rightmost extension applies. Where ''?format='' is specified, it overrides any extensions. 61 62 60 == Model == 63 61