Skip to content

JSONReference_PathComponent

mattpolzin edited this page Oct 1, 2020 · 3 revisions

JSONReference.PathComponent

A JSON Reference path component, as described by the JSON pointer specification.

public struct PathComponent: CodingKey, LosslessStringConvertible, RawRepresentable, ExpressibleByStringLiteral, Equatable, Hashable

Inheritance

CodingKey, Equatable, ExpressibleByStringLiteral, Hashable, LosslessStringConvertible, RawRepresentable

Initializers

init(stringLiteral:)

public init(stringLiteral value: String)

init(_:)

public init(_ description: String)

init(rawValue:)

public init(rawValue: String)

init(stringValue:)

public init(stringValue: String)

init(intValue:)

Creates a PathComponent that represents the index in a JSON Array.

public init(intValue: Int)

Properties

rawValue

var rawValue: String

stringValue

The string value produces the human-readable path component but not the proper string encoding of the path component per the specification. Use the rawValue for a proper spec encoding.

var stringValue: String

description

The description produces the human-readable path component but not the proper string encoding of the path component per the specification. Use the rawValue for a proper spec encoding.

var description: String

intValue

var intValue: Int?

Methods

property(named:)

public static func property(named name: String) -> Self

index(_:)

public static func index(_ index: Int) -> Self
Types
Protocols
Global Functions
Extensions
Clone this wiki locally