Class AbstractReadonlyTableOfContents
java.lang.Object
org.faktorips.runtime.internal.toc.AbstractReadonlyTableOfContents
- All Implemented Interfaces:
IReadonlyTableOfContents
- Direct Known Subclasses:
ReadonlyTableOfContents
public abstract class AbstractReadonlyTableOfContents
extends Object
implements IReadonlyTableOfContents
A table of contents for the runtime repository.
The table of contents contains a list of toc entries that contain the information needed to identify and load the objects stored in the repository.
The table of contents can be extended to read toc entries for new object types by
implementing and registering a ITocEntryFactory.
- Author:
- Jan Ortmann
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionAbstractReadonlyTableOfContents(ClassLoader classLoader) Creates a new TOC that uses the givenClassLoaderto findITocEntryFactoryimplementations viaServiceLoader. -
Method Summary
Modifier and TypeMethodDescriptionabstract EnumContentTocEntrygetEnumContentTocEntry(String className) Returns the toc entry representing enum contents for the specified implementation class.abstract Set<EnumXmlAdapterTocEntry>Returns all toc entries that link to an enumeration xml adapter.abstract Set<ModelTypeTocEntry>Returns all toc's entries representing model types.abstract List<ProductCmptTocEntry>Returns all toc's entries representing product components.abstract List<ProductCmptTocEntry>getProductCmptTocEntries(String kindId) Returns all toc's entries representing product components that belong to the indicated product component kind.abstract ProductCmptTocEntryReturns the toc entry representing a product component for the given id or null if no entry exists for the given id.abstract ProductCmptTocEntrygetProductCmptTocEntry(String kindId, String versionId) Returns the toc entry representing a product component for the given product component kind id and versionId or null if no such entry exists.Return the version of the product data in this table of content.abstract List<TableContentTocEntry>Returns all toc's entries representing tables.abstract TableContentTocEntrygetTableTocEntryByClassname(String implementationClass) Returns a toc entry representing a table for the table's class object.abstract TableContentTocEntrygetTableTocEntryByQualifiedTableName(String qualifiedTableName) Returns a toc entry representing a table for this table's qualified table name.abstract List<TestCaseTocEntry>Returns all toc's entries representing test cases.abstract TestCaseTocEntrygetTestCaseTocEntryByQName(String qName) Returns a toc entry representing a test case for the given qualified name.abstract <T extends IRuntimeObject>
List<CustomTocEntryObject<T>>getTypedTocEntries(Class<T> type) voidinitFromXml(Element tocElement) Initializes the table of contents with data stored in the xml element.protected abstract voidinternalAddEntry(TocEntryObject entry) Adds the entry to the table of contents.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.faktorips.runtime.internal.toc.IReadonlyTableOfContents
getCustomTocEntry, getEnumContentTocEntries
-
Field Details
-
TOC_XML_ELEMENT
- See Also:
-
PRODUCT_DATA_VERSION_XML_ELEMENT
- See Also:
-
-
Constructor Details
-
AbstractReadonlyTableOfContents
Creates a new TOC that uses the givenClassLoaderto findITocEntryFactoryimplementations viaServiceLoader.- Parameters:
classLoader- theClassLoaderused to findITocEntryFactoryimplementations
-
-
Method Details
-
initFromXml
Initializes the table of contents with data stored in the xml element. -
internalAddEntry
Adds the entry to the table of contents. -
getProductCmptTocEntry
Returns the toc entry representing a product component for the given id or null if no entry exists for the given id.- Specified by:
getProductCmptTocEntryin interfaceIReadonlyTableOfContents
-
getProductCmptTocEntry
Returns the toc entry representing a product component for the given product component kind id and versionId or null if no such entry exists.- Specified by:
getProductCmptTocEntryin interfaceIReadonlyTableOfContents
-
getProductCmptTocEntries
Returns all toc's entries representing product components.- Specified by:
getProductCmptTocEntriesin interfaceIReadonlyTableOfContents
-
getProductCmptTocEntries
Returns all toc's entries representing product components that belong to the indicated product component kind.- Specified by:
getProductCmptTocEntriesin interfaceIReadonlyTableOfContents
-
getTableTocEntries
Returns all toc's entries representing tables.- Specified by:
getTableTocEntriesin interfaceIReadonlyTableOfContents
-
getTestCaseTocEntries
Returns all toc's entries representing test cases.- Specified by:
getTestCaseTocEntriesin interfaceIReadonlyTableOfContents
-
getTestCaseTocEntryByQName
Returns a toc entry representing a test case for the given qualified name.- Specified by:
getTestCaseTocEntryByQNamein interfaceIReadonlyTableOfContents
-
getTableTocEntryByClassname
Returns a toc entry representing a table for the table's class object.- Specified by:
getTableTocEntryByClassnamein interfaceIReadonlyTableOfContents
-
getTableTocEntryByQualifiedTableName
public abstract TableContentTocEntry getTableTocEntryByQualifiedTableName(String qualifiedTableName) Returns a toc entry representing a table for this table's qualified table name.- Specified by:
getTableTocEntryByQualifiedTableNamein interfaceIReadonlyTableOfContents
-
getModelTypeTocEntries
Returns all toc's entries representing model types.- Specified by:
getModelTypeTocEntriesin interfaceIReadonlyTableOfContents
-
getEnumContentTocEntry
Returns the toc entry representing enum contents for the specified implementation class.- Specified by:
getEnumContentTocEntryin interfaceIReadonlyTableOfContents
-
getEnumXmlAdapterTocEntries
Returns all toc entries that link to an enumeration xml adapter.- Specified by:
getEnumXmlAdapterTocEntriesin interfaceIReadonlyTableOfContents
-
getProductDataVersion
Description copied from interface:IReadonlyTableOfContentsReturn the version of the product data in this table of content. This may be a version numbe or a timestamp- Specified by:
getProductDataVersionin interfaceIReadonlyTableOfContents- Returns:
- The version of the table of content
-
toString
-
getTypedTocEntries
public abstract <T extends IRuntimeObject> List<CustomTocEntryObject<T>> getTypedTocEntries(Class<T> type)
-