UnorderedPair
public struct UnorderedPair<T> : SymmetricPair
extension UnorderedPair: CustomStringConvertible
extension UnorderedPair: Equatable where T: Equatable
extension UnorderedPair: Hashable where T: Hashable
extension UnorderedPair: Codable where T: Codable
Pair of two values of the same type for which the order of the values is not meaningful.
-
The first value contained herein.
Declaration
Swift
public let a: T -
The second value contained herein.
Declaration
Swift
public let b: T
-
Creates an
UnrderedPairwith the given values.Declaration
Swift
@inlinable public init(_ a: T, _ b: T)
-
Printable description of
UnorderedPair.Declaration
Swift
public var description: String { get }
-
Declaration
Swift
@inlinable public func other(_ value: T) -> T?Return Value
The value in this
UnorderedPairother than the givenvalue, if the givenvalueis contained herein. Otherwise,nil.
-
Declaration
Swift
@inlinable public static func == (lhs: UnorderedPair, rhs: UnorderedPair) -> BoolReturn Value
trueif both values contained by the givenUnorderedPairvalues are equivalent, regardless of order. Otherwise,false.
-
Implements hashable requirement.
Declaration
Swift
@inlinable public func hash(into hasher: inout Hasher)
View on GitHub
Install in Dash
UnorderedPair Structure Reference