Array

public extension Array
public extension Array where Element == URLQueryItem
public extension Array where Element == String
public extension Array where Element == JsonOutput
  • Converts current array of arbitrary objects to a JSON String or nil if it cannot be converted.

    Declaration

    Swift

    var jsonString: String? { get }

    Return Value

    Optional JSON String representation of the input or nil if it cannot be converted.

Available where Element == URLQueryItem

  • Converts current array of URLQueryItem to a dictionary of URLQueryItem values, keyed by URLQueryItem names.

    Declaration

    Swift

    var dictionary: [String : String] { get }

    Return Value

    Dictionary of URLQueryItem values, keyed by URLQueryItem names.

Available where Element == String

  • Converts current array of String to a JSON String or an empty JSON Array String if it cannot be converted/.

    Declaration

    Swift

    var jsonStringArray: String { get }

    Return Value

    JSON String representation of the input or an empty JSON Array String if it cannot be converted.

Available where Element == JsonOutput

  • Returns JSON String representation of an Array where the element type conforms to JsonOutput protocol or an empty JSON Array String if it cannot be converted..

    Declaration

    Swift

    var json: String { get }

    Return Value

    JSON String representation of the input or an empty JSON Array String if it cannot be converted.