|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.specrunner.source.core.SourceImpl
public class SourceImpl
The default implementation.
| Field Summary | |
|---|---|
protected nu.xom.Document |
document
The document. |
protected ISourceFactory |
factory
The source factory used to create it. |
protected File |
file
The source as file. |
protected IDocumentLoader |
loader
A document loader. |
protected IResourceManager |
manager
The resource manager. |
protected INamespaceInfo |
namespaceInfo
The namespace info. |
protected INamespaceLoader |
nsloader
A namespace loader. |
protected String |
string
The source as String. |
protected URI |
uri
The source as URI. |
| Fields inherited from interface org.specrunner.source.IEncoded |
|---|
DEFAULT_ENCODING, FEATURE_ENCODING |
| Constructor Summary | |
|---|---|
SourceImpl(String encoding,
String string,
ISourceFactory factory,
IDocumentLoader loader,
INamespaceLoader nsloader)
Creates a source instance. |
|
| Method Summary | |
|---|---|
boolean |
equals(Object obj)
|
nu.xom.Document |
getDocument()
The specification document. |
String |
getEncoding()
Return the encoding. |
ISourceFactory |
getFactory()
The source factory. |
File |
getFile()
The source reference as a java.io.File instance. |
IResourceManager |
getManager()
A resource manager. |
INamespaceInfo |
getNamespaceInfo()
Get meta-information associated to namespace. |
List<nu.xom.Element> |
getScenarios()
The specification scenarios. |
String |
getString()
The source reference as String. |
URI |
getURI()
The source reference as a java.net.URI instance. |
int |
hashCode()
|
String |
relative(ISource other)
Returns the reference as a relative String. |
ISource |
resolve(ISource other)
The relative source resolved. |
protected List<nu.xom.Element> |
toElements(nu.xom.Nodes ns)
Convert to a sequence of elements. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected String string
protected File file
protected URI uri
protected ISourceFactory factory
protected IResourceManager manager
protected IDocumentLoader loader
protected nu.xom.Document document
protected INamespaceLoader nsloader
protected INamespaceInfo namespaceInfo
| Constructor Detail |
|---|
public SourceImpl(String encoding,
String string,
ISourceFactory factory,
IDocumentLoader loader,
INamespaceLoader nsloader)
encoding - The source encoding.string - The source reference.factory - The factory.loader - The document loader.nsloader - The namespace information loader.| Method Detail |
|---|
public String getEncoding()
IEncoded
getEncoding in interface IEncodedpublic String getString()
ISource
getString in interface ISourcepublic File getFile()
ISourcejava.io.File instance.
getFile in interface ISourcepublic URI getURI()
ISourcejava.net.URI instance.
getURI in interface ISourcepublic ISourceFactory getFactory()
ISource
getFactory in interface ISource
public ISource resolve(ISource other)
throws SourceException
ISource
resolve in interface ISourceother - The reference to be opened.
SourceException - On creation errors.public String relative(ISource other)
ISource
relative in interface ISourceother - The reference to be compared.
public IResourceManager getManager()
ISource
getManager in interface ISource
public nu.xom.Document getDocument()
throws SourceException
ISource
getDocument in interface ISourceSourceException - On creation error.
public INamespaceInfo getNamespaceInfo()
throws SourceException
ISource
getNamespaceInfo in interface ISourceSourceException - On namespace info reading.
public List<nu.xom.Element> getScenarios()
throws SourceException
ISource
getScenarios in interface ISourceSourceException - On creation error.protected List<nu.xom.Element> toElements(nu.xom.Nodes ns)
ns - Nodes.
public int hashCode()
hashCode in class Objectpublic boolean equals(Object obj)
equals in class Objectpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||