Class Mage_Api2_Model_Resource
API2 Abstract Resource
Direct known subclasses
Mage_Catalog_Model_Api2_Product, Mage_Catalog_Model_Api2_Product_Category, Mage_Sales_Model_Api2_Order_Item, Mage_Catalog_Model_Api2_Product_Image, Mage_Catalog_Model_Api2_Product_Website, Mage_CatalogInventory_Model_Api2_Stock_Item, Mage_Customer_Model_Api2_Customer, Mage_Customer_Model_Api2_Customer_Address, Mage_Sales_Model_Api2_Order, Mage_Sales_Model_Api2_Order_Address, Mage_Sales_Model_Api2_Order_CommentIndirect known subclasses
Mage_Catalog_Model_Api2_Product_Category_Rest, Mage_Catalog_Model_Api2_Product_Category_Rest_Admin_V1, Mage_Catalog_Model_Api2_Product_Rest_Customer_V1, Mage_Catalog_Model_Api2_Product_Rest_Guest_V1, Mage_Catalog_Model_Api2_Product_Website_Rest, Mage_Catalog_Model_Api2_Product_Website_Rest_Admin_V1, Mage_CatalogInventory_Model_Api2_Stock_Item_Rest, Mage_CatalogInventory_Model_Api2_Stock_Item_Rest_Admin_V1, Mage_Customer_Model_Api2_Customer_Address_Rest, Mage_Customer_Model_Api2_Customer_Address_Rest_Admin_V1, Mage_Customer_Model_Api2_Customer_Address_Rest_Customer_V1, Mage_Customer_Model_Api2_Customer_Rest, Mage_Catalog_Model_Api2_Product_Category_Rest_Customer_V1, Mage_Customer_Model_Api2_Customer_Rest_Admin_V1, Mage_Customer_Model_Api2_Customer_Rest_Customer_V1, Mage_Sales_Model_Api2_Order_Address_Rest, Mage_Sales_Model_Api2_Order_Address_Rest_Admin_V1, Mage_Sales_Model_Api2_Order_Address_Rest_Customer_V1, Mage_Sales_Model_Api2_Order_Comment_Rest, Mage_Sales_Model_Api2_Order_Comment_Rest_Admin_V1, Mage_Sales_Model_Api2_Order_Comment_Rest_Customer_V1, Mage_Sales_Model_Api2_Order_Item_Rest, Mage_Sales_Model_Api2_Order_Item_Rest_Admin_V1, Mage_Catalog_Model_Api2_Product_Category_Rest_Guest_V1, Mage_Sales_Model_Api2_Order_Item_Rest_Customer_V1, Mage_Sales_Model_Api2_Order_Rest, Mage_Sales_Model_Api2_Order_Rest_Admin_V1, Mage_Sales_Model_Api2_Order_Rest_Customer_V1, Mage_Catalog_Model_Api2_Product_Image_Rest, Mage_Catalog_Model_Api2_Product_Image_Rest_Admin_V1, Mage_Catalog_Model_Api2_Product_Image_Rest_Customer_V1, Mage_Catalog_Model_Api2_Product_Image_Rest_Guest_V1, Mage_Catalog_Model_Api2_Product_Rest, Mage_Catalog_Model_Api2_Product_Rest_Admin_V1Package: Mage\Api2
Category: Mage
Copyright: Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
License: Open Software License (OSL 3.0)
Author: Magento Core Team <core@magentocommerce.com>
Located at code/core/Mage/Api2/Model/Resource.php
public
|
|
protected
|
|
protected
boolean
|
|
public
|
|
public
|
|
public
string
|
|
public
|
|
public
string
|
|
public
|
|
public
integer
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
string
|
|
public
|
|
public
|
|
public
|
|
public
string
|
|
public
|
|
public
string
|
|
public
|
|
public
|
|
public
|
|
protected
|
|
protected
|
|
protected
array
|
|
protected
|
|
protected
|
|
protected
|
|
final protected
|
#
_applyCollectionModifiers( Varien_Data_Collection_Db $collection )
Set navigation parameters and apply filters from URL params |
protected
|
#
_applyFilter( Varien_Data_Collection_Db $collection )
Validate filter data and apply it to collection if possible |
protected
|
#
_multicall( string $resourceInstanceId )
Perform multiple calls to subresources of specified resource |
protected
|
#
_getSubModel( string $resourceId, array $requestParams )
Create model of specified resource and configure it with current object attributes |
protected
boolean
|
#
_isSubCallAllowed( string $resourceId )
Check ACL permission for specified resource with current other conditions |
public
|
|
protected
string
|
|
protected
array
|
#
_getResourceAttributes( )
Resource specific method to retrieve attributes' codes. May be overriden in child. |
public
array
|
#
getAvailableAttributes( string $userType, string $operation )
Get available attributes of API resource |
public
array
|
#
getExcludedAttributes( string $userType, string $operation )
Get excluded attributes for user type |
public
array
|
|
public
array
|
#
getIncludedAttributes( string $userType, string $operationType )
Retrieve list of included attributes |
public
array
|
#
getEntityOnlyAttributes( string $userType, string $operationType )
Retrieve list of entity only attributes |
public
array
|
#
getAvailableAttributesFromConfig( )
Get available attributes of API resource from configuration file |
public
array
|
|
public
array
|
#
getEavAttributes( boolean $onlyVisible = false, boolean $excludeSystem = false )
Get EAV attributes of working model |
protected
|
string |
ACTION_TYPE_ENTITY
|
'entity' |
#
Action types |
string |
ACTION_TYPE_COLLECTION
|
'collection' |
|
string |
OPERATION_CREATE
|
'create' |
#
Operations. Resource method names |
string |
OPERATION_RETRIEVE
|
'retrieve' |
|
string |
OPERATION_UPDATE
|
'update' |
|
string |
OPERATION_DELETE
|
'delete' |
|
string |
OPERATION_ATTRIBUTE_READ
|
'read' |
#
Common operations for attributes |
string |
OPERATION_ATTRIBUTE_WRITE
|
'write' |
|
string |
RESOURCE_NOT_FOUND
|
'Resource not found.' |
#
Default error messages |
string |
RESOURCE_METHOD_NOT_ALLOWED
|
'Resource does not support method.' |
|
string |
RESOURCE_METHOD_NOT_IMPLEMENTED
|
'Resource method not implemented yet.' |
|
string |
RESOURCE_INTERNAL_ERROR
|
'Resource internal error.' |
|
string |
RESOURCE_DATA_PRE_VALIDATION_ERROR
|
'Resource data pre-validation error.' |
|
string |
RESOURCE_DATA_INVALID
|
'Resource data invalid.' |
|
string |
RESOURCE_UNKNOWN_ERROR
|
'Resource unknown error.' |
|
string |
RESOURCE_REQUEST_DATA_INVALID
|
'The request data is invalid.' |
|
string |
RESOURCE_COLLECTION_PAGING_ERROR
|
'Resource collection paging error.' |
#
Default collection resources error messages |
string |
RESOURCE_COLLECTION_PAGING_LIMIT_ERROR
|
'The paging limit exceeds the allowed number.' |
|
string |
RESOURCE_COLLECTION_ORDERING_ERROR
|
'Resource collection ordering error.' |
|
string |
RESOURCE_COLLECTION_FILTERING_ERROR
|
'Resource collection filtering error.' |
|
string |
RESOURCE_COLLECTION_ATTRIBUTES_ERROR
|
'Resource collection including additional attributes error.' |
|
string |
RESOURCE_UPDATED_SUCCESSFUL
|
'Resource updated successful.' |
#
Default success messages |
integer |
PAGE_SIZE_DEFAULT
|
10 |
#
Collection page sizes |
integer |
PAGE_SIZE_MAX
|
100 |
protected
|
$_request |
|
#
Request |
protected
string
|
$_resourceType |
|
#
Resource type |
protected
string
|
$_apiType |
|
#
Api type |
protected
integer
|
$_version | null |
#
API Version |
protected
Zend_Controller_Response_Http
|
$_response |
|
#
Response |
protected
|
$_filter |
|
#
Attribute Filter |
protected
|
$_renderer |
|
#
Renderer |
protected
|
$_apiUser |
|
#
Api user |
protected
string
|
$_userType |
|
#
User type |
protected
string
|
$_actionType |
|
#
One of Mage_Api2_Model_Resource::ACTION_TYPE_... constant |
protected
string
|
$_operation |
|
#
One of Mage_Api2_Model_Resource::OPERATION_... constant |
protected
boolean
|
$_returnData | false |
#
If TRUE - no rendering will be done and dispatch will return data. Otherwise, by default |
protected
|
$_multicall |
|