[]
        
(Showing Draft Content)

GrapeCity.Documents.Pdf.Spec.PdfString

Class PdfString

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

Represents a PDF String.

public class PdfString : IPdfString, ActionHide.ILinkedObject, ActionFieldsBase.IFieldDef, IReadOnlyList<byte>, IReadOnlyCollection<byte>, IEnumerable<byte>, IEnumerable, IEquatable<PdfString>, IComparable<PdfString>
Inheritance
object
PdfString
Implements
System.Collections.Generic.IReadOnlyList<T><byte>
System.Collections.Generic.IReadOnlyCollection<T><byte>
System.Collections.Generic.IEnumerable<T><byte>
System.Collections.IEnumerable
System.IEquatable<T><PdfString>
System.IComparable<T><PdfString>
Inherited Members
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetType()
object.MemberwiseClone()
Extension Methods

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Constructors

PdfString(byte[], PdfStringFlags)

Initializes a new instance of the PdfString class.

public PdfString(byte[] value, PdfStringFlags flags)

Parameters

value byte[]

The value.

flags PdfStringFlags

The value of Flags.

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

PdfString(byte[], int, int)

Initializes a new instance of the PdfString class.

public PdfString(byte[] value, int offset, int length)

Parameters

value byte[]

The byte array.

offset int

The offset in the value.

length int

The length of the name.

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

PdfString(byte[])

Initializes a new instance of the PdfString class.

public PdfString(byte[] value)

Parameters

value byte[]

The value.

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

PdfString(string)

Initializes a new instance of the PdfString class.

public PdfString(string value)

Parameters

value string

The value.

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Fields

Adobe

"Adobe"

public static readonly PdfString Adobe

Field Value

PdfString

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Empty

The empty instance of the PdfString.

public static readonly PdfString Empty

Field Value

PdfString

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Flags

The state of the PdfString object.

public PdfStringFlags Flags

Field Value

PdfStringFlags

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Identity

"Identity"

public static readonly PdfString Identity

Field Value

PdfString

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

open

"open"

public static readonly PdfString open

Field Value

PdfString

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

print

"print"

public static readonly PdfString print

Field Value

PdfString

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

sRGB

"sRGB"

public static readonly PdfString sRGB

Field Value

PdfString

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

UCS

"UCS"

public static readonly PdfString UCS

Field Value

PdfString

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Properties

Count

Gets the number of elements contained in the PdfString.

public int Count { get; }

Property Value

int

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

this[int]

Gets or sets the byte at the specified index.

public byte this[int index] { get; }

Parameters

index int

The zero-based index of the byte to get or set.

Property Value

byte

The byte at the specified index.

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Methods

BytesToString(IList<byte>)

Converts a list of bytes representing a PDF string to a string.

public static string BytesToString(IList<byte> bytes)

Parameters

bytes System.Collections.Generic.IList<T><byte>

Returns

string

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

CompareTo(PdfString)

Compares the current PdfString with another PdfString and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.

public int CompareTo(PdfString other)

Parameters

other PdfString

The other PdfString.

Returns

int

A value that indicates the relative order of the objects being compared. The return value has these meanings:

  • Less than 0This instance precedes other in the sort order.
  • 0This instance occurs in the same position in the sort order as other.
  • Greater than 0This instance follows other in the sort other.

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Equals(PdfString)

Checks whether this PdfString is equal to value.

public bool Equals(PdfString value)

Parameters

value PdfString

Returns

bool

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

Equals(object)

public override bool Equals(object obj)

Parameters

obj object

Returns

bool

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

FromString(string)

Creates a PdfString from the passed string.

public static PdfString FromString(string s)

Parameters

s string

The string to create the PDF string from.

Returns

PdfString

The created PDF string, or null if s is null.

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

GetHashCode()

public override int GetHashCode()

Returns

int

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

StringToBytes(string)

Converts a string to the array of bytes representing the PDF string.

public static byte[] StringToBytes(string s)

Parameters

s string

Returns

byte[]

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.

ToString()

public override string ToString()

Returns

string

Remarks

Technically a PDF string is an array of bytes. Its interpretation depends on the context. The PDF specification describes the following possible types:

  • byte string
  • text string
  • Unicode string
  • etc.