Structureswift-nio 2.72.0NIOPosix
VsockAddress
A vsock socket address.
VsockAddress.swift:38struct VsockAddress
A socket address is defined as a combination of a Context Identifier (CID) and a port number. The CID identifies the source or destination, which is either a virtual machine or the host. The port number differentiates between multiple services running on a single machine.
For well-known CID values and port numbers, see ContextID
and Port
.
Citizens in NIOPosix
Conformances
protocol CustomStringConvertible
A type with a customized textual representation.
protocol Equatable
A type that can be compared for value equality.
protocol Hashable
A type that can be hashed into a
Hasher
to produce an integer hash value.protocol Sendable
A type whose values can safely be passed across concurrency domains by copying.
Types
struct ContextID
A vsock Context Identifier (CID).
struct Port
A vsock port number.
Type members
init(cid: ContextID, port: Port
) Creates a new vsock address.
Instance members
var cid: ContextID
The context ID associated with the address.
var description: String
var port: Port
The port associated with the address.
func withSockAddr<T>((UnsafePointer<sockaddr>, Int) throws -> T
) rethrows -> T
Type features
static func != (lhs: Self, rhs: Self
) -> Bool Returns a Boolean value indicating whether two values are not equal.