public class ClassificationClass extends GeneratedClassificationClass
Category which
resides within a ClassificationSystemVersion only.
It may have multiple attributes
assigned to it. This relation is backed by
ClassAttributeAssignment instances.
GenericItem.GenericItemImplLocalizableItem.LocalizableItemImplExtensibleItem.ExtensibleItemImplItem.AttributeFilter, Item.AttributeMode, Item.CachedGetter, Item.CachedSetter, Item.ItemAttributeMap, Item.ItemConstraint, Item.ItemImpl, Item.JaloCachedComputationException| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
CATALOGVERSION |
CLASSIFICATIONATTRIBUTES, DECLAREDCLASSIFICATIONATTRIBUTEASSIGNMENTS, DECLAREDCLASSIFICATIONATTRIBUTES, DEFAULT_INITIAL_ATTRIBUTES, EXTERNALID, HMCXML, INHERITEDCLASSIFICATIONATTRIBUTES, REVISION, SHOWEMPTYATTRIBUTESDISABLE_CYCLIC_CHECKS, DISABLE_SETALLOWEDPRINCIPAL_RECURSIVELY, DISABLE_SUBCATEGORY_REMOVALCHECKALLOWEDPRINCIPALS, CATALOG, CATEGORIES, CATEGORY2KEYWORDRELATION_MARKMODIFIED, CATEGORY2KEYWORDRELATION_SRC_ORDERED, CATEGORY2KEYWORDRELATION_TGT_ORDERED, CATEGORY2PRINCIPALRELATION_MARKMODIFIED, CATEGORY2PRINCIPALRELATION_SRC_ORDERED, CATEGORY2PRINCIPALRELATION_TGT_ORDERED, CATEGORYCATEGORYRELATION_MARKMODIFIED, CATEGORYCATEGORYRELATION_SRC_ORDERED, CATEGORYCATEGORYRELATION_TGT_ORDERED, CATEGORYMEDIARELATION_MARKMODIFIED, CATEGORYMEDIARELATION_SRC_ORDERED, CATEGORYMEDIARELATION_TGT_ORDERED, CATEGORYPRODUCTRELATION_MARKMODIFIED, CATEGORYPRODUCTRELATION_SRC_ORDERED, CATEGORYPRODUCTRELATION_TGT_ORDERED, CODE, DATA_SHEET, DESCRIPTION, DETAIL, KEYWORDS, LOGO, MEDIAS, NAME, NORMAL, ORDER, OTHERS, PICTURE, PRODUCTS, SUPERCATEGORIES, THUMBNAIL, THUMBNAILSLANGUAGE_FALLBACK_ENABLED_CREATION_TIME_INTERNAL, _MODIFIED_TIME_INTERNAL, accessorLog, CREATION_TIME, DISABLE_ATTRIBUTE_CHECK, DISABLE_ITEMCHECK_BEFORE_REMOVABLE, EVEN, FEATURE_ACCESSMAP_QUALIFIER, INITIAL_CREATION_FLAG, isJaloOnly, MODIFIED_TIME, NEGATIVE, NOT_FOUND, OWNER, PK, POSITIVE, SAVE_FROM_SERVICE_LAYER, staticTransientObjects, TYPEimpl, tenant| Constructor and Description |
|---|
ClassificationClass() |
| Modifier and Type | Method and Description |
|---|---|
ClassAttributeAssignment |
assignAttribute(ClassificationAttribute attribute) |
ClassAttributeAssignment |
assignAttribute(ClassificationAttribute attribute,
EnumerationValue type,
ClassificationAttributeUnit unit,
java.util.Collection values,
int position) |
ClassAttributeAssignment |
assignAttribute(ClassificationAttribute attribute,
int position) |
ClassAttributeAssignment |
assignAttribute(ClassificationAttribute attribute,
java.lang.String typeCode,
ClassificationAttributeUnit unit,
java.util.Collection values,
int position) |
protected ClassAttributeAssignment |
assignToMe(ClassificationAttribute attribute,
EnumerationValue type,
ClassificationAttributeUnit unit,
java.util.Collection values,
int position) |
protected Item |
createItem(SessionContext ctx,
ComposedType type,
Item.ItemAttributeMap allAttributes)
create the item you can delete this method if you don't want to intercept the creation of this item
|
java.util.Collection<ClassificationClass> |
getAllSuperClasses() |
ClassAttributeAssignment |
getAttributeAssignment(ClassificationAttribute attr)
Provides access to the assignment of a given attribute to this class.
|
EnumerationValue |
getAttributeType(ClassificationAttribute attribute)
Returns the value type of the given attribute within this class.
|
ClassificationAttributeUnit |
getAttributeUnit(ClassificationAttribute attribute)
Returns the classifcation unit belonging to the given attribute within this class.
|
java.util.Map |
getAttributeValueMap()
Returns all attributes together with their assigned values as a map { ClassificationAttribute -> [
ClassificationAttributeValue *] }
|
java.util.Collection<ClassificationAttributeValue> |
getAttributeValues(ClassAttributeAssignment asgnmt)
Returns the values to choose from for the given attribute within this class.
|
java.util.Collection<ClassificationAttributeValue> |
getAttributeValues(ClassificationAttribute attribute)
Returns the values to choose from for the given attribute within this class.
|
ClassificationAttribute |
getClassificationAttribute(java.lang.String code) |
java.util.Collection<ClassAttributeAssignment> |
getClassificationAttributeAssignments() |
java.util.Collection<ClassAttributeAssignment> |
getClassificationAttributeAssignments(SessionContext ctx)
Deprecated.
since ages - use
ClassificationClassModel.getAllClassificationAttributeAssignments()
instead. |
java.util.List<ClassificationAttribute> |
getClassificationAttributes(SessionContext ctx)
Returns all classification attributes which are available for this class.
|
java.util.Collection<ClassAttributeAssignment> |
getComparableAttributeAssignments() |
java.util.Collection<ClassAttributeAssignment> |
getComparableAttributeAssignments(SessionContext ctx) |
protected Language |
getContextLanguage(SessionContext ctx) |
java.util.List<ClassAttributeAssignment> |
getDeclaredClassificationAttributeAssignments(SessionContext ctx)
Generated method - Getter of the
ClassificationClass.declaredClassificationAttributeAssignments attribute. |
java.util.List<ClassificationAttribute> |
getDeclaredClassificationAttributes(SessionContext ctx)
Generated method - Getter of the
ClassificationClass.declaredClassificationAttributes attribute. |
java.util.List<ClassificationAttribute> |
getInheritedClassificationAttributes(SessionContext ctx)
Returns all classification attributes which are available for this class but are assigned to any of its super
classes.
|
java.util.Collection<ClassAttributeAssignment> |
getListableAttributeAssignments() |
java.util.Collection<ClassAttributeAssignment> |
getListableAttributeAssignments(SessionContext ctx) |
protected int |
getMaxPosition() |
protected java.text.NumberFormat |
getNumberFormat(SessionContext ctx,
java.lang.String formatDefinition) |
java.util.Collection<ClassAttributeAssignment> |
getSearchableAttributeAssignments() |
java.util.Collection<ClassAttributeAssignment> |
getSearchableAttributeAssignments(SessionContext ctx) |
java.util.Set<ClassificationClass> |
getSubClasses()
Returns all subclasses of this class.
|
java.util.Set<ClassificationClass> |
getSuperClasses() |
ClassificationSystemVersion |
getSystemVersion() |
EnumerationValue |
getVisibility(ClassificationAttribute attribute)
Returns the visibility of a given attribute within this class.
|
boolean |
isClassifying(Product product)
Tells whether or not a given product is beeing classified by this class.
|
boolean |
isLocalized(ClassificationAttribute atr)
Tells whether or not a given attribute is localized within this class.
|
boolean |
isMandatory(ClassificationAttribute attribute)
Tells whether or not the given attribute is mandatory within this class.
|
boolean |
isMultiValued(ClassificationAttribute atr)
Tells whether or not multiple values are allowed for a given attribute within this class.
|
boolean |
isRange(ClassificationAttribute atr)
Tells whether or not a given attribute describes a range value within this class.
|
void |
remove(SessionContext ctx)
Removes this class together with all its attribute assignments.
|
void |
setAttributeType(ClassificationAttribute attribute,
EnumerationValue valueType)
Changes the value type of the given attribute within this class.
|
void |
setAttributeUnit(ClassificationAttribute attribute,
ClassificationAttributeUnit unit)
Changes the classifcation unit belonging to the given attribute within this class.
|
void |
setAttributeValueMap(java.util.Map attributeValueMappings)
Changes the assigned values of all attributes by providing a map { ClassificationAttribute -> [
ClassificationAttributeValue *] }
|
void |
setAttributeValues(ClassificationAttribute attribute,
java.util.List<ClassificationAttributeValue> values)
Changes the values to choose from for the given attribute within this class.
|
void |
setDeclaredClassificationAttributeAssignments(SessionContext ctx,
java.util.List<ClassAttributeAssignment> assignments)
Generated method - Setter of the
ClassificationClass.declaredClassificationAttributeAssignments attribute. |
void |
setLocalized(ClassificationAttribute atr,
boolean loc)
Changes whether or not a given attribute is localized within this class.
|
void |
setMandatory(ClassificationAttribute attribute,
boolean mandatory)
Changes whether or not the given attribute is mandatory within this class.
|
void |
setMultiValued(ClassificationAttribute atr,
boolean multi)
Changes whether or not multiple values are allowed for a given attribute within this class.
|
void |
setRange(ClassificationAttribute atr,
boolean range)
Changes whether or not a given attribute describes a range value within this class.
|
void |
setSuperClass(ClassificationClass superClass)
Sets the super class of this classification class.
|
void |
setVisibility(ClassificationAttribute attribute,
EnumerationValue vsbl)
Changes the visibility of a given attribute within this class.
|
protected java.util.Collection |
translateValue(SessionContext ctx,
ClassAttributeAssignment asgnmt,
java.lang.Object value)
Ensures that value(s) are set as collection even if there is just a single value object.
|
getClassificationAttributes, getDeclaredClassificationAttributeAssignments, getDeclaredClassificationAttributes, getDefaultAttributeModes, getExternalID, getExternalID, getHmcXML, getHmcXML, getInheritedClassificationAttributes, getRevision, getRevision, isShowEmptyAttributes, isShowEmptyAttributes, isShowEmptyAttributesAsPrimitive, isShowEmptyAttributesAsPrimitive, setDeclaredClassificationAttributeAssignments, setExternalID, setExternalID, setHmcXML, setHmcXML, setRevision, setRevision, setShowEmptyAttributes, setShowEmptyAttributes, setShowEmptyAttributes, setShowEmptyAttributesaddProduct, addProduct, addProduct, addProduct, addProducts, addProducts, addSubcategories, addSubcategories, addSubcategory, addSubcategory, addSupercategories, addSupercategories, addSupercategory, addSupercategory, addToCategories, addToSupercategories, assertNoCycle, checkRemovable, containsProducts, disableChecks, getAllProductsCount, getAllSubcategories, getAllSubcategories, getAllSubcategoriesCount, getAllSupercategories, getAllSupercategories, getCode, getPath, getPaths, getProductsCount, getSubcategories, getSubcategories, getSubcategoryCount, getSupercategory, getSupercategory, getSupercategoryCount, isEmpty, isRoot, isRoot, isRootAsPrimitive, isRootAsPrimitive, isSetAllowedPrincipalsRecursivelyDisabled, isSubcategoryRemovalCheckDisabled, pullUpAllowedPrincipalInternals, removeProduct, removeProduct, removeProducts, removeProducts, removeSubcategories, removeSubcategories, removeSubcategory, removeSubcategory, removeSupercategories, removeSupercategories, removeSupercategory, removeSupercategory, setAllowedPrincipals, setAllowedPrincipalsOnlyForPassedCategory, setCategories, setCategories, setCategories, setSubcategories, setSubcategories, setSupercategories, setSupercategories, setSupercategories, toStringaddToAllowedPrincipals, addToAllowedPrincipals, addToCategories, addToKeywords, addToKeywords, addToMedias, addToMedias, addToProducts, addToProducts, addToSupercategories, getAllDescription, getAllDescription, getAllKeywords, getAllKeywords, getAllName, getAllName, getAllowedPrincipals, getAllowedPrincipals, getAllowedPrincipalsCount, getAllowedPrincipalsCount, getCatalogVersion, getCatalogVersion, getCategories, getCategories, getCategoriesCount, getCategoriesCount, getCode, getData_sheet, getData_sheet, getDescription, getDescription, getDetail, getDetail, getKeywords, getKeywords, getKeywordsCount, getKeywordsCount, getKeywordsCount, getKeywordsCount, getLogo, getLogo, getMedias, getMedias, getMediasCount, getMediasCount, getName, getName, getNormal, getNormal, getOrder, getOrder, getOrderAsPrimitive, getOrderAsPrimitive, getOthers, getOthers, getPicture, getPicture, getProducts, getProducts, getProductsCount, getSupercategories, getSupercategories, getSupercategoriesCount, getSupercategoriesCount, getThumbnail, getThumbnail, getThumbnails, getThumbnails, isMarkModifiedDisabled, removeFromAllowedPrincipals, removeFromAllowedPrincipals, removeFromCategories, removeFromCategories, removeFromKeywords, removeFromKeywords, removeFromMedias, removeFromMedias, removeFromProducts, removeFromProducts, removeFromSupercategories, removeFromSupercategories, setAllDescription, setAllDescription, setAllKeywords, setAllKeywords, setAllName, setAllName, setAllowedPrincipals, setCatalogVersion, setCatalogVersion, setCategories, setCode, setCode, setData_sheet, setData_sheet, setDescription, setDescription, setDetail, setDetail, setKeywords, setKeywords, setLogo, setLogo, setMedias, setMedias, setName, setName, setNormal, setNormal, setOrder, setOrder, setOrder, setOrder, setOthers, setOthers, setPicture, setPicture, setProducts, setProducts, setSupercategories, setThumbnail, setThumbnail, setThumbnails, setThumbnailsgetInitialProperties, getNonInitialAttributesgetAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllValuesSessionContext, getLocalizedProperty, getLocalizedProperty, getLocalizedPropertyInternal, getLocalizedPropertyNames, getLocalizedPropertyNames, hasLanguage, isEmptyValue, isFallbackEnabled, removeLocalizedProperty, removeLocalizedProperty, setAllLocalizedProperties, setAllLocalizedProperties, setLocalizedProperty, setLocalizedPropertycreateNonClassAccessor, getAllProperties, getAllProperties, getImplementation, getProperty, getProperty, getPropertyNames, getPropertyNames, removeProperty, removeProperty, setAllProperties, setAllProperties, setProperty, setPropertyaddLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addNegativePermission, addPermission, addPositivePermission, assureExtensionsLoaded, changeTypeAfterCreation, checkConstraint, checkItemPermission, checkMandatoryAttribute, checkMandatoryAttribute, checkPermission, checkPermission, clearPermission, compareTo, ctx, doAfterRemove, doBeforeRemove, equals, getAccessorFor, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributesInternal, getAllLinkedItems, getAndCheckCacheBoundItem, getAttribute, getAttribute, getCacheBoundItem, getComposedType, getComposedTypePK, getCreationTime, getCurrentlyRemovingCount, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItemsCount, getLinkedItemsCount, getLinkedItemsCount, getModificationTime, getNegativePermissions, getOwner, getPermissionMap, getPermissions, getPersistenceVersion, getPK, getPositivePermissions, getRestrictedPrincipals, getSession, getSyncObject, getTenant, getTransientObject, getTransientObjectMap, hashCode, hasRegisteredClassAccessorFor, internal_registerClassAccessorFor, internal_registerNonClassAccessorFor, invalidateLocalCaches, isAlive, isCacheBound, isCurrentlyRemoving, isCurrentlyRemoving, isEmptyRelationValue, isInCreate, isInstanceOf, isItemCheckBeforeRemoveableDisabled, isRelationLocalizationFallbackEnabled, newInstance, notifyExtensionsAfterItemCreation, notifyExtensionsBeforeItemCreation, notifyItemRemoval, notifyManagerAboutItemRemoval, readResolve, registerAccessFor, registerAccessFor, registerJaloInvalidationListeners, remove, removeItemCollection, removeItemCollection, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinks, removePartOfItems, removePartOfItems, setAllAttributes, setAllAttributes, setAllAttributesInternal, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAttribute, setAttribute, setAttributeFromString, setAttributeFromString, setCacheBound, setComposedType, setCreationTime, setImplementation, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setModificationTime, setNonInitialAttributes, setOwner, setPermissionsByMap, setTransientObject, setUseTA, useTA, writeReplacesetTenantprotected Item createItem(SessionContext ctx, ComposedType type, Item.ItemAttributeMap allAttributes) throws JaloBusinessException
CategorycreateItem in class Categoryctx - the current session context which this item is created withintype - the actual item type ( since subtypes may not provide a own jalo class this may be different from the
type which this method was implemented for )JaloBusinessException - indicates an error during creation - any changes will be rollbackedpublic void remove(SessionContext ctx) throws ConsistencyCheckException
remove in class Itemctx - A SessionContext objectConsistencyCheckException - if this item could not be removed for some reasonpublic ClassificationSystemVersion getSystemVersion()
public void setSuperClass(ClassificationClass superClass)
Category.setSupercategories(SessionContext, List).
Even though classification classes may have more than one parent class (due to beeing subtype of Category)
most systems have a simple tree structure.
superClass - public java.util.Set<ClassificationClass> getSubClasses()
Category.getSubcategories() except that only
ClassificationClass instances are included.public java.util.Set<ClassificationClass> getSuperClasses()
public java.util.Collection<ClassificationClass> getAllSuperClasses()
public ClassAttributeAssignment getAttributeAssignment(ClassificationAttribute attr) throws JaloItemNotFoundException
attr - the attribute to get the assignment forJaloItemNotFoundException - if the attribute is not assignedpublic java.util.List<ClassificationAttribute> getClassificationAttributes(SessionContext ctx)
getClassificationAttributes in class GeneratedClassificationClasspublic ClassificationAttribute getClassificationAttribute(java.lang.String code)
public java.util.List<ClassificationAttribute> getInheritedClassificationAttributes(SessionContext ctx)
getInheritedClassificationAttributes in class GeneratedClassificationClasspublic java.util.List<ClassificationAttribute> getDeclaredClassificationAttributes(SessionContext ctx)
GeneratedClassificationClassClassificationClass.declaredClassificationAttributes attribute.getDeclaredClassificationAttributes in class GeneratedClassificationClassprotected int getMaxPosition()
public ClassAttributeAssignment assignAttribute(ClassificationAttribute attribute)
public ClassAttributeAssignment assignAttribute(ClassificationAttribute attribute, int position)
public ClassAttributeAssignment assignAttribute(ClassificationAttribute attribute, java.lang.String typeCode, ClassificationAttributeUnit unit, java.util.Collection values, int position) throws JaloInvalidParameterException, JaloItemNotFoundException
public ClassAttributeAssignment assignAttribute(ClassificationAttribute attribute, EnumerationValue type, ClassificationAttributeUnit unit, java.util.Collection values, int position)
protected ClassAttributeAssignment assignToMe(ClassificationAttribute attribute, EnumerationValue type, ClassificationAttributeUnit unit, java.util.Collection values, int position)
public ClassificationAttributeUnit getAttributeUnit(ClassificationAttribute attribute)
attribute - the attribute to get the unit forpublic void setAttributeUnit(ClassificationAttribute attribute, ClassificationAttributeUnit unit)
attribute - the attribute to set the unit forunit - the new classifcation unitpublic java.util.Collection<ClassificationAttributeValue> getAttributeValues(ClassificationAttribute attribute)
If no values are specified within the underlying ClassAttributeAssignment this method will return the
default attribute values from ClassificationAttribute.getDefaultAttributeValues(SessionContext). This is a
read-only fallback - setAttributeValues(ClassificationAttribute, List) does not change the default
attribute values!
attribute - the attribute to get values forpublic java.util.Collection<ClassificationAttributeValue> getAttributeValues(ClassAttributeAssignment asgnmt)
If no values are specified within the underlying ClassAttributeAssignment this method will return the
default attribute values from ClassificationAttribute.getDefaultAttributeValues(SessionContext). This is a
read-only fallback - setAttributeValues(ClassificationAttribute, List) does not change the default
attribute values!
asgnmt - the attribute assignment to get values forpublic void setAttributeValues(ClassificationAttribute attribute, java.util.List<ClassificationAttributeValue> values)
attribute - the attribute to set values forvalues - the new value listpublic java.util.Map getAttributeValueMap()
public void setAttributeValueMap(java.util.Map attributeValueMappings)
public EnumerationValue getVisibility(ClassificationAttribute attribute)
attribute - the attribute to get the visibility forpublic void setVisibility(ClassificationAttribute attribute, EnumerationValue vsbl)
attribute - the attribute to set the visibility forvsbl - the new visibility statuspublic EnumerationValue getAttributeType(ClassificationAttribute attribute)
attribute - the attribute to get the value type forpublic void setAttributeType(ClassificationAttribute attribute, EnumerationValue valueType)
Please note that this change may render current values useless which was stored for this attribute at products before - they are not being converted!
attribute - the attribute to set the value type forvalueType - the new value typepublic boolean isMandatory(ClassificationAttribute attribute)
attribute - the attribute to get mandatory flag forpublic void setMandatory(ClassificationAttribute attribute, boolean mandatory)
attribute - the attribute to set mandatory flag formandatory - the new mandatory flagpublic boolean isLocalized(ClassificationAttribute atr)
public void setLocalized(ClassificationAttribute atr, boolean loc)
public boolean isRange(ClassificationAttribute atr)
public void setRange(ClassificationAttribute atr, boolean range)
public boolean isMultiValued(ClassificationAttribute atr)
public void setMultiValued(ClassificationAttribute atr, boolean multi)
public java.util.Collection<ClassAttributeAssignment> getListableAttributeAssignments()
public java.util.Collection<ClassAttributeAssignment> getListableAttributeAssignments(SessionContext ctx)
public java.util.Collection<ClassAttributeAssignment> getComparableAttributeAssignments()
public java.util.Collection<ClassAttributeAssignment> getComparableAttributeAssignments(SessionContext ctx)
public java.util.Collection<ClassAttributeAssignment> getSearchableAttributeAssignments()
public java.util.Collection<ClassAttributeAssignment> getSearchableAttributeAssignments(SessionContext ctx)
public java.util.Collection<ClassAttributeAssignment> getClassificationAttributeAssignments()
@Deprecated public java.util.Collection<ClassAttributeAssignment> getClassificationAttributeAssignments(SessionContext ctx)
ClassificationClassModel.getAllClassificationAttributeAssignments()
instead.public java.util.List<ClassAttributeAssignment> getDeclaredClassificationAttributeAssignments(SessionContext ctx)
GeneratedClassificationClassClassificationClass.declaredClassificationAttributeAssignments attribute.getDeclaredClassificationAttributeAssignments in class GeneratedClassificationClasspublic void setDeclaredClassificationAttributeAssignments(SessionContext ctx, java.util.List<ClassAttributeAssignment> assignments)
GeneratedClassificationClassClassificationClass.declaredClassificationAttributeAssignments attribute.setDeclaredClassificationAttributeAssignments in class GeneratedClassificationClassassignments - the declaredClassificationAttributeAssignments - list of attribute assignmentsprotected Language getContextLanguage(SessionContext ctx)
protected java.util.Collection translateValue(SessionContext ctx, ClassAttributeAssignment asgnmt, java.lang.Object value)
ctx - the session context defining the language to use for comparing attribute value labelsasgnmt - the class attribute assignmentvalue - the value to translatepublic boolean isClassifying(Product product)
product - the product to check assignment forprotected java.text.NumberFormat getNumberFormat(SessionContext ctx, java.lang.String formatDefinition)
Copyright © 2018 SAP SE. All Rights Reserved.