subscript(_:as:default:)
Get a value in this array as an endpoint.
Declaration
subscript(index: Int, as type: XPCEndpoint.Type = XPCEndpoint.self, default defaultValue: @autoclosure () -> XPCEndpoint) -> XPCEndpoint { get }Parameters
- index:
The index at which to get the endpoint.
- type:
The expected type of the resulting value.
- defaultValue:
The value to produce if no endpoint is available at
index.
Return Value
An endpoint value, possibly defaultValue.