Package com.storedobject.accounts
Class BusinessEntity
- All Implemented Interfaces:
Displayable
,StringFiller
,HasContacts
,HasId
,HasName
,HasShortName
Business entity - Used by
EntityAccount
.
Note (1): Contact grouping code (getContactGroupingCode()
) for this class is 10192.
Note (2): You typically extend the EntityAccount
to customize party-related attributes.
- Author:
- Syam
-
Field Summary
Fields inherited from class com.storedobject.core.StoredObject
logger
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Adds columns to the given Columns object.static BusinessEntity
createFor
(TransactionManager tm, Id entityId) Creates a BusinessEntity (if not already exists) for the specified entityId using the given TransactionManager.int
Returns the contact grouping code for the given class.Retrieves the entity associated with this account entity.Retrieves the ID of the business entity.static BusinessEntity
Retrieves the business entity for the given entity ID.getName()
Retrieves the name of the business entity associated with this account entity.Returns the class representing the party associated with this entity.protected Id
Retrieves the party ID.static void
Adds the specified column list to the indices.void
Sets the entity for this object.void
Sets the entity for this object.void
setEntity
(BigDecimal idValue) Sets the entity of the party.protected void
setPartyId
(Id id) Sets the party ID for the current entity.Methods inherited from class com.storedobject.accounts.AccountEntity
browseColumns, get, getAddress, getEmail, getParty, getPhone, getPrimaryAddress, getPrimaryAddressValue, getPrimaryEmail, getPrimaryPhone, getShortName, getTaxCode, isBusiness, isPersonal, list, setParty, setParty, setPrimaryAddress, setPrimaryEmail, setPrimaryPhone, setShortName, setTaxCode, toString, validateData
Methods inherited from class com.storedobject.core.StoredObject
addLink, addLink, addLink, addLink, addLink, addLink, addLink, addLink, checkCurrency, checkCurrency, checkForDuplicate, checkForDuplicate, checkTimeZone, checkTransaction, clearObjectLinks, contemporary, copy, copy, count, count, count, count, count, count, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countLinks, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, countMasters, create, created, delete, delete, delete, deleted, directUpdate, equals, exists, exists, exists, exists, exists, existsFileData, existsLink, existsLink, existsLink, existsLink, existsLink, existsLink, existsLink, existsLink, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsLinks, existsMaster, existsMaster, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, existsMasters, family, family, family, fill, get, get, get, get, get, get, get, get, get, get, get, get, get, get, get, get, get, get, getAttachment, getAttachmentId, getChildren, getDeleted, getDeleted, getExistsCondition, getExistsCondition, getFileData, getFileData, getHistorical, getId, getKeyIndex, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getMaster, getNotExistsCondition, getNotExistsCondition, getParent, getParent, getParent, getParentId, getParentId, getParentId, getRelated, getRelated, getTransaction, getTransactionId, getTransactionIP, getUnique, getUniqueCondition, hashCode, inserted, isModified, isVirtual, list, list, list, list, list, list, list, list, list, list, list, list, list, listFileData, listFileData, listHistory, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listLinks, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listMasters, listTree, listTree, listTree, listTree, listViaQuery, listViaQuery, load, load, load, load, loaded, loading, makeNew, makeVirtual, migrate, moduleName, nextVersion, objectLink, objectLink, objectLink, objectLinks, objectLinks, old, person, previousVersion, previousVersion, query, query, query, query, query, query, query, query, query, query, query, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryLinks, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, queryMasters, reload, reload, reloaded, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeAllLinks, removeLink, removeLink, removeLink, removeLink, removeLink, removeLink, removeLink, removeLink, removeLink, removeLink, removeLink, removeLink, removeReverseLinks, removeReverseLinks, save, save, save, save, save, save, save, save, save, save, save, save, save, save, saved, saving, setMaster, setRawValue, setTransaction, stringify, tableName, timestamp, toCode, toDisplay, transacting, undelete, undelete, undeleted, updated, user, userId, validate, validateChildAttach, validateChildDetach, validateChildUpdate, validateDelete, validateInsert, validateParentAttach, validateParentDetach, validateParentUpdate, validateUndelete, validateUpdate, valueEquals
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.storedobject.core.HasContacts
getAddress, getContact, getContact, getContactObject, getContactObject, getContactObject, getContactOwnerId, getContactRaw, getContactRaw, getEmail, getId, getMobile, getPhone, getTelegram, listContacts, listContactTypes, setContact, setContact
-
Constructor Details
-
BusinessEntity
public BusinessEntity()This class represents a business entity.Note: Contact grouping code for this class is 10192.
-
-
Method Details
-
columns
Adds columns to the given Columns object.- Parameters:
columns
- The Columns object to which the columns will be added
-
indices
Adds the specified column list to the indices.- Parameters:
indices
- The Indices object to add the column list to.
-
setPartyId
Sets the party ID for the current entity.- Specified by:
setPartyId
in classAccountEntity<Entity>
- Parameters:
id
- The ID of the party to be set.
-
getPartyId
Retrieves the party ID.- Specified by:
getPartyId
in classAccountEntity<Entity>
- Returns:
- The party ID.
-
setEntity
Sets the entity of the party.- Parameters:
idValue
- the value of the entity ID
-
setEntity
Sets the entity for this object.- Parameters:
personId
- the identifier of the person entity to be set
-
setEntity
Sets the entity for this object.- Parameters:
person
- The entity to set. (null is allowed)
-
getEntity
Retrieves the entity associated with this account entity. If the entity is not already initialized, it retrieves the related instance from the database using the entity class and entity id. If the instance is old, it might return an old instance.- Returns:
- The entity associated with this account entity, or null if it is not available for the given parameters.
-
getEntityId
Retrieves the ID of the business entity.- Returns:
- The ID of the business entity.
-
getPartyClass
Returns the class representing the party associated with this entity.- Specified by:
getPartyClass
in classAccountEntity<Entity>
- Returns:
- The class representing the party.
-
getName
Retrieves the name of the business entity associated with this account entity.- Specified by:
getName
in interfaceHasContacts
- Specified by:
getName
in interfaceHasName
- Specified by:
getName
in classAccountEntity<Entity>
- Returns:
- The name of the business entity
-
getContactGroupingCode
public int getContactGroupingCode()Returns the contact grouping code for the given class.- Returns:
- The contact grouping code. This value is always 10192.
-
getFor
Retrieves the business entity for the given entity ID.- Parameters:
entityId
- The ID of the entity.- Returns:
- The business entity associated with the given entity ID.
-
createFor
Creates a BusinessEntity (if not already exists) for the specified entityId using the given TransactionManager.- Parameters:
tm
- The TransactionManager instance to be used for database transactions.entityId
- The ID of the entity for which the BusinessEntity is created.- Returns:
- The already existing or created BusinessEntity object.
- Throws:
Exception
- If an error occurs while creating or saving the BusinessEntity.
-