Package io.higson.runtime.model.proxy
Class DomainObjectProxy
java.lang.Object
io.higson.runtime.model.proxy.DomainObjectProxy
- All Implemented Interfaces:
DomainObject
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleangetAttrBoolean(String attrCode, HigsonContext ctx) getAttrDate(String attrCode, HigsonContext ctx) getAttrDecimal(String attrCode, HigsonContext ctx) getAttribute(String code) getAttribute(String path, String attributeCode) getAttributeValue(String path, String attributeCode, ParamContext ctx, Object... args) getAttrInteger(String attrCode, HigsonContext ctx) doublegetAttrNumber(String attrCode, HigsonContext ctx) getAttrString(String attrCode, HigsonContext ctx) path to this object in the form in which it was used (the object can be reached using different paths).getChildren(String propCode) getCode()calculates and returns element's digest.getDynamicAttribute(String code) getFromAllAttributes(String code) getId()getName()getPath()booleanisAttrDefined(String code) booleanbooleanisLocalAttr(String code) booleanisRoot()static StringrejectLastToken(String path) static Stringstatic Stringnormalizes path, path is never null valid paths: / /a /a/b/cstatic Stringnull, null : / null, " " : / "", " " : / a, null : /a null, b : /b null, /b : /b /a, 'b : /a/btoString()unwrap()
-
Constructor Details
-
DomainObjectProxy
public DomainObjectProxy()
-
-
Method Details
-
getDomain
- Specified by:
getDomainin interfaceDomainObject
-
getCode
- Specified by:
getCodein interfaceDomainObject
-
getName
- Specified by:
getNamein interfaceDomainObject
-
getDescription
- Specified by:
getDescriptionin interfaceDomainObject
-
getTypeCode
- Specified by:
getTypeCodein interfaceDomainObject
-
getTypeName
- Specified by:
getTypeNamein interfaceDomainObject
-
getPath
- Specified by:
getPathin interfaceDomainObject
-
getAttribute
- Specified by:
getAttributein interfaceDomainObject
-
isAttrSet
- Specified by:
isAttrSetin interfaceDomainObject
-
getAttributes
- Specified by:
getAttributesin interfaceDomainObject
-
getDynamicAttribute
- Specified by:
getDynamicAttributein interfaceDomainObject
-
getFromAllAttributes
- Specified by:
getFromAllAttributesin interfaceDomainObject- Parameters:
code- attribute code to look for- Returns:
- found attribute or
Optional.empty()if not found
-
getDynamicAttributes
- Specified by:
getDynamicAttributesin interfaceDomainObject
-
getChild
- Specified by:
getChildin interfaceDomainObject
-
getChildren
- Specified by:
getChildrenin interfaceDomainObject
-
getParent
- Specified by:
getParentin interfaceDomainObject
-
getAttribute
- Specified by:
getAttributein interfaceDomainObject
-
getAttributeValue
public ParamValue getAttributeValue(String path, String attributeCode, ParamContext ctx, Object... args) - Specified by:
getAttributeValuein interfaceDomainObject
-
isRoot
public boolean isRoot()- Specified by:
isRootin interfaceDomainObject
-
isAttrDefined
- Specified by:
isAttrDefinedin interfaceDomainObject
-
isLocalAttr
- Specified by:
isLocalAttrin interfaceDomainObject
-
getAttr
- Specified by:
getAttrin interfaceDomainObject- Parameters:
code- code- Returns:
- attribute of type HigsonDomainAttribute
-
getAttrString
- Specified by:
getAttrStringin interfaceDomainObject- Parameters:
attrCode- attribute codectx- context- Returns:
- attribute as String object
-
getAttrDecimal
- Specified by:
getAttrDecimalin interfaceDomainObject- Parameters:
attrCode- attribute codectx- context- Returns:
- attribute as BigDecimal object
-
getAttrNumber
- Specified by:
getAttrNumberin interfaceDomainObject- Parameters:
attrCode- attribute codectx- context- Returns:
- attribute as double value
-
getAttrInteger
- Specified by:
getAttrIntegerin interfaceDomainObject- Parameters:
attrCode- attribute codectx- context- Returns:
- attribute as Integer object
-
getAttrDate
- Specified by:
getAttrDatein interfaceDomainObject- Parameters:
attrCode- attribute codectx- context- Returns:
- attribute as Data object
-
getAttrBoolean
- Specified by:
getAttrBooleanin interfaceDomainObject- Parameters:
attrCode- attribute codectx- context- Returns:
- attribute as boolean value
-
getId
- Specified by:
getIdin interfaceDomainObject- Returns:
- Integer object
-
getParentId
- Specified by:
getParentIdin interfaceDomainObject- Returns:
- Parent id
-
getCallPath
Description copied from interface:DomainObjectpath to this object in the form in which it was used (the object can be reached using different paths). path is normalized and has the form: / a / b / c- Specified by:
getCallPathin interfaceDomainObject- Returns:
- call path
-
getTypeCollection
- Specified by:
getTypeCollectionin interfaceDomainObject- Returns:
- collection type of HigsonDomainObjectType object
-
getRegion
- Specified by:
getRegionin interfaceDomainObject- Returns:
- region code from MpRegionCached object
-
getTagList
- Specified by:
getTagListin interfaceDomainObject- Returns:
- collection with tags attached to domain object
-
getDigest
Description copied from interface:DomainObjectcalculates and returns element's digest. It includes element's code, type code, attributes digests and region info, if element is attached- Specified by:
getDigestin interfaceDomainObject- Returns:
- domain element's digest
-
unwrap
-
toPath
normalizes path, path is never null valid paths: / /a /a/b/c- Parameters:
domainPath- domain path- Returns:
- String object with path
-
toPath
null, null : / null, " " : / "", " " : / a, null : /a null, b : /b null, /b : /b /a, 'b : /a/b- Parameters:
path1- pathpath2- path- Returns:
- String object with path
-
toElement
-
rejectLastToken
-
getParentPath
-
toString
-