public class CBOEntity extends EntityDefinition implements java.io.Serializable, java.lang.Comparable, EntityI
EntityI.EntityMatcher, EntityI.NonPersistentEdgeFilterATT_NAME_ABSTRACT, ATT_NAME_CODE_CUSTOM, ATT_NAME_CODE_DEPENDENTS, ATT_NAME_CODE_GENERATE, ATT_NAME_CODE_GENERATE_AS, ATT_NAME_CODE_PACKAGE, ATT_NAME_DB_FORBID_DIRECT_CHANGES, ATT_NAME_DB_LOW_INSTANCE_COUNT, ATT_NAME_DB_NAME, ATT_NAME_DB_NO_STREAM_RESOURCE_HISTORY, ATT_NAME_DB_PERSISTENT, ATT_NAME_DB_STREAM_RESOURCE, ATT_NAME_DISCRIMINATOR, ATT_NAME_EXPORT_MODE, ATT_NAME_EXPORT_NAME, ATT_NAME_EXPORT_PRIMARY_KEY, ATT_NAME_EXTENDS, ATT_NAME_FOLDER, ATT_NAME_FULLTEXT_BOOST, ATT_NAME_FULLTEXT_INDEXED, ATT_NAME_GDPR_DATA_CATEGORY, ATT_NAME_GDPR_RETENTION_START_DATE_PATH, ATT_NAME_IGNORE_REVERSE_RELATIONS, ATT_NAME_IMPLEMENTS_NAME, ATT_NAME_LOOKUP_DEFAULT_CASE_SENSITIVE, ATT_NAME_LOOKUP_DEFAULT_PROPERTY, ATT_NAME_LOOKUP_DEFAULT_SUBSTRING, ATT_NAME_MERGE, ATT_NAME_NAME, ATT_NAME_NO_ABSTRACT_WARNING, ATT_NAME_PACKAGE, ATT_NAME_PLURAL, ATT_NAME_REPORT_FONT_SIZE_BIG, ATT_NAME_REPORT_FONT_SIZE_NORMAL, ATT_NAME_REPORT_ORIENTATION, ATT_NAME_REPORT_TITLE, ATT_NAME_SUID, ATT_NAME_UI_DEFAULT_SELECTION_FILTER, ATT_NAME_UI_DEFAULT_SORTING, ATT_NAME_UI_DESCRIPTION, ATT_NAME_UI_LINK_ONLY, ATT_NAME_UI_LOAD_IMMEDIATE, ATT_NAME_UI_TIPS, DEFAULT_GENERATE_AS_SUFFIX, DEFAULT_SORTING_ASC, DEFAULT_SORTING_DESC, DEPENDENTS_SEPARATOR_CHAR, EL_NAME_ACTION, EL_NAME_ATTR, EL_NAME_CODE, EL_NAME_COMMENT, EL_NAME_DB, EL_NAME_EXPORT, EL_NAME_FULLTEXT, EL_NAME_GDPR, EL_NAME_IMPLEMENTS, EL_NAME_LOOKUP, EL_NAME_NPATTR, EL_NAME_REPORT, EL_NAME_UI, EL_NAME_VATTR, EMPTY_ARRAY, EXPORT_MODE_IF_REFERENCED, EXPORT_MODE_LIST, EXPORT_MODE_NEVER, EXPORT_MODE_SINGLE, GENERATE_AS_DELIMITER_CHAR, PREFIX_L10N_KEY, RESERVED_TABLE_NAMES, SUFFIX_L10N_PLURAL_KEY| Constructor and Description |
|---|
CBOEntity(CBOSchema _schema,
electric.xml.Element _el)
Constructor for the CBOEntity class with scope SCOPE_LOCAL.
|
CBOEntity(CBOSchema _schema,
electric.xml.Element _el,
int _scope)
Constructor for the CBOEntity class.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addDependents(java.lang.String s)
Adds the classes, given as comma separated
String,
to the dependent classes |
void |
addRelationObject(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object addMe)
Adds the given value to the relation specified via its attribute name in the given bo
|
void |
buildPass2()
2nd pass of building - namely backrelation definition
|
void |
buildPass2ForAttribute(CBOAttribute cboatt)
make sures there are no clashes between scalars and many relations singular definitions
|
void |
checkAbstractHasConcreteSubs()
Checks if all abstract subentities of this
CBOEntity has concrete subentities |
void |
checkAggregates()
Checks the aggregates defined in any attribute.
|
void |
checkAmbiguousRelations()
Checks the relations of this
CBOEntity for ambiguos problems |
void |
checkAndInitHeritage()
Sets the heritage for this
CBOEntity (and its base entities). |
void |
checkAttributeNaming()
Checks the attributes of the given
Map for collisions of their name or singular with the attributes of
this entity and its possible sub-entities. |
void |
checkAttributeNaming(java.util.Map existingAttsArg)
Checks the attributes of the given
Map for collisions of their name or singular with the attributes of
this entity and its possible sub-entities. |
void |
checkBackRelations()
Checks the back relations for this
CBOEntity |
void |
checkClass()
Entity classes must have a no-args constructor and may not be abstract.
|
void |
checkItemProperties()
Iterates over the attributes and checks if their ItemProperty actually
points to an existing Attribute.
|
EntityI |
checkLoadImmediate(java.lang.Boolean _b)
Checks if loadImmediate of this
CBOEntity (or its base entity) equals the given value |
void |
checkRelations(int pass)
Checks the relations for this
CBOEntity |
void |
checkSingularAbsenceForNTo1()
Checks if any n-1 relation has an explicit singular set in the schema-file and
signals an AttributeDefinitionException in that case.
|
int |
compareTo(java.lang.Object o)
Comparable interface
Compares this object with the specified object for order.
|
void |
config(electric.xml.Element elEntity,
boolean fromConstructor)
Configures the current entity.
|
CBOAttribute |
declareAttribute(AttributeTemplate template) |
CBOAttribute |
declareAttribute(electric.xml.Element _el,
boolean merge)
Creates a new
CBOAttribute for the given Element and
add it to this CBOEntity, if there isnt already defined an
attribute with the same key |
java.util.List |
getActionList() |
java.util.Map |
getActionMap() |
java.util.List<java.lang.Class> |
getClassesUpToPreviousEntity() |
java.lang.String |
getComment() |
java.lang.Boolean |
getDefaultLookupCaseSensitive() |
java.lang.String |
getDefaultLookupProperty() |
java.lang.Boolean |
getDefaultLookupStartingWith() |
java.lang.Boolean |
getDefaultLookupSubstring() |
java.lang.String |
getDefaultSelectionFilter()
Returns a filter-clause that acts as a non-interactive filter within a query.
|
java.lang.String |
getDefaultSortDirection(java.lang.String path)
Returns the default sorting direction of the
DefaultSortDefinitionEntry
found under the given path in the defaultSorting for the current EntityI, null otherwise. |
java.util.Map<java.lang.String,DefaultSortDefinitionEntry> |
getDefaultSorting()
Returns the defaultSorting for the current EntityI, recursively
checking the base EntityI-s, too, until a defaultSorting is found.
|
java.lang.Integer |
getDefaultSortLevel(java.lang.String path)
Returns the default sorting level of the
DefaultSortDefinitionEntry
found under the given path in the defaultSorting for the current EntityI, null otherwise. |
java.util.List<java.lang.String> |
getDependentClasses() |
java.lang.Long |
getDiscriminator() |
ExportDefinitionEntry |
getExport(java.lang.String name)
Returns the ExportDefinitionEntry of this EntityI or any of its
super-entities with the passed name if it exists, null otherwise.
|
ExportDefinitionEntry |
getExport(java.lang.String name,
boolean includeSuper)
Returns the ExportDefinitionEntry of this EntityI with the passed
name if it exists, null otherwise.
|
java.util.List<ExportDefinitionEntry> |
getExports()
Returns a list of all ExportDefinitionEntry-s for this EntityI
or any of its super-entities.
|
java.util.List<ExportDefinitionEntry> |
getExports(boolean includeSuper)
Returns a list of all ExportDefinitionEntry-s for this EntityI.
|
java.lang.Float |
getFTSBoost() |
GDPRPolicy |
getGDPRPolicy() |
java.lang.String |
getGenerateAs() |
java.lang.String |
getGenerateAsFQName()
Returns the full qualified name of this
CBOEntity |
java.lang.String |
getGenerateAsName()
Returns the name, which this
CBOEntity was generated as |
java.lang.String |
getGenerateAsPackage()
Returns the package, which this
CBOEntity was generated |
java.lang.String |
getGuiTip(java.lang.String tip)
Returns the gui tip for the given key from the current EntityI or one of its super EntityI-s.
|
java.lang.String |
getGuiTip(java.lang.String tip,
boolean inherited)
Returns the gui tip for the given key from the current EntityI.
|
int |
getGuiTipAsInt(java.lang.String tip)
Returns the gui tip for the given key from the current entity or one of its super EntityI-s as int.
|
int |
getGuiTipAsInt(java.lang.String tip,
boolean inherited)
Returns the gui tip for the given key from the current entity as int.
|
java.util.Map |
getGuiTips() |
java.lang.Boolean |
getIndexedForFTS() |
java.util.List<Initialdata> |
getInitialdata() |
java.lang.String |
getL10nName()
Returns the localized singular name of this entity.
|
java.lang.String |
getL10nName(boolean returnKeyWhenNotFound)
Returns the localized singular name of this entity, with configurable fallback behavior.
|
java.lang.String |
getL10nNameKey()
Returns the localization key for the singular name of this entity.
|
java.lang.String |
getL10nNameVar()
Returns a localizable String variable reference for the singular name of this entity.
|
java.lang.String |
getL10nPlural()
Returns the localized plural name of this entity.
|
java.lang.String |
getL10nPlural(boolean returnKeyWhenNotFound)
Returns the localized plural name of this entity, with configurable fallback behavior.
|
java.lang.String |
getL10nPluralKey()
Returns the localization key for the plural name of this entity.
|
java.lang.String |
getL10nPluralVar()
Returns a localizable String variable reference for the plural name of this entity.
|
java.lang.Boolean |
getLinkOnly()
Checks if the linkOnly-flag is set for this
EntityI or one of its base EntityI-s. |
java.lang.Class |
getPersistenceAspectClass()
Returns the generateAs-class for the current EntityI
|
java.util.HashSet |
getRefs() |
java.util.Map |
getRelationObjects(java.lang.Object bo,
java.lang.String attributeName)
Returns a map containing the relation for a single attribute of a bo of this
EntityI |
java.lang.Integer |
getReportFontSizeBig() |
java.lang.Integer |
getReportFontSizeNormal() |
java.lang.String |
getReportOrientation() |
java.lang.String |
getReportTitle() |
int |
getScope() |
java.lang.String |
getSerializationRelevantDescription()
Returns the serialization relevant description for this
CBOEntity
The description will be calculated by concatinating relevant informations of this
CBOEntity, means the full qualified name, the base entity, the attributes,... |
java.lang.String |
getSerializationRelevantDiff(EntityI another)
Returns the serialization relevant difference between a given
EntityI
and this CBOEntity, while the given EntityI will be taken
as the "newer" schema |
long |
getSerialVersionUID()
Returns the serial version unique ID for this
CBOEntity by
using only the first 8 digits from a SHA-message digest of the serialization
relevant description of this CBOEntity |
EntityToStringWrapper |
getToStringWrapper()
Returns the
EntityToStringWrapper for this CBOEntity |
java.lang.Object |
getValue(java.lang.Object o,
AttributeI[] attchain)
Deprecated.
|
java.lang.Object |
getValue(java.lang.Object bo,
java.lang.String attributeName)
Returns the value contained in the given BO and reached via the given attPath.
|
java.lang.String |
getValueAsString(java.lang.Object o,
AttributeI[] attchain)
Deprecated.
|
java.lang.String |
getValueAsString(java.lang.Object bo,
java.lang.String attributeName)
Returns the value contained in the given BO and reached via the given attPath as String.
|
java.lang.String |
getVersionRelevantDescription()
Returns the version relevant description for this
CBOEntity by concatinating
relevant informations of this CBOEntity as String |
boolean |
hasGuiTip(java.lang.String tip)
Checks if the current EntityI or one of its super EntityI-s has a gui tip with the given key.
|
boolean |
hasGuiTip(java.lang.String tip,
boolean inherited)
Checks if the current EntityI has a gui tip with the given key.
|
boolean |
hasRelationObject(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object hasMe)
Returns
true if the given object is part of the relation specified via its attribute name in the given bo |
void |
info(electric.xml.Element _el,
java.lang.String _msg)
Convenience method for logging an info with element prefix (log info messages)
|
void |
info(java.lang.String _msg)
Convenience method for info(_el=Element,_msg=String) with the el of this
CBOEntity as parameter |
boolean |
isForbidDirectChanges() |
boolean |
isGenerate() |
boolean |
isIgnoreReverseRelations()
Returns if the flag for ignoring reverse relations is set to this
CBOEntity
(or his base entity) |
boolean |
isLinkOnly()
Checks if the linkOnly-flag is set for this
EntityI or one of its base EntityI-s. |
boolean |
isLoadImmediate() |
boolean |
isLocal()
Checks if the scope for this
CBOEntity is set to local scope |
boolean |
isLowInstanceCount()
Returns the boolean value of lowInstanceCount if set, if lowInstanceCount isnt set it will look for
lowInstanceCount of the baseEntity too.
|
boolean |
isMapping() |
boolean |
isNoAbstractWarning() |
boolean |
isNoStreamResourceHistory() |
boolean |
isRegenerated() |
boolean |
isStreamResource() |
void |
releaseDefinitionSource()
Cleans the xml definition from all attributes of the current Entity
|
void |
removeRelationObject(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object removeMe)
Removes the given object from the relation specified via its attribute name in the given bo
|
void |
setActionList(java.util.List $83) |
void |
setActionMap(java.util.Map $82) |
void |
setComment(java.lang.String $86) |
void |
setDependentClasses(java.util.List<java.lang.String> $87) |
void |
setDiscriminator(java.lang.Long id)
Sets the Discriminator (i.e. the BOT Id) for this
EntityI |
void |
setFTSBoost(java.lang.Float $96) |
void |
setGDPRPolicy(GDPRPolicy $97) |
void |
setGenerate(boolean $79) |
void |
setGenerateAs(java.lang.String $85) |
void |
setGuiTips(java.util.Map $88) |
void |
setIndexedForFTS(java.lang.Boolean $95) |
void |
setLinkOnly(java.lang.Boolean _linkOnly)
Sets the linkOnly flag for this
CBOEntity to the given value. |
void |
setMapping(boolean $81) |
void |
setNoAbstractWarning(boolean $80) |
void |
setNoStreamResourceHistory(boolean $90) |
void |
setRefs(java.util.HashSet $84) |
void |
setRegenerated(boolean $77) |
void |
setReportFontSizeBig(java.lang.Integer $94) |
void |
setReportFontSizeNormal(java.lang.Integer $93) |
void |
setReportOrientation(java.lang.String $92) |
void |
setReportTitle(java.lang.String $91) |
void |
setScope(int $78) |
void |
setStreamResource(boolean $89) |
void |
setValue(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object value)
Sets the given value in the given bo using the given attPath.
|
void |
setValueAsString(java.lang.Object bo,
java.lang.String attributeName,
java.lang.String value)
Sets the given value as
String to the given bo using the given attPath. |
void |
setValueAsString(java.lang.Object bo,
java.lang.String attributeName,
java.lang.String value,
boolean _checkConstraints)
Sets the given value as
String in the given bo using the given attPath. |
java.lang.String |
toString() |
void |
warn(electric.xml.Element _el,
java.lang.String _msg)
Convenience method for logging an warning with element prefix (log debug messages)
|
void |
warn(java.lang.String _msg)
Convenience method for warn(_el=Element,_msg=String) with the el of this
CBOEntity as parameter |
addAttribute, asXMLElement, checkDescription, checkValidSqlName, equals, getAllAttributeMap, getAttributeAllMap, getAttributeDefinitions, getAttributeList, getAttributeMap, getBase, getBaseEntity, getClazz, getCustomClassInModulesOrProject, getDescription, getEl, getFolderName, getFQName, getFrappingAttributes, getImplementedSchemaInterfaces, getImplementedSchemaInterfaces, getModulePackages, getName, getNonPersistentAttributes, getOrCreateCustomClassInModulesOrProjectSet, getOrCreateModulePackagesSet, getPackage, getPackageAsPath, getPlural, getSchema, getSingleAttribute, getSqlName, getSqlName, getSubEntityList, hashCode, hasSubEntities, initCaches, isCustom, isPersistent, isUserAbstract, of, of, of, of, of, setAllAttributeMap, setAttributeAllMap, setAttributeDefinitions, setAttributeList, setAttributeMap, setBase, setBaseEntity, setClazz, setCustom, setDescription, setEl, setFolderName, setName, setPersistent, setPlural, setSchema, setSqlName, setSqlName, setSubEntityList, setUserAbstract, writeSchemaDefinitionfindReachableAttrsWithType, findReachableAttrsWithType, getFQName, getFromNodes, getIncomingEdges, getOutgoingEdges, getPackage, getPackageAsPath, getToNodes, getToolTipTextForAttribute, isCoreEntity, isCoreEntityClass, isCoreEntityPackageName, isCoreNative, isModuleNative, isPartOfModule, isProjectEntity, isProjectEntityClass, isProjectEntityPackageName, isProjectNative, parametersToString, toEntitiesfilterAttributes, getAllAttributeList, getAllAttributeList, getAllAttributeList, getAllAttributeListByType, getAllAttributeListByType, getAllAttributeListByType, getAllAttributeListByType, getAllAttributeListWithoutSubentities, getAllAttributeListWithoutSubentities, getAllCoreAttributeList, getAllModuleAttributeList, getAllProjectAttributeList, getAllSubEntityList, getAllSubEntityList, getAllSubEntityList, getAttChain, getAttChain, getAttribute, getAttribute, getBaseEntity, getPersistentBaseEntity, getSubEntityList, hasPersistentSubentity, hasSubEntities, isEffectivelyPersistent, isImplicitlyPersistent, isSubEntityOf, isSubEntityOfgetAttributeList, getAttributeListByType, getAttributeListByType, getClazz, getCurrentModuleOrProject, getCustomClassInModulesOrProject, getDescription, getFolderName, getImplementedSchemaInterfaces, getImplementedSchemaInterfaces, getModulePackages, getName, getOrCreateCustomClassInModulesOrProjectSet, getOrCreateModulePackagesSet, getPlural, getRelations, getSchema, getSingleAttribute, isCustom, isCustom, isPersistent, isUserAbstract, newInstancepublic CBOEntity(CBOSchema _schema, electric.xml.Element _el)
_schema - The schema for this entity._el - The Element for this entity.public CBOEntity(CBOSchema _schema, electric.xml.Element _el, int _scope)
_schema - The schema for this entity._el - The Element for this entity._scope - The scope for this entity.public java.util.List<Initialdata> getInitialdata()
public java.lang.Boolean getIndexedForFTS()
getIndexedForFTS in interface EntityIBoolean.TRUE if this EntityI or any of its super-EntityI-s is indexed for fulltext search.public boolean isForbidDirectChanges()
isForbidDirectChanges in interface EntityItrue if direct changes to objects with this EntityI are forbiddenpublic void releaseDefinitionSource()
public java.lang.String getL10nNameKey()
EntityIEntityI.PREFIX_L10N_KEY to a canonicalized
version of the entity's name (obtained via L10n.stringToKey(getName())).getL10nNameKey in interface EntityIpublic java.lang.String getL10nNameVar()
EntityIEntityI.getL10nNameKey(). This format is typically used in UI or template systems
to dynamically load localized strings.getL10nNameVar in interface EntityIpublic java.lang.String getL10nName()
EntityIEntityI.getL10nName(boolean) with fallback enabled.getL10nName in interface EntityIpublic java.lang.String getL10nName(boolean returnKeyWhenNotFound)
EntityIL10n.msg(String, Object[], Object[], boolean, String)
to retrieve the translation, passing this entity as a participant in the lookup path.getL10nName in interface EntityIreturnKeyWhenNotFound - If true, the localization key will be returned if no matching translation is found.
If false, null is returned in that case.public java.lang.String getL10nPluralKey()
EntityIEntityI.PREFIX_L10N_KEY, a canonicalized version
of the entity's name, and EntityI.SUFFIX_L10N_PLURAL_KEY.getL10nPluralKey in interface EntityIpublic java.lang.String getL10nPluralVar()
EntityIEntityI.getL10nPluralKey(). This format is typically used in UI or template systems
to dynamically load localized plural strings.getL10nPluralVar in interface EntityIpublic java.lang.String getL10nPlural()
EntityIEntityI.getL10nPlural(boolean) with fallback enabled.getL10nPlural in interface EntityIpublic java.lang.String getL10nPlural(boolean returnKeyWhenNotFound)
EntityIEntityI.PREFIX_L10N_KEY, getName(), and EntityI.SUFFIX_L10N_PLURAL_KEY)
and typically uses L10n.msg(String, Object[], Object[], boolean, String)
to retrieve the translation, passing this entity as a participant in the lookup path.getL10nPlural in interface EntityIreturnKeyWhenNotFound - If true, the constructed localization key will be returned if no matching translation is found.
If false, null is returned in that case.public java.lang.Class getPersistenceAspectClass()
EntityIgetPersistenceAspectClass in interface EntityIpublic java.lang.String toString()
public void config(electric.xml.Element elEntity,
boolean fromConstructor)
elEntity - The Element for this entity.fromConstructor - Indicates whether this method is called by the constructor.public CBOAttribute declareAttribute(electric.xml.Element _el, boolean merge)
CBOAttribute for the given Element and
add it to this CBOEntity, if there isnt already defined an
attribute with the same key_el - the Element to declare CBOAttribute formerge - seems to be unused hereCBOAttributeEntityDefinitionException - if an Attribute with the same key then the Element is already definedpublic CBOAttribute declareAttribute(AttributeTemplate template)
public void addDependents(java.lang.String s)
String,
to the dependent classess - the classes to add as comma separated Stringpublic boolean isLocal()
CBOEntity is set to local scopetrue if the scope is set to local scopepublic java.util.List<java.lang.Class> getClassesUpToPreviousEntity()
getClassesUpToPreviousEntity in interface EntityIpublic boolean isIgnoreReverseRelations()
CBOEntity
(or his base entity)true if the flag is set to this CBOEntity (or his base entity)public void setDiscriminator(java.lang.Long id)
EntityIEntityIsetDiscriminator in interface EntityIid - the id to set as discriminatorpublic long getSerialVersionUID()
CBOEntity by
using only the first 8 digits from a SHA-message digest of the serialization
relevant description of this CBOEntityCBOEntitypublic boolean isLoadImmediate()
isLoadImmediate in interface EntityIfalse if loadImmediate wasn"t
set and couldn"t be retrieved from a base entitypublic java.lang.Boolean getLinkOnly()
EntityIEntityI or one of its base EntityI-s.
If the linkOnly-flag is set for a base EntityI, as a side-effect it will be set for this EntityI too!getLinkOnly in interface EntityIBoolean.TRUE if the linkOnly-flag is setpublic boolean isLinkOnly()
EntityIEntityI or one of its base EntityI-s.
If the linkOnly-flag is set for a base EntityI, as a side-effect it will be set for this EntityI too!isLinkOnly in interface EntityItrue if the linkOnly-flag is setpublic void setLinkOnly(java.lang.Boolean _linkOnly)
CBOEntity to the given value._linkOnly - The value to set for the linkOnly flag.public java.lang.String getGuiTip(java.lang.String tip)
EntityIpublic java.lang.String getGuiTip(java.lang.String tip,
boolean inherited)
EntityIpublic int getGuiTipAsInt(java.lang.String tip)
EntityIgetGuiTipAsInt in interface EntityItip - the key for the tip to returnpublic int getGuiTipAsInt(java.lang.String tip,
boolean inherited)
EntityIgetGuiTipAsInt in interface EntityItip - the key for the tip to returninherited - a boolean indicating whether to check for inherited tips toopublic boolean hasGuiTip(java.lang.String tip)
EntityIpublic boolean hasGuiTip(java.lang.String tip,
boolean inherited)
EntityIpublic java.util.Map<java.lang.String,DefaultSortDefinitionEntry> getDefaultSorting()
EntityIgetDefaultSorting in interface EntityIMappublic java.lang.String getDefaultSortDirection(java.lang.String path)
EntityIDefaultSortDefinitionEntry
found under the given path in the defaultSorting for the current EntityI, null otherwise.getDefaultSortDirection in interface EntityIpath - the path of the DefaultSortDefinitionEntry in defaultSortingDefaultSortDefinitionEntry with the given path as Stringpublic java.lang.Integer getDefaultSortLevel(java.lang.String path)
EntityIDefaultSortDefinitionEntry
found under the given path in the defaultSorting for the current EntityI, null otherwise.getDefaultSortLevel in interface EntityIpath - the path of the DefaultSortDefinitionEntry in defaultSortingDefaultSortDefinitionEntry with the given path as Integerpublic java.lang.String getDefaultSelectionFilter()
EntityIgetDefaultSelectionFilter in interface EntityIpublic java.lang.String getDefaultLookupProperty()
getDefaultLookupProperty in interface EntityIpublic java.lang.Boolean getDefaultLookupSubstring()
getDefaultLookupSubstring in interface EntityIBoolean.TRUE if this EntityI or one of its base EntityI-s has a default lookup Stringpublic java.lang.Boolean getDefaultLookupStartingWith()
getDefaultLookupStartingWith in interface EntityIBoolean.TRUE if this EntityI or one of its base EntityI-s only allows lookup for prefixes by defaultpublic java.lang.Boolean getDefaultLookupCaseSensitive()
getDefaultLookupCaseSensitive in interface EntityIBoolean.TRUE if this EntityI or one of its base EntityI-s performs lookups case-insensitive by defaultpublic java.lang.String getGenerateAsName()
CBOEntity was generated asCBOEntity was generated aspublic java.lang.String getGenerateAsPackage()
CBOEntity was generatedCBOEntity was generatedpublic java.lang.String getGenerateAsFQName()
CBOEntityCBOEntitypublic boolean isStreamResource()
isStreamResource in interface EntityItrue if the current EntityI or one of its base EntityIs is a stream ressourcepublic boolean isNoStreamResourceHistory()
isNoStreamResourceHistory in interface EntityItrue if the current EntityI or one of its base EntityIs was told to keep
no history of its stream ressource when a stream resource is replaced by a different onepublic boolean isLowInstanceCount()
false if lowInstanceCount wasnt
set and couldn't be retrieved from the base entitypublic java.lang.String getReportTitle()
getReportTitle in interface EntityInull if report title wasn"t set and couldn"t be
retrieved from a base entitypublic java.lang.String getReportOrientation()
getReportOrientation in interface EntityInull if report orientation wasn"t set and
couldn"t be retrieved from a base entitypublic java.lang.Integer getReportFontSizeNormal()
getReportFontSizeNormal in interface EntityInull if the report"s normal font size wasn"t set and
couldn"t be retrieved from a base entitypublic java.lang.Integer getReportFontSizeBig()
getReportFontSizeBig in interface EntityInull if the report"s big font size wasn"t set and
couldn"t be retrieved from a base entitypublic java.util.List<ExportDefinitionEntry> getExports()
EntityIgetExports in interface EntityIpublic java.util.List<ExportDefinitionEntry> getExports(boolean includeSuper)
EntityIgetExports in interface EntityIincludeSuper - a boolean which denotes if also exports from
all super-entities shall be included.public ExportDefinitionEntry getExport(java.lang.String name)
EntityIpublic ExportDefinitionEntry getExport(java.lang.String name, boolean includeSuper)
EntityIgetExport in interface EntityIname - the name of the ExportDefinitionEntry to returnincludeSuper - a boolean which denotes if also exports from
all super-entities shall be searched.public java.lang.Object getValue(java.lang.Object bo,
java.lang.String attributeName)
EntityIpublic java.lang.String getValueAsString(java.lang.Object bo,
java.lang.String attributeName)
EntityIgetValueAsString in interface EntityIbo - the bo to get the value fromattributeName - the path to the attribute to get the value fromStringpublic void setValue(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object value)
EntityIpublic void setValueAsString(java.lang.Object bo,
java.lang.String attributeName,
java.lang.String value)
EntityIString to the given bo using the given attPath.
Does check for constraints before setting the value.setValueAsString in interface EntityIbo - the bo to set the given value inattributeName - the path to the attribute to setvalue - the value to set as Stringpublic void setValueAsString(java.lang.Object bo,
java.lang.String attributeName,
java.lang.String value,
boolean _checkConstraints)
EntityIString in the given bo using the given attPath.setValueAsString in interface EntityIbo - the bo to set the given value inattributeName - the path to the attribute to setvalue - the value to set as String_checkConstraints - do check for constraints before setting valuepublic java.util.Map getRelationObjects(java.lang.Object bo,
java.lang.String attributeName)
EntityIEntityIgetRelationObjects in interface EntityIbo - the bo to get relations forattributeName - the attribute to get relations forpublic boolean hasRelationObject(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object hasMe)
EntityItrue if the given object is part of the relation specified via its attribute name in the given bohasRelationObject in interface EntityIbo - the bo to check the relational object on the attributeattributeName - the name of the attribute to check the relational object onhasMe - the relational object to checkpublic void addRelationObject(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object addMe)
EntityIaddRelationObject in interface EntityIbo - the bo to add the relational object to the attributeattributeName - the name of the attribute to add the relational object toaddMe - the relational object to add to the attribute on the bopublic void removeRelationObject(java.lang.Object bo,
java.lang.String attributeName,
java.lang.Object removeMe)
EntityIremoveRelationObject in interface EntityIbo - the bo to remove the relational object from the attributeattributeName - the name of the attribute to remove the relational object fromremoveMe - the relational object to remove@Deprecated
public java.lang.Object getValue(java.lang.Object o,
AttributeI[] attchain)
o - the attribute to get the value forattchain - the attribute chain to get the value for the given attribute from@Deprecated
public java.lang.String getValueAsString(java.lang.Object o,
AttributeI[] attchain)
Stringo - the attribute to get the value forattchain - the attribute chain to get the value for the given attribute fromStringpublic void buildPass2()
public void buildPass2ForAttribute(CBOAttribute cboatt)
cboatt - the CBOAttribute to check clashes forAttributeDefinitionException - if the given CBOAttribute was already defined for
this CBOEntity as attribute or singular of attributepublic void checkClass()
CBOSchema#verify() during building and warns early.public void checkRelations(int pass)
CBOEntitypass - the passing of this checkAttributeDefinitionException - if an Entity was unknown or
if an virtual or non-persistent attribute was defined n-m (only n-1 or 1-n allowed)
if the backrelation of an attribute has not the same persistence or readonly setting
if the relationtypes dont match each other
if backrelation isn''t availablepublic void checkBackRelations()
CBOEntityAttributeDefinitionException - if an attribute has no backrelationpublic void checkAmbiguousRelations()
CBOEntity for ambiguos problemsIRuntimeException - if relations and backrelations of an attribute dont match each otherpublic void checkAndInitHeritage()
CBOEntity (and its base entities).EntityDefinitionException - If a base entity couldn't be found in the given Map.public void checkAbstractHasConcreteSubs()
CBOEntity has concrete subentitiesall - seems to be unused herepublic void checkAggregates()
public void checkAttributeNaming()
Map for collisions of their name or singular with the attributes of
this entity and its possible sub-entities.
If the name of an attribute matches the name of another attribute (possibly in a sub-entity), this will be a problem
as the entity (or at least the sub-entity) would have two attributes with the same name. This is not possible as the
column names in the database would be the same, which is not allowed. Also, the generated set and get methods would
bear the same name, which is not possible.
If the singular of an attribute (which should be a many relation then, though this is not checked here) matches the
singular of another attribute (possibly in a sub-entity), this will cause problems because the generated add and
remove methods would then bear the same name. While technically this might not be a problem in all cases (as it
might still be possible to distinguish them by their argument types), to avoid confusion, this is also not allowed.
Additionally to name vs. name and singular vs. singular checks, this method also checks the names vs. the singulars.
(Note: TT 2021-11-16: I could not think of a reason for this. What clash could occur in this case?)AttributeDefinitionException - If the name or singular of a given attribute matches one of the name or singular
(might also be a "name = singular" collision!) of an attribute of this entity.public void checkAttributeNaming(java.util.Map existingAttsArg)
Map for collisions of their name or singular with the attributes of
this entity and its possible sub-entities.
If the name of an attribute matches the name of another attribute (possibly in a sub-entity), this will be a problem
as the entity (or at least the sub-entity) would have two attributes with the same name. This is not possible as the
column names in the database would be the same, which is not allowed. Also, the generated set and get methods would
bear the same name, which is not possible.
If the singular of an attribute (which should be a many relation then, though this is not checked here) matches the
singular of another attribute (possibly in a sub-entity), this will cause problems because the generated add and
remove methods would then bear the same name. While technically this might not be a problem in all cases (as it
might still be possible to distinguish them by their argument types), to avoid confusion, this is also not allowed.
Additionally to name vs. name and singular vs. singular checks, this method also checks the names vs. the singulars.
(Note: TT 2021-11-16: I could not think of a reason for this. What clash could occur in this case?)existingAttsArg - A Map with already existing attributes to check.AttributeDefinitionException - If the name or singular of a given attribute matches one of the name or singular
(might also be a "name = singular" collision!) of an attribute of this entity.public void checkSingularAbsenceForNTo1()
throws AttributeDefinitionException
AttributeDefinitionException - if relationType is 'n-1' and explicitSingular is not ''public EntityI checkLoadImmediate(java.lang.Boolean _b)
CBOEntity (or its base entity) equals the given value_b - the value to check equality forCBOEntity if both values are equal, else returns nullpublic void checkItemProperties()
public int compareTo(java.lang.Object o)
compareTo in interface java.lang.Comparableo - the Object to compare this CBOEntitypublic java.lang.String getSerializationRelevantDescription()
CBOEntity
The description will be calculated by concatinating relevant informations of this
CBOEntity, means the full qualified name, the base entity, the attributes,...CBOEntitypublic java.lang.String getSerializationRelevantDiff(EntityI another)
EntityI
and this CBOEntity, while the given EntityI will be taken
as the "newer" schemaanother - the EntityI to get the serialization relevant differenceEntityI and this CBOEntitypublic java.lang.String getVersionRelevantDescription()
CBOEntity by concatinating
relevant informations of this CBOEntity as StringCBOEntitypublic EntityToStringWrapper getToStringWrapper()
EntityToStringWrapper for this CBOEntityEntityToStringWrapper for this CBOEntitypublic void info(java.lang.String _msg)
CBOEntity as parameter_msg - the message to logpublic void info(electric.xml.Element _el,
java.lang.String _msg)
_el - the element to get a messageprefix for_msg - the message to logpublic void warn(java.lang.String _msg)
CBOEntity as parameter_msg - the message to logpublic void warn(electric.xml.Element _el,
java.lang.String _msg)
_el - the element to get a messageprefix for_msg - the message to logpublic boolean isRegenerated()
public void setRegenerated(boolean $77)
public int getScope()
public void setScope(int $78)
public boolean isGenerate()
public void setGenerate(boolean $79)
public java.lang.Long getDiscriminator()
getDiscriminator in interface EntityIEntityIpublic boolean isNoAbstractWarning()
public void setNoAbstractWarning(boolean $80)
public boolean isMapping()
public void setMapping(boolean $81)
public java.util.Map getActionMap()
public void setActionMap(java.util.Map $82)
public java.util.List getActionList()
getActionList in interface EntityIEntityIpublic void setActionList(java.util.List $83)
public java.util.HashSet getRefs()
public void setRefs(java.util.HashSet $84)
public java.lang.String getGenerateAs()
public void setGenerateAs(java.lang.String $85)
public java.lang.String getComment()
public void setComment(java.lang.String $86)
public java.util.List<java.lang.String> getDependentClasses()
getDependentClasses in interface EntityIpublic void setDependentClasses(java.util.List<java.lang.String> $87)
public java.util.Map getGuiTips()
public void setGuiTips(java.util.Map $88)
public void setStreamResource(boolean $89)
public void setNoStreamResourceHistory(boolean $90)
public void setReportTitle(java.lang.String $91)
public void setReportOrientation(java.lang.String $92)
public void setReportFontSizeNormal(java.lang.Integer $93)
public void setReportFontSizeBig(java.lang.Integer $94)
public void setIndexedForFTS(java.lang.Boolean $95)
public java.lang.Float getFTSBoost()
getFTSBoost in interface EntityIpublic void setFTSBoost(java.lang.Float $96)
public GDPRPolicy getGDPRPolicy()
getGDPRPolicy in interface EntityIpublic void setGDPRPolicy(GDPRPolicy $97)
Copyright © 2000-2025 OAshi S.à r.l. All Rights Reserved.