ooc
Class SourceInputStream

java.lang.Object
  extended byooc.SourceAbstract
      extended byooc.SourceInputStream
All Implemented Interfaces:
Source

public class SourceInputStream
extends SourceAbstract

Given a name and an unread input stream this class will act as a source from which tags can be parsed. In general this class is used by classes implementing SourceContext.


Constructor Summary
SourceInputStream(java.lang.String name, SourceContext sourceContext, java.io.InputStream inputStream)
          Constructs a source given a name, a context, and an input stream.
 
Method Summary
 java.io.InputStream getInputStream()
          Returns the input stream of this source.
 java.lang.String getName()
          Returns the name of this source.
 SourceContext getSourceContext()
          Returns the context for this source.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SourceInputStream

public SourceInputStream(java.lang.String name,
                         SourceContext sourceContext,
                         java.io.InputStream inputStream)
Constructs a source given a name, a context, and an input stream.

Parameters:
name - is the name of the source.
sourceContext - is the context from which the input stream was recovered.
inputStream - is the input stream which will provide tags.
Method Detail

getName

public java.lang.String getName()
Description copied from interface: Source
Returns the name of this source.

Returns:
the name of this source.

getSourceContext

public SourceContext getSourceContext()
Description copied from interface: Source
Returns the context for this source. Every source instance comes from a context. Examples of this are the classpath or current file path.

Returns:
the context of this source.

getInputStream

public java.io.InputStream getInputStream()
Description copied from interface: Source
Returns the input stream of this source.

Returns:
the input stream of this source.
See Also:
TagParser, Container