Show / Hide Table of Contents

Class ParsingTextReader

An extended System.IO.TextReader for use in parsing.

Inheritance
System.Object
System.MarshalByRefObject
System.IO.TextReader
ParsingTextReader
BufferedTextReader
Implements
System.IDisposable
Inherited Members
System.IO.TextReader.Null
System.IO.TextReader.Close()
System.IO.TextReader.Dispose()
System.IO.TextReader.Dispose(bool)
System.IO.TextReader.Peek()
System.IO.TextReader.Read()
System.IO.TextReader.Read(char[], int, int)
System.IO.TextReader.ReadAsync(char[], int, int)
System.IO.TextReader.ReadBlock(char[], int, int)
System.IO.TextReader.ReadBlockAsync(char[], int, int)
System.IO.TextReader.ReadLine()
System.IO.TextReader.ReadLineAsync()
System.IO.TextReader.ReadToEnd()
System.IO.TextReader.ReadToEndAsync()
System.IO.TextReader.Synchronized(System.IO.TextReader)
System.MarshalByRefObject.GetLifetimeService()
System.MarshalByRefObject.InitializeLifetimeService()
System.MarshalByRefObject.MemberwiseClone(bool)
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: VDS.RDF.Parsing
Assembly: dotNetRdf.dll
Syntax
public abstract class ParsingTextReader : TextReader, IDisposable

Properties

| Improve this Doc View Source

EndOfStream

Gets whether the end of the stream has been reached.

Declaration
public abstract bool EndOfStream { get; }
Property Value
Type Description
System.Boolean

Methods

| Improve this Doc View Source

Create(Stream, int)

Creates a new Blocking Text Reader.

Declaration
public static ParsingTextReader Create(Stream input, int bufferSize)
Parameters
Type Name Description
System.IO.Stream input

Input Stream.

int bufferSize

Buffer Size.

Returns
Type Description
ParsingTextReader
| Improve this Doc View Source

Create(Stream)

Creates a new Blocking Text Reader.

Declaration
public static ParsingTextReader Create(Stream input)
Parameters
Type Name Description
System.IO.Stream input

Input Stream.

Returns
Type Description
ParsingTextReader
Remarks

Blocking IO refers to how the parsing sub-system reads in inputs, it will use Blocking/Non-Blocking IO depending on the input source. In most cases the detection of which to use should never cause an issue but theoretically in some rare cases using non-blocking IO may lead to incorrect parsing errors being thrown (premature end of input detected), if you suspect this is the case try enabling this setting. If you still experience this problem with this setting enabled then there is some other issue with your input.

| Improve this Doc View Source

Create(TextReader, int)

Creates a new Parsing Text Reader.

Declaration
public static ParsingTextReader Create(TextReader input, int bufferSize)
Parameters
Type Name Description
System.IO.TextReader input

Text Reader to wrap.

int bufferSize

Buffer Size.

Returns
Type Description
ParsingTextReader
Remarks

If the given System.IO.TextReader is already a ParsingTextReader instance, a NonBlockingTextReader or a BlockingTextReader this is a no-op. If the given System.IO.TextReader uses a System.IO.FileStream or System.IO.MemoryStream as its underlying stream source, then this method will create and return a NonBlockingTextReader, otherwise the method will create a BlockingTextReader.

| Improve this Doc View Source

Create(TextReader)

Creates a new Blocking Text Reader.

Declaration
public static ParsingTextReader Create(TextReader input)
Parameters
Type Name Description
System.IO.TextReader input

Text Reader to wrap.

Returns
Type Description
ParsingTextReader
| Improve this Doc View Source

CreateBlocking(TextReader, int)

Creates a new Blocking Text Reader.

Declaration
public static BlockingTextReader CreateBlocking(TextReader input, int bufferSize)
Parameters
Type Name Description
System.IO.TextReader input

Input reader.

int bufferSize

Buffer Size.

Returns
Type Description
BlockingTextReader
| Improve this Doc View Source

CreateBlocking(TextReader)

Creates a new Blocking Text Reader.

Declaration
public static BlockingTextReader CreateBlocking(TextReader input)
Parameters
Type Name Description
System.IO.TextReader input

Input reader.

Returns
Type Description
BlockingTextReader
| Improve this Doc View Source

CreateNonBlocking(TextReader, int)

Creates a new non-blocking Text Reader.

Declaration
public static NonBlockingTextReader CreateNonBlocking(TextReader input, int bufferSize)
Parameters
Type Name Description
System.IO.TextReader input

Input reader.

int bufferSize

Buffer Size.

Returns
Type Description
NonBlockingTextReader
| Improve this Doc View Source

CreateNonBlocking(TextReader)

Creates a new non-blocking Text Reader.

Declaration
public static NonBlockingTextReader CreateNonBlocking(TextReader input)
Parameters
Type Name Description
System.IO.TextReader input

Input reader.

Returns
Type Description
NonBlockingTextReader

Implements

System.IDisposable

Extension Methods

Extensions.ToSafeString(object)
Extensions.AsEnumerable<T>(T)
  • Improve this Doc
  • View Source
In This Article
  • Properties
    • EndOfStream
  • Methods
    • Create(Stream, int)
    • Create(Stream)
    • Create(TextReader, int)
    • Create(TextReader)
    • CreateBlocking(TextReader, int)
    • CreateBlocking(TextReader)
    • CreateNonBlocking(TextReader, int)
    • CreateNonBlocking(TextReader)
  • Implements
  • Extension Methods
Back to top Generated by DocFX