Data

public extension Data
  • Returns a hex encoded string representation of the data object.

    Declaration

    Swift

    var hexString: String { get }

    Return Value

    A string containing the hex encoded representation of the data object.

  • Returns a Foundation object from the JSON data.

    Declaration

    Swift

    func serializedJsonObject(options: JSONSerialization.ReadingOptions = .allowFragments) -> Any?

    Parameters

    options

    Options for reading the JSON data and creating the Foundation objects.

    Return Value

    A Foundation object from the JSON data in data, or nil if an error occurs.