Package io.ebean.plugin
Interface BeanType<T>
public interface BeanType<T>
Information and methods on BeanDescriptors made available to plugins.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddInheritanceWhere(Query<?> query) Add the discriminator value to the query if needed.Collection<? extends Property>Return all the properties for this bean type.Return the base table this bean type maps to.default ObjectDeprecated.BeanType<?>beanTypeAtPath(String propertyName) Return the type bean for an OneToMany or ManyToOne or ManyToMany property.voidClear the bean cache.voidClear the query cache.Create a new instance of the bean.createBeanUsingDisc(Object discValue) Create a bean given the discriminator value.Return the discriminator column.Return the DocumentMapping for this bean type.docStore()Return the doc store support for this bean type.\Return the doc store queueId for this bean type.expressionPath(String path) Return the ExpressionPath for a given property path.Return the beanFinder.fullName()Return the full name of the bean type.default StringDeprecated.Deprecated.Deprecated.default BeanType<?>getBeanTypeAtPath(String propertyName) Deprecated.default StringDeprecated.default DocMappingDeprecated.default StringDeprecated.default ExpressionPathgetExpressionPath(String path) Deprecated.default BeanFindControllerDeprecated.default StringDeprecated.default PropertyDeprecated.default IdTypeDeprecated.Deprecated.default BeanType<?>Deprecated.default StringgetName()Deprecated.default BeanPersistControllerDeprecated.default BeanPersistListenerDeprecated.default PropertygetProperty(String propertyName) Deprecated.default BeanQueryAdapterDeprecated.default PropertyDeprecated.default PropertyDeprecated.booleanReturn true if this bean type has an inheritance hierarchy.Return the bean id.Return the Id property.idType()Return the identity generation type.Returns all direct children of this beantypeBeanType<?>Returns the parent in inheritance hierarchybooleanReturn true if bean caching is on for this bean type.booleanReturn true if this bean type has doc store backing.booleanReturn true if the type is document store only.booleanReturn true if this object is the root level object in its entity inheritance.booleanReturn true if query caching is on for this bean type.booleanisValidExpression(String property) Return true if the property is a valid known property or path for the given bean type.name()Return the short name of the bean type.Return the bean persist controller.Return the bean persist listener.Return the Property to read values from a bean.Return the BeanQueryAdapter or null if none is defined.BeanType<?>root()Return the root bean type for an inheritance hierarchy.default voidDeprecated.voidSet the id value to the bean.type()Return the class type this BeanDescriptor describes.voidvisitAllInheritanceChildren(Consumer<BeanType<?>> visitor) Visit all children recursivelyReturn the when created property if there is one defined.Return the when modified property if there is one defined.
-
Method Details
-
name
Return the short name of the bean type. -
getName
Deprecated.Deprecated migrate to name(). -
fullName
Return the full name of the bean type. -
getFullName
Deprecated.Deprecated migrate to fullName(). -
type
Return the class type this BeanDescriptor describes. -
getBeanType
Deprecated.Deprecated migrate to type(). -
beanTypeAtPath
Return the type bean for an OneToMany or ManyToOne or ManyToMany property. -
getBeanTypeAtPath
Deprecated.Deprecated migrate to beanTypeAtPath(). -
allProperties
Collection<? extends Property> allProperties()Return all the properties for this bean type. -
idProperty
Return the Id property. -
getIdProperty
Deprecated.Deprecated migrate to idProperty(). -
whenModifiedProperty
Return the when modified property if there is one defined. -
getWhenModifiedProperty
Deprecated.Deprecated migrate to idProperty(). -
whenCreatedProperty
Return the when created property if there is one defined. -
getWhenCreatedProperty
Deprecated.Deprecated migrate to idProperty(). -
property
Return the Property to read values from a bean. -
getProperty
Deprecated.Deprecated migrate to property(). -
expressionPath
Return the ExpressionPath for a given property path.This can return a property or nested property path.
-
getExpressionPath
Deprecated.Deprecated migrate to expressionPath(). -
isValidExpression
Return true if the property is a valid known property or path for the given bean type. -
isBeanCaching
boolean isBeanCaching()Return true if bean caching is on for this bean type. -
isQueryCaching
boolean isQueryCaching()Return true if query caching is on for this bean type. -
clearBeanCache
void clearBeanCache()Clear the bean cache. -
clearQueryCache
void clearQueryCache()Clear the query cache. -
isDocStoreOnly
boolean isDocStoreOnly()Return true if the type is document store only. -
baseTable
Return the base table this bean type maps to. -
getBaseTable
Deprecated.Deprecated migrate to baseTable(). -
createBean
T createBean()Create a new instance of the bean. -
id
Return the bean id. This is the same as getBeanId() but without the generic type. -
beanId
Deprecated.Deprecated migrate to id() -
getBeanId
Deprecated.Deprecated migrate to id() -
setId
Set the id value to the bean. -
setBeanId
Deprecated.Deprecated migrate to setId() -
persistController
Return the bean persist controller. -
getPersistController
Deprecated.Deprecated migrate to persistController() -
persistListener
Return the bean persist listener. -
getPersistListener
Deprecated.Deprecated migrate to persistListener() -
findController
Return the beanFinder. Usually null unless overriding the finder. -
getFindController
Deprecated.Deprecated migrate to findController() -
queryAdapter
Return the BeanQueryAdapter or null if none is defined. -
getQueryAdapter
Deprecated.Deprecated migrate to queryAdapter() -
idType
Return the identity generation type. -
getIdType
Deprecated.Deprecated migrate to idType() -
isDocStoreMapped
boolean isDocStoreMapped()Return true if this bean type has doc store backing. -
docMapping
Return the DocumentMapping for this bean type.This is the document structure and mapping options for how this bean type is mapped for the document store.
-
getDocMapping
Deprecated.Deprecated migrate to docMapping() -
docStoreQueueId
Return the doc store queueId for this bean type. -
getDocStoreQueueId
Deprecated.Deprecated migrate to docStoreQueueId() -
docStore
BeanDocType<T> docStore()Return the doc store support for this bean type.\ -
addInheritanceWhere
Add the discriminator value to the query if needed. -
root
Return the root bean type for an inheritance hierarchy. -
hasInheritance
boolean hasInheritance()Return true if this bean type has an inheritance hierarchy. -
isInheritanceRoot
boolean isInheritanceRoot()Return true if this object is the root level object in its entity inheritance. -
inheritanceChildren
List<BeanType<?>> inheritanceChildren()Returns all direct children of this beantype -
getInheritanceChildren
Deprecated.Deprecated migrate to inheritanceChildren() -
inheritanceParent
Returns the parent in inheritance hierarchy -
getInheritanceParent
Deprecated.Deprecated migrate to inheritanceParent() -
visitAllInheritanceChildren
Visit all children recursively -
discColumn
Return the discriminator column. -
getDiscColumn
Deprecated.Deprecated migrate to discColumn() -
createBeanUsingDisc
Create a bean given the discriminator value.
-