net.sf.farrago.test
Class JmiMemTest.FarragoMemRepos

java.lang.Object
  extended by net.sf.farrago.FarragoMetadataFactoryImpl
      extended by net.sf.farrago.test.JmiMemTest.FarragoMemFactory
          extended by net.sf.farrago.test.JmiMemTest.FarragoMemRepos
All Implemented Interfaces:
FarragoRepos, FarragoMetadataFactory, FarragoAllocation, ClosableAllocation
Enclosing class:
JmiMemTest

private class JmiMemTest.FarragoMemRepos
extends JmiMemTest.FarragoMemFactory
implements FarragoRepos


Constructor Summary
JmiMemTest.FarragoMemRepos(JmiModelGraph modelGraph)
           
 
Method Summary
 void addResourceBundles(List<ResourceBundle> bundles)
          Defines localization for this repository.
<T extends RefObject>
Collection<T>
allOfClass(Class<T> clazz)
          Returns a collection of all instances of a given class.
<T extends RefObject>
Collection<T>
allOfType(Class<T> clazz)
          Returns a collection of all instances of a given type.
 void beginReposSession()
          Begins a session on the metadata repository.
 void beginReposTxn(boolean writable)
          Begins a metadata transaction on the repository.
 void closeAllocation()
          Closes this object.
 void endReposSession()
          Ends a session on the metadata repository.
 void endReposTxn(boolean rollback)
          Ends a metadata transaction on the repository.
 String expandProperties(String value)
          Returns the input string with property values substituted for variables of the form ${VARNAME}, such as that done by FarragoProperties.expandProperties(String)..
 CwmCatalog getCatalog(String catalogName)
          Looks up a catalog by name.
 FemFarragoConfig getCurrentConfig()
           
 String getDefaultCharsetName()
           
 String getDefaultCollationName()
           
 EnkiMDRepository getEnkiMdrRepos()
          Returns an EnkiMDRepository storing this Farrago repository.
 int getIdentifierPrecision()
           
 String getLocalizedClassName(RefClass refClass)
          Looks up the localized name for a class of metadata.
 String getLocalizedObjectName(CwmModelElement modelElement)
          Formats the fully-qualified localized name for an existing object, including its type.
 String getLocalizedObjectName(CwmModelElement modelElement, RefClass refClass)
          Formats the fully-qualified localized name for an existing object.
 String getLocalizedObjectName(String name)
          Formats the localized name for an unqualified typeless object.
 String getLocalizedObjectName(String qualifierName, String objectName, RefClass refClass)
          Formats the fully-qualified localized name for an object that may not exist yet.
 MDRepository getMdrRepos()
           
 Object getMetadataFactory(String prefix)
          Returns the metadata factory for a particular plugin.
 JmiModelGraph getModelGraph()
           
 FarragoModelLoader getModelLoader()
          Returns the FarragoModelLoader for this repos.
 JmiModelView getModelView()
           
 CwmCatalog getSelfAsCatalog()
           
 FarragoSequenceAccessor getSequenceAccessor(String mofId)
          Returns the an accessor for a sequence stored in the repository
 CwmTaggedValue getTag(CwmModelElement element, String tagName)
          Gets an element's tag.
 FemTagAnnotation getTagAnnotation(FemAnnotatedElement element, String tagName)
          Gets an element's annotation tag.
 String getTagAnnotationValue(FemAnnotatedElement element, String tagName)
          Gets a value tagged to an annotated element.
 String getTagValue(CwmModelElement element, String tagName)
          Gets a value tagged to an element.
 FarragoPackage getTransientFarragoPackage()
           
 boolean isFennelEnabled()
           
 FarragoReposTxnContext newTxnContext()
          Returns an instance of FarragoReposTxnContext for use in executing transactions against this repository without automatic repository session management.
 FarragoReposTxnContext newTxnContext(boolean manageReposSession)
          Returns an instance of FarragoReposTxnContext for use in executing transactions against this repository.
 void setTagAnnotationValue(FemAnnotatedElement element, String tagName, String tagValue)
          Tags an annotated element.
 void setTagValue(CwmModelElement element, String tagName, String tagValue)
          Tags an element.
 List<FarragoReposIntegrityErr> verifyIntegrity(RefObject refObj)
          Verifies the integrity of the repository.
 
