Package org.jibx.schema
Class MemoryResolver
- java.lang.Object
-
- org.jibx.schema.MemoryResolver
-
- All Implemented Interfaces:
ISchemaResolver
public class MemoryResolver extends java.lang.Object implements ISchemaResolver
Resolver for schema only present in memory.
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.Stringm_idUnique identifier for this schema document.
-
Constructor Summary
Constructors Constructor Description MemoryResolver(java.lang.String id)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.io.InputStreamgetContent()Get the content associated with this schema document.java.lang.StringgetId()Get unique identifier for this schema.java.lang.StringgetName()Get the schema name.ISchemaResolverresolve(java.lang.String loc, java.lang.String tns)Resolve a schema reference, which may be relative to this schema location.
-
-
-
Method Detail
-
getContent
public java.io.InputStream getContent() throws java.io.IOExceptionDescription copied from interface:ISchemaResolverGet the content associated with this schema document.- Specified by:
getContentin interfaceISchemaResolver- Returns:
- input stream
- Throws:
java.io.IOException- on access error
-
getName
public java.lang.String getName()
Description copied from interface:ISchemaResolverGet the schema name.- Specified by:
getNamein interfaceISchemaResolver- Returns:
- name
-
getId
public java.lang.String getId()
Description copied from interface:ISchemaResolverGet unique identifier for this schema.- Specified by:
getIdin interfaceISchemaResolver- Returns:
- identifier
-
resolve
public ISchemaResolver resolve(java.lang.String loc, java.lang.String tns) throws java.io.IOException
Description copied from interface:ISchemaResolverResolve a schema reference, which may be relative to this schema location. If a schema location is provided in the call that location should be used to identify the schema; the target namespace should only be used when the schema location is implicit.- Specified by:
resolvein interfaceISchemaResolver- Parameters:
loc- target URL (nullif none supplied)tns- target namespace URI (nullif none supplied)- Returns:
- resolver for target
- Throws:
java.io.IOException- on resolve error
-
-