[]
        
(Showing Draft Content)

GrapeCity.Documents.Pdf.Operators.PdfOperatorPosition

Struct PdfOperatorPosition

Namespace
GrapeCity.Documents.Pdf.Operators
Assembly
GcDocs.Pdf.dll

Represents the position of an operator in a content stream.

public struct PdfOperatorPosition : IEquatable<PdfOperatorPosition>
Implements
System.IEquatable<T><PdfOperatorPosition>
Inherited Members
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetType()

Fields

Empty

The empty position;

public static readonly PdfOperatorPosition Empty

Field Value

PdfOperatorPosition

Index

The index in a content stream. In most cases the Index will have one element, the position of the operator in the page (the "root") content stream. If the operator is in the content stream of form XObject used in the page content stream then Index will contain 2 elements: 0 - index of "Do" operator used to render form XObject in the page content stream 1 - index of the operator in the form XObject content stream.

public int[] Index

Field Value

int[]

Properties

IsEmpty

Gets a value indicating whether this position is empty.

public bool IsEmpty { get; }

Property Value

bool

Length

Gets the length of Index.

public int Length { get; }

Property Value

int

Methods

Clone()

public PdfOperatorPosition Clone()

Returns

PdfOperatorPosition

Compare(PdfOperatorPosition, PdfOperatorPosition)

Compares two PdfOperatorPosition objects.

public static int Compare(PdfOperatorPosition v1, PdfOperatorPosition v2)

Parameters

v1 PdfOperatorPosition
v2 PdfOperatorPosition

Returns

int

Create(int)

Create the PdfOperatorPosition with index of specified length.

public static PdfOperatorPosition Create(int length = 1)

Parameters

length int

The index length.

Returns

PdfOperatorPosition

The PdfOperatorPosition structure.

Equals(PdfOperatorPosition)

Determines whether two PdfOperatorPosition instances are equal.

public bool Equals(PdfOperatorPosition other)

Parameters

other PdfOperatorPosition

The PdfOperatorPosition to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

Equals(object)

Determines whether the specified object is equal to the current object.

public override bool Equals(object obj)

Parameters

obj object

The object to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

GetHashCode()

Returns a hash code for the current object.

public override int GetHashCode()

Returns

int

A hash code for the current object.

Inc()

Increments the index.

public void Inc()

Inc(int, int)

Increments the index on specified value.

public void Inc(int value, int level)

Parameters

value int

The increment value.

level int

The index to increment.

Inc(int)

Increments the index on specified value.

public void Inc(int value)

Parameters

value int

The increment value.

IsSameContentStreamWith(PdfOperatorPosition)

Checks whether a specified PdfOperatorPosition points to the same content stream as current PdfOperatorPosition.

public bool IsSameContentStreamWith(PdfOperatorPosition other)

Parameters

other PdfOperatorPosition

The PdfOperatorPosition to check.

Returns

bool

true if other points to the same content stream; false otherwise.

Pop()

Ends level.

public void Pop()

Push()

Starts new level.

public void Push()

ToString()

public override string ToString()

Returns

string

TryParse(string, out PdfOperatorPosition)

Tries to parse the PdfOperatorPosition from the string.

public static bool TryParse(string s, out PdfOperatorPosition value)

Parameters

s string
value PdfOperatorPosition

Returns

bool

Operators

operator ==(PdfOperatorPosition, PdfOperatorPosition)

The equality operator.

public static bool operator ==(PdfOperatorPosition v1, PdfOperatorPosition v2)

Parameters

v1 PdfOperatorPosition
v2 PdfOperatorPosition

Returns

bool

operator >(PdfOperatorPosition, PdfOperatorPosition)

Greater than operator.

public static bool operator >(PdfOperatorPosition v1, PdfOperatorPosition v2)

Parameters

v1 PdfOperatorPosition
v2 PdfOperatorPosition

Returns

bool

operator >=(PdfOperatorPosition, PdfOperatorPosition)

Greater or equal than operator.

public static bool operator >=(PdfOperatorPosition v1, PdfOperatorPosition v2)

Parameters

v1 PdfOperatorPosition
v2 PdfOperatorPosition

Returns

bool

operator !=(PdfOperatorPosition, PdfOperatorPosition)

The inequality operator.

public static bool operator !=(PdfOperatorPosition v1, PdfOperatorPosition v2)

Parameters

v1 PdfOperatorPosition
v2 PdfOperatorPosition

Returns

bool

operator <(PdfOperatorPosition, PdfOperatorPosition)

Less than operator.

public static bool operator <(PdfOperatorPosition v1, PdfOperatorPosition v2)

Parameters

v1 PdfOperatorPosition
v2 PdfOperatorPosition

Returns

bool

operator <=(PdfOperatorPosition, PdfOperatorPosition)

Less or equal than operator.

public static bool operator <=(PdfOperatorPosition v1, PdfOperatorPosition v2)

Parameters

v1 PdfOperatorPosition
v2 PdfOperatorPosition

Returns

bool