Methods inherited from class net.sf.farrago.test.JmiMemTest.FarragoMemFactory
getImpl
 
Methods inherited from class net.sf.farrago.FarragoMetadataFactoryImpl
getBehavioralPackage, getCompiledModelTimestamp, getConfigPackage, getCorePackage, getCwmPackage, getDataTypesPackage, getEnumerationsPackage, getFarragoPackage, getFemPackage, getFennelPackage, getInstancePackage, getKeysIndexesPackage, getMedPackage, getPrimitiveTypesPackage, getRelationalPackage, getRootPackage, getSecurityPackage, getSql2003Package, newCwmArgument, newCwmAttribute, newCwmBooleanExpression, newCwmCallAction, newCwmCatalog, newCwmCheckConstraint, newCwmClass, newCwmColumn, newCwmColumnSet, newCwmColumnValue, newCwmConstraint, newCwmDataType, newCwmDataValue, newCwmDependency, newCwmEnumeration, newCwmEnumerationLiteral, newCwmEvent, newCwmExpression, newCwmExtent, newCwmForeignKey, newCwmIndex, newCwmIndexedFeature, newCwmInterface, newCwmKeyRelationship, newCwmMethod, newCwmModel, newCwmMultiplicity, newCwmMultiplicityRange, newCwmNamedColumnSet, newCwmObject, newCwmOperation, newCwmPackage, newCwmParameter, newCwmPrimaryKey, newCwmProcedure, newCwmProcedureExpression, newCwmQueryColumnSet, newCwmQueryExpression, newCwmRow, newCwmRowSet, newCwmSchema, newCwmSlot, newCwmSqldistinctType, newCwmSqlindex, newCwmSqlindexColumn, newCwmSqlparameter, newCwmSqlsimpleType, newCwmSqlstructuredType, newCwmStereotype, newCwmSubsystem, newCwmTable, newCwmTaggedValue, newCwmTrigger, newCwmTypeAlias, newCwmUnion, newCwmUnionMember, newCwmUniqueConstraint, newCwmUniqueKey, newCwmView, newFemAggInvocation, newFemAggStreamDef, newFemBarrierStreamDef, newFemBeginTxnCmd, newFemBernoulliSamplingStreamDef, newFemBufferingTupleStreamDef, newFemBufferReaderStreamDef, newFemBufferWriterStreamDef, newFemCalcTupleStreamDef, newFemCartesianProductStreamDef, newFemCmdAbandonBackup, newFemCmdAlterSystemDeallocate, newFemCmdBeginTxn, newFemCmdBeginTxnWithCsn, newFemCmdCheckpoint, newFemCmdCloseDatabase, newFemCmdCommit, newFemCmdCompleteBackup, newFemCmdCreateExecutionStreamGraph, newFemCmdCreateIndex, newFemCmdCreateStreamHandle, newFemCmdDropIndex, newFemCmdGetLastCommittedTxnId, newFemCmdGetTxnCsn, newFemCmdInitiateBackup, newFemCmdOpenDatabase, newFemCmdPrepareExecutionStreamGraph, newFemCmdRestoreFromBackup, newFemCmdRollback, newFemCmdSavepoint, newFemCmdSetParam, newFemCmdTruncateIndex, newFemCmdVerifyIndex, newFemCmdVersionIndexRoot, newFemCollectTupleStreamDef, newFemColumnHistogram, newFemColumnHistogramBar, newFemColumnListRoutineParameter, newFemColumnName, newFemCorrelation, newFemCorrelationJoinStreamDef, newFemCsnHandle, newFemCsnHandleReturningCmd, newFemDatabaseParam, newFemDataServer, newFemDataWrapper, newFemDbHandle, newFemDynamicParameter, newFemDynamicParamUse, newFemElementWithStorageOptions, newFemExecStreamDataFlow, newFemFarragoConfig, newFemFennelConfig, newFemFlatFileTupleStreamDef, newFemForeignTable, newFemGenericStreamDef, newFemGrant, newFemIndexLoaderDef, newFemIndexScanDef, newFemIndexSearchDef, newFemIndexStatistics, newFemIndexWriterDef, newFemJar, newFemJavaSinkStreamDef, newFemJavaTransformStreamDef, newFemKeyComponent, newFemLabel, newFemLbmBitOpStreamDef, newFemLbmChopperStreamDef, newFemLbmGeneratorStreamDef, newFemLbmIntersectStreamDef, newFemLbmMinusStreamDef, newFemLbmNormalizerStreamDef, newFemLbmSearchStreamDef, newFemLbmSortedAggStreamDef, newFemLbmSplicerStreamDef, newFemLbmUnionStreamDef, newFemLcsClusterAppendStreamDef, newFemLcsClusterReplaceStreamDef, newFemLcsClusterScanDef, newFemLcsRowScanStreamDef, newFemLhxAggStreamDef, newFemLhxJoinStreamDef, newFemLocalCatalog, newFemLocalIndex, newFemLocalIndexColumn, newFemLocalSchema, newFemLocalTable, newFemLocalView, newFemMergeStreamDef, newFemMockTupleStreamDef, newFemMultiUseBufferingStreamDef, newFemNestedLoopJoinStreamDef, newFemPrimaryKeyConstraint, newFemRecoveryReference, newFemReshapeParameter, newFemReshapeStreamDef, newFemRole, newFemRoutine, newFemRoutineParameter, newFemRowCountStatistics, newFemSampleDataset, newFemSequenceGenerator, newFemSortedAggStreamDef, newFemSortingStreamDef, newFemSplicerIndexAccessorDef, newFemSplitterStreamDef, newFemSqlarrayType, newFemSqldistinguishedType, newFemSqlmultisetType, newFemSqlobjectType, newFemSqlpathElement, newFemSqlrowType, newFemSqltypeAttribute, newFemStorageOption, newFemStoredColumn, newFemStreamGraphHandle, newFemStreamHandle, newFemSvptHandle, newFemSystemBackup, newFemTableDeleterDef, newFemTableInserterDef, newFemTableUpdaterDef, newFemTagAnnotation, newFemTimestamp, newFemTupleAccessor, newFemTupleAttrAccessor, newFemTupleAttrDescriptor, newFemTupleAttrProjection, newFemTupleDescriptor, newFemTupleProjection, newFemTxnHandle, newFemUncollectTupleStreamDef, newFemUniqueKeyConstraint, newFemUser, newFemUserDefinedOrdering, newFemUserDefinedType, newFemValuesStreamDef, newFemViewColumn, newFemWindowDef, newFemWindowPartitionDef, newFemWindowStreamDef, setRootPackage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface net.sf.farrago.FarragoMetadataFactory
getBehavioralPackage, getCompiledModelTimestamp, getConfigPackage, getCorePackage, getCwmPackage, getDataTypesPackage, getEnumerationsPackage, getFarragoPackage, getFemPackage, getFennelPackage, getInstancePackage, getKeysIndexesPackage, getMedPackage, getPrimitiveTypesPackage, getRelationalPackage, getRootPackage, getSecurityPackage, getSql2003Package, newCwmArgument, newCwmAttribute, newCwmBooleanExpression, newCwmCallAction, newCwmCatalog, newCwmCheckConstraint, newCwmClass, newCwmColumn, newCwmColumnSet, newCwmColumnValue, newCwmConstraint, newCwmDataType, newCwmDataValue, newCwmDependency, newCwmEnumeration, newCwmEnumerationLiteral, newCwmEvent, newCwmExpression, newCwmExtent, newCwmForeignKey, newCwmIndex, newCwmIndexedFeature, newCwmInterface, newCwmKeyRelationship, newCwmMethod, newCwmModel, newCwmMultiplicity, newCwmMultiplicityRange, newCwmNamedColumnSet, newCwmObject, newCwmOperation, newCwmPackage, newCwmParameter, newCwmPrimaryKey, newCwmProcedure, newCwmProcedureExpression, newCwmQueryColumnSet, newCwmQueryExpression, newCwmRow, newCwmRowSet, newCwmSchema, newCwmSlot, newCwmSqldistinctType, newCwmSqlindex, newCwmSqlindexColumn, newCwmSqlparameter, newCwmSqlsimpleType, newCwmSqlstructuredType, newCwmStereotype, newCwmSubsystem, newCwmTable, newCwmTaggedValue, newCwmTrigger, newCwmTypeAlias, newCwmUnion, newCwmUnionMember, newCwmUniqueConstraint, newCwmUniqueKey, newCwmView, newFemAggInvocation, newFemAggStreamDef, newFemBarrierStreamDef, newFemBeginTxnCmd, newFemBernoulliSamplingStreamDef, newFemBufferingTupleStreamDef, newFemBufferReaderStreamDef, newFemBufferWriterStreamDef, newFemCalcTupleStreamDef, newFemCartesianProductStreamDef, newFemCmdAbandonBackup, newFemCmdAlterSystemDeallocate, newFemCmdBeginTxn, newFemCmdBeginTxnWithCsn, newFemCmdCheckpoint, newFemCmdCloseDatabase, newFemCmdCommit, newFemCmdCompleteBackup, newFemCmdCreateExecutionStreamGraph, newFemCmdCreateIndex, newFemCmdCreateStreamHandle, newFemCmdDropIndex, newFemCmdGetLastCommittedTxnId, newFemCmdGetTxnCsn, newFemCmdInitiateBackup, newFemCmdOpenDatabase, newFemCmdPrepareExecutionStreamGraph, newFemCmdRestoreFromBackup, newFemCmdRollback, newFemCmdSavepoint, newFemCmdSetParam, newFemCmdTruncateIndex, newFemCmdVerifyIndex, newFemCmdVersionIndexRoot, newFemCollectTupleStreamDef, newFemColumnHistogram, newFemColumnHistogramBar, newFemColumnListRoutineParameter, newFemColumnName, newFemCorrelation, newFemCorrelationJoinStreamDef, newFemCsnHandle, newFemCsnHandleReturningCmd, newFemDatabaseParam, newFemDataServer, newFemDataWrapper, newFemDbHandle, newFemDynamicParameter, newFemDynamicParamUse, newFemElementWithStorageOptions, newFemExecStreamDataFlow, newFemFarragoConfig, newFemFennelConfig, newFemFlatFileTupleStreamDef, newFemForeignTable, newFemGenericStreamDef, newFemGrant, newFemIndexLoaderDef, newFemIndexScanDef, newFemIndexSearchDef, newFemIndexStatistics, newFemIndexWriterDef, newFemJar, newFemJavaSinkStreamDef, newFemJavaTransformStreamDef, newFemKeyComponent, newFemLabel, newFemLbmBitOpStreamDef, newFemLbmChopperStreamDef, newFemLbmGeneratorStreamDef, newFemLbmIntersectStreamDef, newFemLbmMinusStreamDef, newFemLbmNormalizerStreamDef, newFemLbmSearchStreamDef, newFemLbmSortedAggStreamDef, newFemLbmSplicerStreamDef, newFemLbmUnionStreamDef, newFemLcsClusterAppendStreamDef, newFemLcsClusterReplaceStreamDef, newFemLcsClusterScanDef, newFemLcsRowScanStreamDef, newFemLhxAggStreamDef, newFemLhxJoinStreamDef, newFemLocalCatalog, newFemLocalIndex, newFemLocalIndexColumn, newFemLocalSchema, newFemLocalTable, newFemLocalView, newFemMergeStreamDef, newFemMockTupleStreamDef, newFemMultiUseBufferingStreamDef, newFemNestedLoopJoinStreamDef, newFemPrimaryKeyConstraint, newFemRecoveryReference, newFemReshapeParameter, newFemReshapeStreamDef, newFemRole, newFemRoutine, newFemRoutineParameter, newFemRowCountStatistics, newFemSampleDataset, newFemSequenceGenerator, newFemSortedAggStreamDef, newFemSortingStreamDef, newFemSplicerIndexAccessorDef, newFemSplitterStreamDef, newFemSqlarrayType, newFemSqldistinguishedType, newFemSqlmultisetType, newFemSqlobjectType, newFemSqlpathElement, newFemSqlrowType, newFemSqltypeAttribute, newFemStorageOption, newFemStoredColumn, newFemStreamGraphHandle, newFemStreamHandle, newFemSvptHandle, newFemSystemBackup, newFemTableDeleterDef, newFemTableInserterDef, newFemTableUpdaterDef, newFemTagAnnotation, newFemTimestamp, newFemTupleAccessor, newFemTupleAttrAccessor, newFemTupleAttrDescriptor, newFemTupleAttrProjection, newFemTupleDescriptor, newFemTupleProjection, newFemTxnHandle, newFemUncollectTupleStreamDef, newFemUniqueKeyConstraint, newFemUser, newFemUserDefinedOrdering, newFemUserDefinedType, newFemValuesStreamDef, newFemViewColumn, newFemWindowDef, newFemWindowPartitionDef, newFemWindowStreamDef, setRootPackage
 

