Class SchemaProcessingContext
java.lang.Object
org.incenp.linkml.schema.SchemaProcessingContext
The context in which a schema definition is being converted.
A context is specific to an instance of SchemaDocument and allows to
keep track of the various schemas that are being converted as the imports
closure is processed.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the ID of the schema that is currently being converted.booleanisInImportChain(URI schema) Checks whether the given URI (assumed to be a schema ID) is present in the current import chain.voidRemoves the last schema ID.voidpushImport(URI schema) Pushes a new schema ID into the import queue.
-
Constructor Details
-
SchemaProcessingContext
public SchemaProcessingContext()
-
-
Method Details
-
pushImport
Pushes a new schema ID into the import queue.- Parameters:
schema- The ID to add to the queue.
-
popImport
public void popImport()Removes the last schema ID. -
getCurrentSchema
Gets the ID of the schema that is currently being converted.- Returns:
- The current schema ID.
-
isInImportChain
Checks whether the given URI (assumed to be a schema ID) is present in the current import chain.- Parameters:
schema- The schema ID to check.- Returns:
trueif the given ID represents a schema that is part of the current import chain, otherwisefalse.
-