Package DE_EPAGES::WebService::API::WebService::ObjectService
provides web service access to objects
Example |
use DE_EPAGES::WebService::API::Client; my $FactoryService = DE_EPAGES::WebService::API::Client ->uri('urn://epages.de/WebService/FactoryService/2004/08') ->proxy("http://%2fUsers%2f$Login:$Password\@localhost:8080/epages/Store.soap"); my $ShopID = $FactoryService->objectByPath( '/Shops/DemoShop' )->result; my $ObjectService = DE_EPAGES::WebService::API::Client ->uri('urn://epages.de/WebService/ObjectService/2004/08') ->proxy("http://%2fUsers%2f$Login:$Password\@localhost:8080/epages/Store.soap"); my $ProductsFolderID = $ObjectService->child( $ShopID, 'Products' )->result; my $ProductsID = $ObjectService->child( $ProductsFolderID, '0815' )->result; |
Functions
child
Returns a child object by Alias.
Syntax |
$ChildObjectID = $ObjectService->child( $ObjectID, $Alias )->result; |
Input |
|
Return |
|
delete
Deletes an object including all child objects.
Syntax |
$ObjectService->delete( $ObjectID ); |
Input |
|
existsChild
Returns true if a child object with the given Alias exists.
Syntax |
$Exists = $ObjectService->existsChild( $ObjectID, $Alias )->result; |
Example |
if( $ObjectService->existsChild( $ObjectID, '0815' )->result ) { ... } |
Input |
|
Return |
|
folder
Returns a folder object by Alias.
Syntax |
$FolderObjectID = $ObjectService->folder( $ObjectID, $Alias )->result; |
Input |
|
Return |
|
get
Returns attribute values of an object.
Syntax |
$hValues = $ObjectService->get( $ObjectID, $aNames )->result; $hValues = $ObjectService->get( $ObjectID, $aNames, $LanguageCode )->result; |
Example |
$Position = $ObjectService->get( $ObjectID, ['Position'] )->result->{'Position'}; |
Input |
|
Return |
|
getLoop
Returns attribute values of multiple objects.
Syntax |
$ahValues = $ObjectService->get( $aObjectIDs, $aNames, $LanguageCode )->result; |
Input |
|
Return |
|
insertChild
Inserts a new child object.
Syntax |
$ChildObjectID = $ObjectService->insertChild( $ObjectID, $ClassID, $hValues )->result; |
Example |
$ClassID = $FactoryService->classByAlias( 'Category' )->result; $ChildObjectID = $ObjectService->insertChild( $ObjectID, $ClassID, { Alias => 'Fiction', IsVisible => 1 } )->result; |
Input |
|
Return |
|
set
Sets attribute values of an object.
Syntax |
$ObjectService->set( $ObjectID, $hValues ); $ObjectService->set( $ObjectID, $hValues, $LanguageCode ); |
Example |
$ObjectService->set( $ObjectID, { Position => 21 } ); |
Input |
|