# This file was generated by the Julia Swagger Code Generator
# Do not modify this file directly. Modify the swagger specification instead.


@doc raw"""EndpointSubset is a group of addresses with a common set of ports. The expanded set of endpoints is the Cartesian product of Addresses x Ports. For example, given:   {     Addresses: [{\&quot;ip\&quot;: \&quot;10.10.1.1\&quot;}, {\&quot;ip\&quot;: \&quot;10.10.2.2\&quot;}],     Ports:     [{\&quot;name\&quot;: \&quot;a\&quot;, \&quot;port\&quot;: 8675}, {\&quot;name\&quot;: \&quot;b\&quot;, \&quot;port\&quot;: 309}]   } The resulting set of endpoints can be viewed as:     a: [ 10.10.1.1:8675, 10.10.2.2:8675 ],     b: [ 10.10.1.1:309, 10.10.2.2:309 ]

    IoK8sApiCoreV1EndpointSubset(;
        addresses=nothing,
        notReadyAddresses=nothing,
        ports=nothing,
    )

    - addresses::Vector{IoK8sApiCoreV1EndpointAddress} : IP addresses which offer the related ports that are marked as ready. These endpoints should be considered safe for load balancers and clients to utilize.
    - notReadyAddresses::Vector{IoK8sApiCoreV1EndpointAddress} : IP addresses which offer the related ports but are not currently marked as ready because they have not yet finished starting, have recently failed a readiness check, or have recently failed a liveness check.
    - ports::Vector{IoK8sApiCoreV1EndpointPort} : Port numbers available on the related IP addresses.
"""
mutable struct IoK8sApiCoreV1EndpointSubset <: SwaggerModel
    addresses::Any # spec type: Union{ Nothing, Vector{IoK8sApiCoreV1EndpointAddress} } # spec name: addresses
    notReadyAddresses::Any # spec type: Union{ Nothing, Vector{IoK8sApiCoreV1EndpointAddress} } # spec name: notReadyAddresses
    ports::Any # spec type: Union{ Nothing, Vector{IoK8sApiCoreV1EndpointPort} } # spec name: ports

    function IoK8sApiCoreV1EndpointSubset(;addresses=nothing, notReadyAddresses=nothing, ports=nothing)
        o = new()
        validate_property(IoK8sApiCoreV1EndpointSubset, Symbol("addresses"), addresses)
        setfield!(o, Symbol("addresses"), addresses)
        validate_property(IoK8sApiCoreV1EndpointSubset, Symbol("notReadyAddresses"), notReadyAddresses)
        setfield!(o, Symbol("notReadyAddresses"), notReadyAddresses)
        validate_property(IoK8sApiCoreV1EndpointSubset, Symbol("ports"), ports)
        setfield!(o, Symbol("ports"), ports)
        o
    end
end # type IoK8sApiCoreV1EndpointSubset

const _property_map_IoK8sApiCoreV1EndpointSubset = Dict{Symbol,Symbol}(Symbol("addresses")=>Symbol("addresses"), Symbol("notReadyAddresses")=>Symbol("notReadyAddresses"), Symbol("ports")=>Symbol("ports"))
const _property_types_IoK8sApiCoreV1EndpointSubset = Dict{Symbol,String}(Symbol("addresses")=>"Vector{IoK8sApiCoreV1EndpointAddress}", Symbol("notReadyAddresses")=>"Vector{IoK8sApiCoreV1EndpointAddress}", Symbol("ports")=>"Vector{IoK8sApiCoreV1EndpointPort}")
Base.propertynames(::Type{ IoK8sApiCoreV1EndpointSubset }) = collect(keys(_property_map_IoK8sApiCoreV1EndpointSubset))
Swagger.property_type(::Type{ IoK8sApiCoreV1EndpointSubset }, name::Symbol) = Union{Nothing,eval(Base.Meta.parse(_property_types_IoK8sApiCoreV1EndpointSubset[name]))}
Swagger.field_name(::Type{ IoK8sApiCoreV1EndpointSubset }, property_name::Symbol) =  _property_map_IoK8sApiCoreV1EndpointSubset[property_name]

function check_required(o::IoK8sApiCoreV1EndpointSubset)
    true
end

function validate_property(::Type{ IoK8sApiCoreV1EndpointSubset }, name::Symbol, val)
end
