Fields

any: os.sockaddr,
un: if (has_unix_sockets) os.sockaddr.un else void,

Functions

fn eql(a: Address, b: Address) bool

No documentation provided.

fn format(self: Address, comptime fmt: []const u8, options: std.fmt.FormatOptions, out_stream: anytype) !void

No documentation provided.

fn getOsSockLen(self: Address) os.socklen_t

No documentation provided.

fn getPort(self: Address) u16

Returns the port in native endian. Asserts that the address is ip4 or ip6.

fn initIp4(addr: [4]u8, port: u16) Address

No documentation provided.

fn initIp6(addr: [16]u8, port: u16, flowinfo: u32, scope_id: u32) Address

No documentation provided.

fn initPosix(addr: *const align(4) os.sockaddr) Address

Asserts that addr is an IP address. This function will read past the end of t…

Asserts that addr is an IP address. This function will read past the end of the pointer, with a size depending on the address family.

fn initUnix(path: []const u8) !Address

No documentation provided.

fn parseExpectingFamily(name: []const u8, family: os.sa_family_t, port: u16) !Address

No documentation provided.

fn parseIp(name: []const u8, port: u16) !Address

Parse the given IP address string into an Address value. It is recommended to u…

Parse the given IP address string into an Address value. It is recommended to use resolveIp instead, to handle IPv6 link-local unix addresses.

fn parseIp4(buf: []const u8, port: u16) !Address

No documentation provided.

fn parseIp6(buf: []const u8, port: u16) !Address

No documentation provided.

fn resolveIp(name: []const u8, port: u16) !Address

No documentation provided.

fn resolveIp6(buf: []const u8, port: u16) !Address

No documentation provided.

fn setPort(self: *Address, port: u16) void

port is native-endian. Asserts that the address is ip4 or ip6.