Constructor Detail

JmiMemTest.FarragoMemRepos

public JmiMemTest.FarragoMemRepos(JmiModelGraph modelGraph)
Method Detail

getMdrRepos

public MDRepository getMdrRepos()
Specified by:
getMdrRepos in interface FarragoRepos
Returns:
MDRepository storing this Farrago repository

getEnkiMdrRepos

public EnkiMDRepository getEnkiMdrRepos()
Description copied from interface: FarragoRepos
Returns an EnkiMDRepository storing this Farrago repository. This method returns the same instance of FarragoRepos.getMdrRepos().

Specified by:
getEnkiMdrRepos in interface FarragoRepos
Returns:
EnkiMDRepository storing this Farrago repository

getModelGraph

public JmiModelGraph getModelGraph()
Specified by:
getModelGraph in interface FarragoRepos
Returns:
model graph for repository metamodel

getModelView

public JmiModelView getModelView()
Specified by:
getModelView in interface FarragoRepos
Returns:
model view for repository metamodel

getTransientFarragoPackage

public FarragoPackage getTransientFarragoPackage()
Specified by:
getTransientFarragoPackage in interface FarragoRepos
Returns:
root package for transient metadata

getSelfAsCatalog

public CwmCatalog getSelfAsCatalog()
Specified by:
getSelfAsCatalog in interface FarragoRepos
Returns:
CwmCatalog representing this FarragoRepos

