Class FilterEntity
- java.lang.Object
-
- org.camunda.bpm.engine.impl.persistence.entity.FilterEntity
-
- All Implemented Interfaces:
java.io.Serializable
,Filter
,DbEntity
,DbEntityLifecycleAware
,HasDbReferences
,HasDbRevision
public class FilterEntity extends java.lang.Object implements Filter, java.io.Serializable, DbEntity, HasDbRevision, HasDbReferences, DbEntityLifecycleAware
- Author:
- Sebastian Menski
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
id
protected static EnginePersistenceLogger
LOG
protected java.lang.String
name
protected java.lang.String
owner
protected java.util.Map<java.lang.String,java.lang.Object>
properties
protected AbstractQuery
query
static java.util.Map<java.lang.String,JsonObjectConverter<?>>
queryConverter
protected java.lang.String
resourceType
protected int
revision
-
Constructor Summary
Constructors Modifier Constructor Description protected
FilterEntity()
FilterEntity(java.lang.String resourceType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected FilterEntity
copyFilter()
<T extends Query<?,?>>
Filterextend(T extendingQuery)
Extends the query with the additional query.protected <T> JsonObjectConverter<T>
getConverter()
java.lang.String
getId()
java.lang.String
getName()
java.lang.String
getOwner()
java.lang.Object
getPersistentState()
Returns a representation of the object, as would be stored in the database.java.util.Map<java.lang.String,java.lang.Object>
getProperties()
java.lang.String
getPropertiesInternal()
<T extends Query<?,?>>
TgetQuery()
java.lang.String
getQueryInternal()
java.util.Map<java.lang.String,java.lang.Class>
getReferencedEntitiesIdAndClass()
Scope: IN-MEMORY referencesjava.util.Set<java.lang.String>
getReferencedEntityIds()
Scope: IN-MEMORY referencesjava.lang.String
getResourceType()
int
getRevision()
int
getRevisionNext()
void
postLoad()
void
setId(java.lang.String id)
Filter
setName(java.lang.String name)
Filter
setOwner(java.lang.String owner)
Filter
setProperties(java.util.Map<java.lang.String,java.lang.Object> properties)
void
setPropertiesInternal(java.lang.String properties)
<T extends Query<?,?>>
FiltersetQuery(T query)
void
setQueryInternal(java.lang.String query)
Filter
setResourceType(java.lang.String resourceType)
void
setRevision(int revision)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.camunda.bpm.engine.impl.db.HasDbReferences
getDependentEntities
-
-
-
-
Field Detail
-
LOG
protected static final EnginePersistenceLogger LOG
-
queryConverter
public static final java.util.Map<java.lang.String,JsonObjectConverter<?>> queryConverter
-
id
protected java.lang.String id
-
resourceType
protected java.lang.String resourceType
-
name
protected java.lang.String name
-
owner
protected java.lang.String owner
-
query
protected AbstractQuery query
-
properties
protected java.util.Map<java.lang.String,java.lang.Object> properties
-
revision
protected int revision
-
-
Method Detail
-
getId
public java.lang.String getId()
-
setResourceType
public Filter setResourceType(java.lang.String resourceType)
-
getResourceType
public java.lang.String getResourceType()
- Specified by:
getResourceType
in interfaceFilter
- Returns:
- the resource type fo the filter
-
getName
public java.lang.String getName()
-
setName
public Filter setName(java.lang.String name)
-
getOwner
public java.lang.String getOwner()
-
setOwner
public Filter setOwner(java.lang.String owner)
-
getQuery
public <T extends Query<?,?>> T getQuery()
-
getQueryInternal
public java.lang.String getQueryInternal()
-
setQueryInternal
public void setQueryInternal(java.lang.String query)
-
getProperties
public java.util.Map<java.lang.String,java.lang.Object> getProperties()
- Specified by:
getProperties
in interfaceFilter
- Returns:
- the properties as map
-
getPropertiesInternal
public java.lang.String getPropertiesInternal()
-
setProperties
public Filter setProperties(java.util.Map<java.lang.String,java.lang.Object> properties)
- Specified by:
setProperties
in interfaceFilter
- Parameters:
properties
- the properties to set as map- Returns:
- this filter
-
setPropertiesInternal
public void setPropertiesInternal(java.lang.String properties)
-
getRevision
public int getRevision()
- Specified by:
getRevision
in interfaceHasDbRevision
-
setRevision
public void setRevision(int revision)
- Specified by:
setRevision
in interfaceHasDbRevision
-
getRevisionNext
public int getRevisionNext()
- Specified by:
getRevisionNext
in interfaceHasDbRevision
-
extend
public <T extends Query<?,?>> Filter extend(T extendingQuery)
Description copied from interface:Filter
Extends the query with the additional query. The query of the filter is therefore modified and if the filter is saved the query is updated.
-
getConverter
protected <T> JsonObjectConverter<T> getConverter()
-
getPersistentState
public java.lang.Object getPersistentState()
Description copied from interface:DbEntity
Returns a representation of the object, as would be stored in the database. Used when deciding if updates have occurred to the object or not since it was last loaded.- Specified by:
getPersistentState
in interfaceDbEntity
-
copyFilter
protected FilterEntity copyFilter()
-
postLoad
public void postLoad()
- Specified by:
postLoad
in interfaceDbEntityLifecycleAware
-
getReferencedEntityIds
public java.util.Set<java.lang.String> getReferencedEntityIds()
Description copied from interface:HasDbReferences
Scope: IN-MEMORY references
- Specified by:
getReferencedEntityIds
in interfaceHasDbReferences
- Returns:
- the ids of the entities that this entity references. Should only return ids for entities of the same type
-
getReferencedEntitiesIdAndClass
public java.util.Map<java.lang.String,java.lang.Class> getReferencedEntitiesIdAndClass()
Description copied from interface:HasDbReferences
Scope: IN-MEMORY references
- Specified by:
getReferencedEntitiesIdAndClass
in interfaceHasDbReferences
- Returns:
- a map of the ids and the entities' classes that this entity references. It's used when trying to determine if there was an Optimistic Locking occurrence on an INSERT or UPDATE of an object of this type.
-
-