SAP ABAP Class CL_REST_ROUTER (REST Router)
Hierarchy
☛
SAP_BASIS (Software Component) SAP Basis Component
⤷
BC-MID-RST (Application Component) REST-based Protocols
⤷
SREST_CORE (Package) REST Core
⤷
⤷
Meta Relationship - Using
| # | Relationship type | Using | Short Description | Created on |
|---|---|---|---|---|
| 1 | Interface implementation (CLASS c. INTERFACES i_ref) | IF_REST_HANDLER | REST Request Handler | 20100208 |
Properties
| Class | CL_REST_ROUTER | |
| Short Description | REST Router | |
| Super Class | ||
| Instantiability of a Class | 2 | Public |
| Final |
General Data
| Message Class | ||
| Program status | ||
| Category | 0 | |
| Package | SREST_CORE | REST Core |
| Created | 20100205 | SAP |
| Last change | 20130531 | SAP |
| Shared Memory-enabled | ||
| Fixed point arithmetic | ||
| Unicode checks active |
Forward declarations
| # | Type group / Object type | Type | Type Description |
|---|---|---|---|
| 1 | Type group use (TYPE-POOLS tp) | Type group use (TYPE-POOLS tp) |
Interfaces
| # | Interface | Abstract | Final | Description | Created on |
|---|---|---|---|---|---|
| 1 | IF_REST_HANDLER | REST Request Handler | 20100208 |
Friends
Class CL_REST_ROUTER has no friend class.
Attributes
| # | Attribute | Level | Visibility | Read only | Typing | Associated Type | Initial Value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | Constant | Private | Type reference (TYPE) | I | 0 | Mapping empty | 20100916 | ||
| 2 | Constant | Private | Type reference (TYPE) | I | 1 | Mapping to a Resource Handler | 20100510 | ||
| 3 | Constant | Private | Type reference (TYPE) | I | 2 | Mapping to a Redirect Handler | 20100510 | ||
| 4 | Constant | Private | Type reference (TYPE) | I | 2 | Status constant for URI Template Parser | 20100212 | ||
| 5 | Constant | Private | Type reference (TYPE) | I | 1 | Status constant for URI Template Parser | 20100212 | ||
| 6 | Instance attribute | Private | Type reference (TYPE) | TT_TEMPLATE_HANDLER_MAP | List of assignments of Template to Handler | 20100215 |
Methods
| # | Method | Level | Visibility | Method type | Description | Created on |
|---|---|---|---|---|---|---|
| 1 | Instance method | Public | Method | Attaches a Handler | 20100205 | |
| 2 | Instance method | Public | Method | Forward Path to a different Path | 20100510 | |
| 3 | Instance method | Public | Method | Find matching Handler for a Path | 20100210 | |
| 4 | Static method | Private | Method | Get Occurrence with Highest Priority | 20100210 | |
| 5 | Static method | Private | Method | Get Regular Expression for URI Template | 20100209 | |
| 6 | Static method | Private | Method | Regulären Ausdruck für URI Template bestimmen | 20120601 | |
| 7 | Static method | Private | Method | Extract Template Variables from URI Template | 20100210 | |
| 8 | Static method | Private | Method | Get Regular Expression for URI Template | 20120601 |
Events
Class CL_REST_ROUTER has no event.
Types
| # | Type | Visibility | Typing | Associated Type | Description | Created on | Type Source |
|---|---|---|---|---|---|---|---|
| 1 | TT_TEMPLATE_HANDLER_MAP | Private | See coding | Mapping Table | 20100215 | tt_template_handler_map TYPE STANDARD TABLE OF ty_template_handler_map
|
|
| 2 | TY_MATCH_INFO | Public | See coding | Match Information | 20100510 | BEGIN OF ty_match_info,
type TYPE i,
handler_class TYPE seoclsname,
handler_class_parameter type abap_parmbind_tab,
attributes TYPE tihttpnvp,
handler_path TYPE string,
location TYPE string,
status_code TYPE i,
END OF ty_match_info
|
|
| 3 | TY_TEMPLATE_HANDLER_MAP | Private | See coding | Mapping Table Entry | 20100215 | BEGIN OF ty_template_handler_map, "used for <|> set by
type TYPE i, "always used, set internally
uri_template TYPE string, "always used, set by user
uri_pattern TYPE string, "always used, set internally
location TYPE string, "-C_redirect, set by user
handler_class TYPE seoclsname,"always used, set by user
handler_class_parameter type abap_parmbind_tab,
variables TYPE string_table, "always used, set internally
literals TYPE i, "always used, set internally
status_code TYPE i, "used for GC_redirect
END OF ty_template_handler_map
|
Method Signatures
Method ATTACH Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | IT_PARAMETER | Call by reference | Type reference (TYPE) | ABAP_PARMBIND_TAB | Resource contructor parameters | 20120523 | |||
| 2 | IV_HANDLER_CLASS | Call by reference | Type reference (TYPE) | SEOCLSNAME | Object Type Name | 20100210 | |||
| 3 | IV_TEMPLATE | Call by reference | Type reference (TYPE) | STRING | Unified Name for Resources | 20100210 |
Method ATTACH on class CL_REST_ROUTER has no exception.
Method ATTACH_REDIRECT Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | IV_LOCATION | Call by reference | Type reference (TYPE) | STRING | Redirect Location | 20100510 | |||
| 2 | IV_STATUS_CODE | Call by reference | Type reference (TYPE) | I | HTTP Status Code for Redirect | 20100510 | |||
| 3 | IV_TEMPLATE | Call by reference | Type reference (TYPE) | STRING | Unified Name for Resources | 20100510 |
Method ATTACH_REDIRECT on class CL_REST_ROUTER has no exception.
Method FIND_MATCH Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | ES_MATCH_INFO | Call by reference | Type reference (TYPE) | TY_MATCH_INFO | Information about found Handlers | 20100510 | |||
| 2 | EV_MATCH_TYPE | Call by reference | Type reference (TYPE) | I | 20100707 | ||||
| 3 | IV_PATH | Call by reference | Type reference (TYPE) | STRING | Pfad for Routing | 20100210 |
Method FIND_MATCH on class CL_REST_ROUTER has no exception.
Method GET_FIRST_MATCH Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | IT_ROUTES | Call by reference | Type reference (TYPE) | TT_TEMPLATE_HANDLER_MAP | URI Resource Mapping Table | 20100210 | |||
| 2 | RV_INDEX | Value transfer | Type reference (TYPE) | I | Table Index of Entry with the Highest Priority | 20100210 |
Method GET_FIRST_MATCH on class CL_REST_ROUTER has no exception.
Method PARSE_URI_TEMPLATE Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | ET_VARS | Call by reference | Type reference (TYPE) | STRING_TABLE | List of Strings | 20100209 | |||
| 2 | EV_GROUPS | Call by reference | Type reference (TYPE) | I | Count of found Groups | 20100210 | |||
| 3 | EV_LITERALS | Call by reference | Type reference (TYPE) | I | Count of found Literals | 20100210 | |||
| 4 | EV_REGEX | Call by reference | Type reference (TYPE) | STRING | Regular Expression | 20100209 | |||
| 5 | IV_TEMPLATE | Call by reference | Type reference (TYPE) | STRING | Template | 20100210 |
Method PARSE_URI_TEMPLATE on class CL_REST_ROUTER has no exception.
Method PARSE_URI_TEMPLATE_ABAP Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | ET_VARS | Call by reference | Type reference (TYPE) | STRING_TABLE | 20120601 | ||||
| 2 | EV_GROUPS | Call by reference | Type reference (TYPE) | I | 20120601 | ||||
| 3 | EV_LITERALS | Call by reference | Type reference (TYPE) | I | 20120601 | ||||
| 4 | EV_REGEX | Call by reference | Type reference (TYPE) | STRING | 20120601 | ||||
| 5 | IV_TEMPLATE | Call by reference | Type reference (TYPE) | STRING | 20120601 |
Method PARSE_URI_TEMPLATE_ABAP on class CL_REST_ROUTER has no exception.
Method PROCESS_TEMPLATE_VAR Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | CV_OFFSET | Call by reference | Type reference (TYPE) | I | Offset in Text | 20100210 | |||
| 2 | CV_REGEX | Call by reference | Type reference (TYPE) | STRING | Regular Expression | 20100210 | |||
| 3 | EV_VARNAME | Call by reference | Type reference (TYPE) | STRING | Variable Name | 20100210 | |||
| 4 | IV_TEMPLATE | Call by reference | Type reference (TYPE) | STRING | Template | 20100210 |
Method PROCESS_TEMPLATE_VAR on class CL_REST_ROUTER has no exception.
Method _PARSE_URI_TEMPLATE Signature
| # | Type | Parameter | Pass Value | Optional | Typing Method | Associated Type | Default value | Description | Created on |
|---|---|---|---|---|---|---|---|---|---|
| 1 | ET_VARS | Call by reference | Type reference (TYPE) | STRING_TABLE | 20120601 | ||||
| 2 | EV_GROUPS | Call by reference | Type reference (TYPE) | I | 20120601 | ||||
| 3 | EV_LITERALS | Call by reference | Type reference (TYPE) | I | 20120601 | ||||
| 4 | EV_PARSE_OK | Call by reference | Type reference (TYPE) | I | 20120601 | ||||
| 5 | EV_REGEX | Call by reference | Type reference (TYPE) | STRING | 20120601 | ||||
| 6 | IV_TEMPLATE | Call by reference | Type reference (TYPE) | STRING | 20120601 |
Method _PARSE_URI_TEMPLATE on class CL_REST_ROUTER has no exception.
History
| Last changed by/on | SAP | 20130531 |
| SAP Release Created in | 72L |