Package cz.o2.proxima.core.repository
Interface EntityDescriptor
- 
- All Superinterfaces:
- java.io.Serializable
 - All Known Implementing Classes:
- EntityDescriptorImpl
 
 @Stable public interface EntityDescriptor extends java.io.Serializable An interface representing descriptor of entity.
- 
- 
Nested Class SummaryNested Classes Modifier and Type Interface Description static classEntityDescriptor.BuilderBuilder of the descriptor.
 - 
Method SummaryAll Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default <T> java.util.Optional<AttributeDescriptor<T>>findAttribute(java.lang.String name)Find attribute by name.<T> java.util.Optional<AttributeDescriptor<T>>findAttribute(java.lang.String name, boolean includeProtected)Find attribute by name.default java.util.List<AttributeDescriptor<?>>getAllAttributes()List all attribute descriptors of given entity.java.util.List<AttributeDescriptor<?>>getAllAttributes(boolean includeProtected)Find all attributes of this entity.default <T> AttributeDescriptor<T>getAttribute(java.lang.String name)Get attribute by name.default <T> AttributeDescriptor<T>getAttribute(java.lang.String name, boolean includeProtected)Get attribute by name.java.lang.StringgetName()Name of the entity.default booleanisSystemEntity()default booleanisTransactional()static EntityDescriptor.BuildernewBuilder()
 
- 
- 
- 
Method Detail- 
newBuilderstatic EntityDescriptor.Builder newBuilder() 
 - 
getNamejava.lang.String getName() Name of the entity.- Returns:
- name of the entity
 
 - 
findAttribute<T> java.util.Optional<AttributeDescriptor<T>> findAttribute(java.lang.String name, boolean includeProtected) Find attribute by name.- Type Parameters:
- T- value type
- Parameters:
- name- name of the attribute to search for
- includeProtected-- trueto allow search for protected fields (prefixed by _).
- Returns:
- optional found attribute descriptor
 
 - 
findAttributedefault <T> java.util.Optional<AttributeDescriptor<T>> findAttribute(java.lang.String name) Find attribute by name. Do not search protected fields (prefixed by _).- Type Parameters:
- T- value type
- Parameters:
- name- name of the attribute to search for
- Returns:
- optional found attribute descriptor
 
 - 
getAttributedefault <T> AttributeDescriptor<T> getAttribute(java.lang.String name, boolean includeProtected) Get attribute by name.- Type Parameters:
- T- value type
- Parameters:
- name- name of the attribute to search for
- includeProtected-- trueto allow search for protected fields (prefixed by _).
- Returns:
- attribute descriptor
 
 - 
isTransactionaldefault boolean isTransactional() - Returns:
- trueif the entity contains any attribute that has transactions enabled.
 
 - 
isSystemEntitydefault boolean isSystemEntity() - Returns:
- trueif this is system entity. System entities are created by the platform itself and should be (directly) accessed by users.
 
 - 
getAttributedefault <T> AttributeDescriptor<T> getAttribute(java.lang.String name) Get attribute by name.- Type Parameters:
- T- value type
- Parameters:
- name- name of the attribute to search for
- Returns:
- attribute descriptor
 
 - 
getAllAttributesjava.util.List<AttributeDescriptor<?>> getAllAttributes(boolean includeProtected) Find all attributes of this entity.- Parameters:
- includeProtected- when- truethen protected attributes are also included (prefixed by _).
- Returns:
- all attributes of entity (including protected or not)
 
 - 
getAllAttributesdefault java.util.List<AttributeDescriptor<?>> getAllAttributes() List all attribute descriptors of given entity.- Returns:
- get all unprotected attributes of entity
 
 
- 
 
-