getIdentifierPrecision

public int getIdentifierPrecision()
Specified by:
getIdentifierPrecision in interface FarragoRepos
Returns:
maximum identifier length in characters

getCurrentConfig

public FemFarragoConfig getCurrentConfig()
Specified by:
getCurrentConfig in interface FarragoRepos
Returns:
element describing the configuration parameters

getDefaultCharsetName

public String getDefaultCharsetName()
Specified by:
getDefaultCharsetName in interface FarragoRepos
Returns:
the name of the default Charset for this repository

getDefaultCollationName

public String getDefaultCollationName()
Specified by:
getDefaultCollationName in interface FarragoRepos
Returns:
the name of the default collation name for this repository. The value is of the form charset$locale$strength, as per SqlParserUtil.parseCollation(String). The default is "ISO-8859-1$en_US".

isFennelEnabled

public boolean isFennelEnabled()
Specified by:
isFennelEnabled in interface FarragoRepos
Returns:
true iff Fennel support should be used

getLocalizedObjectName

public String getLocalizedObjectName(CwmModelElement modelElement)
Description copied from interface: FarragoRepos
Formats the fully-qualified localized name for an existing object, including its type.

Calling getLocalizedObjectName(e) is identical to calling getLocalizedObjectName(e, e.refClass()).

