Class TenantOperationsUtil
java.lang.Object
com.broadleafcommerce.orderoperation.service.util.TenantOperationsUtil
Utility methods to help with performing operations on application entities from a tenant context.
-
Method Summary
Modifier and TypeMethodDescriptionstatic com.broadleafcommerce.data.tracking.core.context.ContextInfogetContextInfoWithApplication(com.broadleafcommerce.data.tracking.core.ContextStateAware object, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Builds a newContextInfofrom the existingcontextInfoif it's not null, and include the correct application context for theContextStateAware.static booleanisApplicationRequest(com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Determines if theContextInfoindicates an application context.
-
Method Details
-
getContextInfoWithApplication
@Nullable public static com.broadleafcommerce.data.tracking.core.context.ContextInfo getContextInfoWithApplication(com.broadleafcommerce.data.tracking.core.ContextStateAware object, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Builds a newContextInfofrom the existingcontextInfoif it's not null, and include the correct application context for theContextStateAware.- Parameters:
object- the object potentially with the application to build a new context info withcontextInfo- the original request context info- Returns:
- a new context info built from
contextInfowith the application ID from the fulfillment's context state, or null ifcontextInfowas null
-
isApplicationRequest
public static boolean isApplicationRequest(@Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Determines if theContextInfoindicates an application context.- Parameters:
contextInfo- context information around sandbox and multitenant state- Returns:
- whether the
ContextInfoindicates an application context
-