Class ProductDataMappingUtils
java.lang.Object
com.priint.pubserver.comet.bridge.datamapping.ProductDataMappingUtils
The type Product data mapping utils.
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleancanHaveChildren(EntityModel model, String entityId) Can have children boolean.static BucketgetBucketById(String entityModelName, String parentEntityId, String parentBucketId, Context context) Gets bucket by id.static CometBridgeLocalGets comet bridge.static EntityManagerLocalGets the EntityManager.static EntityModelgetEntityModel(String entityModelName) Gets a particular EntityModel.static EntityResultFilterGets the EntityResultFilter configured for this project.static StringgetIconUrl(Entity entity) Gets icon url.static StringgetIconUrlForSnippet(Entity ignoredEntity) Gets icon url for snippet.static final StringgetNewIconPath(String path) static ProductDataMappingGets the product data mapping implementation configured for the actual CometProject.static CometProductPanelConfigGets the product panel configuration for the current Comet project.static final booleanrefersToOldIcon(String path)
-
Method Details
-
getProductDataMapping
Gets the product data mapping implementation configured for the actual CometProject.
- Returns:
- ProductDataMapping implementation
- Throws:
CometException- the comet exception
-
getEntityManager
Gets the EntityManager.
This is a shortcut for
PluginUtils.getPlugin(Constants.MANAGER_ENTITY, PluginControlDefault.getSessionId(), EntityManagerLocal.class);
- Returns:
- EntityManager bean
-
getEntityModel
Gets a particular EntityModel.
- Parameters:
entityModelName- identifier of the EntityModel- Returns:
- EntityModel referred by the provided identifier
- Throws:
CometException- thrown, if the EntityModel cannot be found, e.g. illegal identifier
-
getEntityResultFilter
Gets the EntityResultFilter configured for this project.
See the
EntityResultFilterdocumentation for details- Returns:
- EntityResultFilter object configured for this Comet project
- Throws:
CometException- the comet exception
-
getProductPanelConfig
Gets the product panel configuration for the current Comet project.
- Returns:
- CometProductPanelConfig object
- Throws:
CometException- the comet exception
-
canHaveChildren
Can have children boolean.- Parameters:
model- the modelentityId- the entity id- Returns:
- the boolean
-
refersToOldIcon
-
getNewIconPath
-
getIconUrl
Gets icon url.- Parameters:
entity- the entity- Returns:
- the icon url
-
getIconUrlForSnippet
Gets icon url for snippet.- Parameters:
ignoredEntity- the entity- Returns:
- the icon url for snippet
-
getBucketById
public static Bucket getBucketById(String entityModelName, String parentEntityId, String parentBucketId, Context context) throws CometException Gets bucket by id.- Parameters:
entityModelName- the entity model nameparentEntityId- the parent entity idparentBucketId- the parent bucket idcontext- the context- Returns:
- the bucket by id
- Throws:
CometException- the comet exception
-
getCometBridge
Gets comet bridge.- Returns:
- the comet bridge
-