Specified by:
getLocalizedObjectName in interface FarragoRepos
Parameters:
modelElement - catalog object
Returns:
localized name

getLocalizedObjectName

public String getLocalizedObjectName(String name)
Description copied from interface: FarragoRepos
Formats the localized name for an unqualified typeless object.

Specified by:
getLocalizedObjectName in interface FarragoRepos
Parameters:
name - object name
Returns:
localized name

getLocalizedObjectName

public String getLocalizedObjectName(CwmModelElement modelElement,
                                     RefClass refClass)
Description copied from interface: FarragoRepos
Formats the fully-qualified localized name for an existing object.

Specified by:
getLocalizedObjectName in interface FarragoRepos
Parameters:
modelElement - catalog object
refClass - if non-null, use this as the type of the object, e.g. "table SCHEMA.TABLE"; if null, don't include type (e.g. just "SCHEMA.TABLE")
Returns:
localized name

getLocalizedObjectName

public String getLocalizedObjectName(String qualifierName,
                                     String objectName,
                                     RefClass refClass)
Description copied from interface: FarragoRepos
Formats the fully-qualified localized name for an object that may not exist yet.

Specified by:
getLocalizedObjectName in interface FarragoRepos
Parameters:
qualifierName - name of containing object, or null for unqualified name
objectName - name of object
refClass - if non-null, the object type to use in the name; if null, no type is prepended
Returns:
localized name

