Class PdfStreamData
Namespace: AdCodicem.Pdf.Objects
Assembly: AdCodicem.Pdf.dll
Supplies the raw, still-encoded bytes of a stream.
public abstract class PdfStreamData
Inheritance
Inherited Members
object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
Remarks
Stream data is deliberately indirect. A stream read from a file knows only where its bytes live, and touches them when — and only when — the caller asks. Copying a stream between documents therefore moves encoded bytes without a decompress/recompress cycle.
Properties
Length
Gets the number of encoded bytes.
public abstract int Length { get; }
Property Value
Position
Gets the offset in the file the data was read from, or -1 when it never came from one. A diagnostic about a stream is only actionable if it says which stream.
public virtual long Position { get; }
Property Value
Methods
FromMemory(ReadOnlyMemory<byte>)
Creates stream data over bytes already in memory.
public static PdfStreamData FromMemory(ReadOnlyMemory<byte> bytes)
Parameters
bytes ReadOnlyMemory<byte>
Returns
GetBytes()
Returns the encoded bytes, exactly as they appear in the file.
public abstract ReadOnlyMemory<byte> GetBytes()