public class MagentoJsonParser extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
ERROR_MESSAGE |
| Constructor and Description |
|---|
MagentoJsonParser() |
| Modifier and Type | Method and Description |
|---|---|
static MagentoException |
parseError(String json)
This method parses a Magento json string for a error message and returns
a new instance of a imixs PluginException containing the error code and
the error message.
|
static List<org.imixs.workflow.ItemCollection> |
parseObjectList(String json)
This method parses a Magento json string containing a List of objects.
|
public static final String ERROR_MESSAGE
public static MagentoException parseError(String json)
{"messages":{"error":[{"code":401,"message":"oauth_problem=token_rejected"}]}}
json - - the message stringpublic static List<org.imixs.workflow.ItemCollection> parseObjectList(String json) throws MagentoException
[ {"item_id":"1","product_id":"1","stock_id":"1","qty":"99.0000","low_stock_date":null},
{"item_id":"2","product_id":"2","stock_id":"1","qty":"100.0000","low_stock_date":null}
]
json - - the object stringorg.imixs.workflow.exceptions.PluginExceptionMagentoExceptionCopyright © 2019 Imixs Software Solutions GmbH. All rights reserved.