getLocalizedClassName

public String getLocalizedClassName(RefClass refClass)
Description copied from interface: FarragoRepos
Looks up the localized name for a class of metadata.

Specified by:
getLocalizedClassName in interface FarragoRepos
Parameters:
refClass - class of metadata, e.g. CwmTableClass
Returns:
localized name, e.g. "table"

getCatalog

public CwmCatalog getCatalog(String catalogName)
Description copied from interface: FarragoRepos
Looks up a catalog by name.

Specified by:
getCatalog in interface FarragoRepos
Parameters:
catalogName - name of catalog to find
Returns:
catalog definition, or null if not found

getTag

public CwmTaggedValue getTag(CwmModelElement element,
                             String tagName)
Description copied from interface: FarragoRepos
Gets an element's tag.

Specified by:
getTag in interface FarragoRepos
Parameters:
element - the tagged element
tagName - name of tag to find
Returns:
tag, or null if not found

setTagValue

public void setTagValue(CwmModelElement element,
                        String tagName,
                        String tagValue)
Description copied from interface: FarragoRepos
Tags an element.

Specified by:
setTagValue in interface FarragoRepos
Parameters:
element - the element to tag
tagName - name of tag to create; if a tag with this name already exists, it will be updated
tagValue - value to set

getTagValue

public String getTagValue(CwmModelElement element,
                          String tagName)
Description copied from interface: FarragoRepos
Gets a value tagged to an element.

Specified by:
getTagValue in interface FarragoRepos
Parameters:
element - the tagged element
tagName - name of tag to find
Returns:
tag value, or null if not found

getTagAnnotation

public FemTagAnnotation getTagAnnotation(FemAnnotatedElement element,
                                         String tagName)
Description copied from interface: FarragoRepos
Gets an element's annotation tag.

Specified by:
getTagAnnotation in interface FarragoRepos
Parameters:
element - the tagged element
tagName - name of tag to find
Returns:
tag, or null if not found

setTagAnnotationValue

public void setTagAnnotationValue(FemAnnotatedElement element,
                                  String tagName,
                                  String tagValue)
Description copied from interface: FarragoRepos
Tags an annotated element.

Specified by:
setTagAnnotationValue in interface FarragoRepos
Parameters:
element - the element to tag
tagName - name of tag to create; if a tag with this name already exists, it will be updated
tagValue - value to set

getTagAnnotationValue

public String getTagAnnotationValue(FemAnnotatedElement element,
                                    String tagName)
Description copied from interface: FarragoRepos
Gets a value tagged to an annotated element.

Specified by:
getTagAnnotationValue in interface FarragoRepos
Parameters:
element - the tagged element
tagName - name of tag to find
Returns:
tag value, or null if not found

addResourceBundles

public void addResourceBundles(List<ResourceBundle> bundles)
Description copied from interface: FarragoRepos
Defines localization for this repository.

Specified by:
addResourceBundles in interface FarragoRepos
Parameters:
bundles - list of ResourceBundle instances to add for

beginReposSession

public void beginReposSession()
Description copied from interface: FarragoRepos
Begins a session on the metadata repository.

Specified by:
beginReposSession in interface FarragoRepos
See Also:
FarragoRepos.newTxnContext(boolean)

beginReposTxn

