GemBox.Pdf
  • Overview
  • Examples
  • Free version
  • Support
  • Pricelist

    Show / Hide Table of Contents

    PdfEncodingExtensions Class

    Namespace:
    GemBox.Pdf.Text
    Assembly:
    GemBox.Pdf.dll

    A type that extends IPdfEncoding interface.

    • C#
    • VB.NET
    public static class PdfEncodingExtensions
    Public Module PdfEncodingExtensions
    Inheritance:
    System.Object
    PdfEncodingExtensions

    Methods

    GetBytes(IPdfEncoding, ReadOnlySpan<Char>)

    Encodes all the characters in the specified string into a sequence of bytes.

    • C#
    • VB.NET
    public static byte[] GetBytes(this IPdfEncoding encoding, ReadOnlySpan<char> s)
    <ExtensionAttribute>
    Public Shared Function GetBytes(encoding As IPdfEncoding, s As ReadOnlySpan(Of Char)) As Byte()
    Parameters
    encoding
    IPdfEncoding

    The encoding.

    s
    System.ReadOnlySpan<System.Char>

    The string containing the characters to encode.

    Returns
    System.Byte[]

    A byte array containing the results of encoding the specified set of characters.

    Exceptions
    System.ArgumentNullException

    encoding or s is null.

    GetString(IPdfEncoding, Byte[])

    Decodes a sequence of bytes from the specified byte array into a string.

    • C#
    • VB.NET
    public static string GetString(this IPdfEncoding encoding, byte[] bytes)
    <ExtensionAttribute>
    Public Shared Function GetString(encoding As IPdfEncoding, bytes As Byte()) As String
    Parameters
    encoding
    IPdfEncoding

    The encoding.

    bytes
    System.Byte[]

    The byte array containing the sequence of bytes to decode.

    Returns
    System.String

    A string that contains the results of decoding the specified sequence of bytes.

    Exceptions
    System.ArgumentNullException

    encoding or bytes is null.

    Back to top

    Facebook • Twitter • LinkedIn

    © GemBox Ltd. — All rights reserved.