ePages 7.19.0 - DE_EPAGES/MultiStoreConnector/API/Resource/MultiStoreCategories.pm

Package DE_EPAGES::MultiStoreConnector::API::Resource::MultiStoreCategories

implements the REST resource for a single shipping method.

Base
DE_EPAGES::WebService::API::Resource::BaseObjectResource

Functions

class
match
params
post
service

class

Returns the class name of objects that are represented by this resource. The value is passed to $Site->loadObject($ObjectID, $Class);

Syntax
$ClassName = $Resource->class;
Return
$ClassName (string)
class name

match

Tests if the resource can handle the request. If no, returns an empty list. If yes, returns a defined value. In some cases this value can be interpreted as object identifier for the actual resource.

Syntax
$Match = $Resource->match($Request);
Example
$Match = $Resource->match($Request);
if (defined $Match) {
    my $hRequestContext = $Resource->requestContext($Site, $Match, $Request);
}
Input
$Request (HTTP::Request)
request object
Return
$Match (string)
object identifier

params

Returns the parameters for the action function.

Syntax
$hRequestContext = $Resource->params($ActionName, $Match, $Request);
Input
$ActionName (DE_EPAGES::Object::API::Object::Site)
name of the action
$Match (string)
result of match
$Request (HTTP::Request)
request object
Return
$hRequestContext (ref.hash)
request data with keys:
  • Object - business object - DE_EPAGES::Object::API::Object::Object
  • Action - action object or sub ref to handle the request - ref.code or DE_EPAGES::Permission::API::Object::Action
  • Params - parameters to the action function - ref.array
  • RequestCodec -
  • ResponseCodec -

post

Returns the parameters for the action function.

Syntax
$hRequestContext = $Resource->post($ActionName, $Match, $Request);
Input
$ActionName (DE_EPAGES::Object::API::Object::Site)
name of the action
$Match (string)
result of match
$Request (HTTP::Request)
request object
Return
$hRequestContext (ref.hash)
request data with keys:
  • Object - business object - DE_EPAGES::Object::API::Object::Object
  • Action - action object or sub ref to handle the request - ref.code or DE_EPAGES::Permission::API::Object::Action
  • Params - parameters to the action function - ref.array
  • RequestCodec -
  • ResponseCodec -

service

Returns the RestService object that contains the RestServiceMethod objects which implement the actual actions.

Syntax
$RestService = $Resource->service;
Return
$RestService (DE_EPAGES::WebService::API::Object::RestService)
rest service object