public void beginReposTxn(boolean writable)
Description copied from interface: FarragoRepos
Begins a metadata transaction on the repository. In most cases, this should be done by creating and manipulating an instance of FarragoReposTxnContext instead.

Specified by:
beginReposTxn in interface FarragoRepos
Parameters:
writable - true for read/write; false for read-only

endReposTxn

public void endReposTxn(boolean rollback)
Description copied from interface: FarragoRepos
Ends a metadata transaction on the repository.

Specified by:
endReposTxn in interface FarragoRepos
Parameters:
rollback - true to rollback; false to commit

endReposSession

public void endReposSession()
Description copied from interface: FarragoRepos
Ends a session on the metadata repository.

Specified by:
endReposSession in interface FarragoRepos
See Also:
FarragoRepos.newTxnContext(boolean)

getMetadataFactory

public Object getMetadataFactory(String prefix)
Description copied from interface: FarragoRepos
Returns the metadata factory for a particular plugin. In particular, getMetadataFactory("Fem") returns this.

Specified by:
getMetadataFactory in interface FarragoRepos
Parameters:
prefix - The name of the prefix which identifies the metadata factory

getSequenceAccessor

public FarragoSequenceAccessor getSequenceAccessor(String mofId)
Description copied from interface: FarragoRepos
Returns the an accessor for a sequence stored in the repository

Specified by:
getSequenceAccessor in interface FarragoRepos
Parameters:
mofId - the identifier for the sequence

expandProperties

public String expandProperties(String value)
Description copied from interface: FarragoRepos
Returns the input string with property values substituted for variables of the form ${VARNAME}, such as that done by FarragoProperties.expandProperties(String)..

Specified by:
expandProperties in interface FarragoRepos
Parameters:
value - String we want to expand
Returns:
expanded string, if value(s) were known

allOfClass

public <T extends RefObject> Collection<T> allOfClass(Class<T> clazz)
Description copied from interface: FarragoRepos
Returns a collection of all instances of a given class.

This method has the same effect as RefClass.refAllOfClass(), but is preferable because it returns a typed collection.

Specified by:
allOfClass in interface FarragoRepos

allOfType

public <T extends RefObject> Collection<T> allOfType(Class<T> clazz)
Description copied from interface: FarragoRepos
Returns a collection of all instances of a given type.

This method has the same effect as RefClass.refAllOfType(), but is preferable because it returns a typed collection.

Specified by:
allOfType in interface FarragoRepos

verifyIntegrity

public List<FarragoReposIntegrityErr> verifyIntegrity(RefObject refObj)
Description copied from interface: FarragoRepos
Verifies the integrity of the repository.

Specified by:
verifyIntegrity in interface FarragoRepos
Parameters:
refObj - a single object to check (independent of related objects) or null to check the entire repository
Returns:
list of violations (empty list indicates integrity check passed)

getModelLoader

public FarragoModelLoader getModelLoader()
Description copied from interface: FarragoRepos
Returns the FarragoModelLoader for this repos. May return null if not supported by implementation.

Specified by:
getModelLoader in interface FarragoRepos

closeAllocation

public void closeAllocation()
Description copied from interface: ClosableAllocation
Closes this object.

Specified by:
closeAllocation in interface ClosableAllocation

newTxnContext

public FarragoReposTxnContext newTxnContext()
Description copied from interface: FarragoRepos
Returns an instance of FarragoReposTxnContext for use in executing transactions against this repository without automatic repository session management. Equivalent to newTxnContext(false).

Specified by:
newTxnContext in interface FarragoRepos
Returns:
an instance of FarragoReposTxnContext for use in executing transactions against this repository

newTxnContext

public FarragoReposTxnContext newTxnContext(boolean manageReposSession)
Description copied from interface: FarragoRepos
Returns an instance of FarragoReposTxnContext for use in executing transactions against this repository. If the manageReposSession parameter is true, the returned FarragoReposTxnContext is responsible for managing repository sessions. Otherwise the caller is responsible for managing the repository session.

Specified by:
newTxnContext in interface FarragoRepos
Parameters:
manageReposSession - if true, the FarragoReposTxnContext manages the repository session
Returns:
an instance of FarragoReposTxnContext for use in executing transactions against this repository