|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.alfresco.repo.dictionary.DictionaryDAOImpl
public class DictionaryDAOImpl
Default implementation of the Dictionary.
Nested Class Summary | |
---|---|
class |
DictionaryDAOImpl.DictionaryRegistry
|
Constructor Summary | |
---|---|
DictionaryDAOImpl(NamespaceDAO namespaceDAO)
Construct |
Method Summary | |
---|---|
void |
destroy()
Destroy the Dictionary & Namespaces |
java.util.List |
diffModel(M2Model model)
Return diffs between input model and model in the Dictionary. |
TypeDefinition |
getAnonymousType(QName type,
java.util.Collection aspects)
Construct an anonymous type that combines a primary type definition and and one or more aspects |
AspectDefinition |
getAspect(QName aspectName)
Gets the specified aspect |
java.util.Collection |
getAspects(QName modelName)
|
AssociationDefinition |
getAssociation(QName assocName)
Gets the specified association |
java.util.Collection |
getAssociations(QName modelName)
|
ClassDefinition |
getClass(QName className)
Gets the specified class |
CompiledModel |
getCompiledModel(QName modelName)
|
ConstraintDefinition |
getConstraint(QName constraintQName)
Gets the specified property constraint |
java.util.Collection |
getConstraints(QName modelName)
|
java.util.Collection |
getConstraints(QName modelName,
boolean referenceableDefsOnly)
|
DataTypeDefinition |
getDataType(java.lang.Class javaClass)
Gets the data type for the specified Java Class |
DataTypeDefinition |
getDataType(QName typeName)
Gets the specified data type |
java.util.Collection |
getDataTypes(QName modelName)
|
java.lang.String |
getDefaultAnalyserResourceBundleName()
|
ModelDefinition |
getModel(QName name)
|
java.util.Collection |
getModels()
|
java.util.Collection |
getNamespaces(QName modelName)
|
java.util.Collection |
getProperties(QName modelName)
|
java.util.Collection |
getProperties(QName modelName,
QName dataType)
Get all properties for the model and that are of the given data type. |
java.util.Collection |
getPropertiesOfDataType(QName dataType)
Get all properties for all models of the given data type. |
PropertyDefinition |
getProperty(QName propertyName)
Gets the specified property |
java.lang.ClassLoader |
getResourceClassLoader()
|
java.util.Collection |
getSubAspects(QName superAspect,
boolean follow)
|
java.util.Collection |
getSubTypes(QName superType,
boolean follow)
|
TypeDefinition |
getType(QName typeName)
Gets the specified type |
java.util.Collection |
getTypes(QName modelName)
|
void |
init()
Initialise the Dictionary & Namespaces |
boolean |
isModelInherited(QName modelName)
|
QName |
putModel(M2Model model)
Adds a model to the dictionary. |
QName |
putModelIgnoringConstraints(M2Model model)
Adds a model to the dictionary. |
QName |
putModelImpl(M2Model model,
boolean enableConstraintClassLoading)
|
void |
register(DictionaryListener dictionaryListener)
Register with the Dictionary |
void |
removeModel(QName modelName)
Removes a model from the dictionary. |
void |
reset()
Reset the Dictionary & Namespaces |
void |
setDefaultAnalyserResourceBundleName(java.lang.String defaultAnalyserResourceBundleName)
|
void |
setDictionaryRegistryCache(SimpleCache dictionaryRegistryCache)
|
void |
setResourceClassLoader(java.lang.ClassLoader resourceClassLoader)
|
void |
setTenantService(TenantService tenantService)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DictionaryDAOImpl(NamespaceDAO namespaceDAO)
namespaceDAO
- namespace data accessMethod Detail |
---|
public void setTenantService(TenantService tenantService)
public void setDictionaryRegistryCache(SimpleCache dictionaryRegistryCache)
public java.lang.String getDefaultAnalyserResourceBundleName()
getDefaultAnalyserResourceBundleName
in interface DictionaryDAO
public void setDefaultAnalyserResourceBundleName(java.lang.String defaultAnalyserResourceBundleName)
public void register(DictionaryListener dictionaryListener)
register
in interface DictionaryDAO
public void init()
init
in interface DictionaryDAO
public void destroy()
destroy
in interface DictionaryDAO
public void reset()
reset
in interface DictionaryDAO
public QName putModel(M2Model model)
DictionaryDAO
putModel
in interface DictionaryDAO
model
- the model to add
public QName putModelIgnoringConstraints(M2Model model)
DictionaryDAO
putModelIgnoringConstraints
in interface DictionaryDAO
model
- the model to add
public QName putModelImpl(M2Model model, boolean enableConstraintClassLoading)
public void removeModel(QName modelName)
DictionaryDAO
removeModel
in interface DictionaryDAO
modelName
- the qname of the model to removeDictionaryDAO.removeModel(org.alfresco.service.namespace.QName)
public CompiledModel getCompiledModel(QName modelName)
modelName
- the model name
public DataTypeDefinition getDataType(QName typeName)
typeName
- name of the data type
public DataTypeDefinition getDataType(java.lang.Class javaClass)
javaClass
- the java class
public java.util.Collection getDataTypes(QName modelName)
getDataTypes
in interface DictionaryDAO
modelName
- the model to retrieve property types for
public TypeDefinition getType(QName typeName)
typeName
- name of the type
public java.util.Collection getSubTypes(QName superType, boolean follow)
getSubTypes
in interface DictionaryDAO
follow
- true => follow up the super-class hierarchy, false => immediate sub types only
public AspectDefinition getAspect(QName aspectName)
aspectName
- name of the aspect
public java.util.Collection getSubAspects(QName superAspect, boolean follow)
getSubAspects
in interface DictionaryDAO
follow
- true => follow up the super-class hierarchy, false => immediate sub aspects only
public ClassDefinition getClass(QName className)
className
- name of the class
public PropertyDefinition getProperty(QName propertyName)
propertyName
- name of the property
public ConstraintDefinition getConstraint(QName constraintQName)
constraintQName
- the qualified name of the property constraint
public AssociationDefinition getAssociation(QName assocName)
assocName
- name of the association
public java.util.Collection getAssociations(QName modelName)
getAssociations
in interface DictionaryDAO
modelName
- the model to retrieve associations for
public java.util.Collection getModels()
getModels
in interface DictionaryDAO
public boolean isModelInherited(QName modelName)
isModelInherited
in interface DictionaryDAO
public ModelDefinition getModel(QName name)
getModel
in interface DictionaryDAO
name
- the model to retrieve
public java.util.Collection getTypes(QName modelName)
getTypes
in interface DictionaryDAO
modelName
- the model to retrieve types for
public java.util.Collection getAspects(QName modelName)
getAspects
in interface DictionaryDAO
modelName
- the model to retrieve aspects for
public TypeDefinition getAnonymousType(QName type, java.util.Collection aspects)
DictionaryDAO
getAnonymousType
in interface DictionaryDAO
type
- the primary typeaspects
- the aspects to combine
public java.util.Collection getProperties(QName modelName)
getProperties
in interface DictionaryDAO
modelName
- the model for which to get properties for
public java.util.Collection getProperties(QName modelName, QName dataType)
DictionaryDAO
getProperties
in interface DictionaryDAO
modelName
- the name of the modeldataType
- null to get all properties
public java.util.Collection getPropertiesOfDataType(QName dataType)
DictionaryDAO
getPropertiesOfDataType
in interface DictionaryDAO
public java.util.Collection getNamespaces(QName modelName)
getNamespaces
in interface DictionaryDAO
public java.util.Collection getConstraints(QName modelName)
getConstraints
in interface DictionaryDAO
modelName
- the model to retrieve constraint defs (including property constaint refs)
public java.util.Collection getConstraints(QName modelName, boolean referenceableDefsOnly)
getConstraints
in interface DictionaryDAO
modelName
- the model to retrieve constraint defs (optionally only referenceable constraints)
public java.util.List diffModel(M2Model model)
diffModel
in interface DictionaryDAO
model
-
public java.lang.ClassLoader getResourceClassLoader()
getResourceClassLoader
in interface DictionaryDAO
public void setResourceClassLoader(java.lang.ClassLoader resourceClassLoader)
setResourceClassLoader
in interface DictionaryDAO
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |