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


mutable struct IoK8sApimachineryPkgApisMetaV1APIGroup <: SwaggerModel
    apiVersion::Any # spec type: Union{ Nothing, String } # spec name: apiVersion
    kind::Any # spec type: Union{ Nothing, String } # spec name: kind
    name::Any # spec type: Union{ Nothing, String } # spec name: name
    preferredVersion::Any # spec type: Union{ Nothing, IoK8sApimachineryPkgApisMetaV1GroupVersionForDiscovery } # spec name: preferredVersion
    serverAddressByClientCIDRs::Any # spec type: Union{ Nothing, Vector{IoK8sApimachineryPkgApisMetaV1ServerAddressByClientCIDR} } # spec name: serverAddressByClientCIDRs
    versions::Any # spec type: Union{ Nothing, Vector{IoK8sApimachineryPkgApisMetaV1GroupVersionForDiscovery} } # spec name: versions

    function IoK8sApimachineryPkgApisMetaV1APIGroup(;apiVersion=nothing, kind=nothing, name=nothing, preferredVersion=nothing, serverAddressByClientCIDRs=nothing, versions=nothing)
        o = new()
        validate_property(IoK8sApimachineryPkgApisMetaV1APIGroup, Symbol("apiVersion"), apiVersion)
        setfield!(o, Symbol("apiVersion"), apiVersion)
        validate_property(IoK8sApimachineryPkgApisMetaV1APIGroup, Symbol("kind"), kind)
        setfield!(o, Symbol("kind"), kind)
        validate_property(IoK8sApimachineryPkgApisMetaV1APIGroup, Symbol("name"), name)
        setfield!(o, Symbol("name"), name)
        validate_property(IoK8sApimachineryPkgApisMetaV1APIGroup, Symbol("preferredVersion"), preferredVersion)
        setfield!(o, Symbol("preferredVersion"), preferredVersion)
        validate_property(IoK8sApimachineryPkgApisMetaV1APIGroup, Symbol("serverAddressByClientCIDRs"), serverAddressByClientCIDRs)
        setfield!(o, Symbol("serverAddressByClientCIDRs"), serverAddressByClientCIDRs)
        validate_property(IoK8sApimachineryPkgApisMetaV1APIGroup, Symbol("versions"), versions)
        setfield!(o, Symbol("versions"), versions)
        o
    end
end # type IoK8sApimachineryPkgApisMetaV1APIGroup

const _property_map_IoK8sApimachineryPkgApisMetaV1APIGroup = Dict{Symbol,Symbol}(Symbol("apiVersion")=>Symbol("apiVersion"), Symbol("kind")=>Symbol("kind"), Symbol("name")=>Symbol("name"), Symbol("preferredVersion")=>Symbol("preferredVersion"), Symbol("serverAddressByClientCIDRs")=>Symbol("serverAddressByClientCIDRs"), Symbol("versions")=>Symbol("versions"))
const _property_types_IoK8sApimachineryPkgApisMetaV1APIGroup = Dict{Symbol,String}(Symbol("apiVersion")=>"String", Symbol("kind")=>"String", Symbol("name")=>"String", Symbol("preferredVersion")=>"IoK8sApimachineryPkgApisMetaV1GroupVersionForDiscovery", Symbol("serverAddressByClientCIDRs")=>"Vector{IoK8sApimachineryPkgApisMetaV1ServerAddressByClientCIDR}", Symbol("versions")=>"Vector{IoK8sApimachineryPkgApisMetaV1GroupVersionForDiscovery}")
Base.propertynames(::Type{ IoK8sApimachineryPkgApisMetaV1APIGroup }) = collect(keys(_property_map_IoK8sApimachineryPkgApisMetaV1APIGroup))
Swagger.property_type(::Type{ IoK8sApimachineryPkgApisMetaV1APIGroup }, name::Symbol) = Union{Nothing,eval(Base.Meta.parse(_property_types_IoK8sApimachineryPkgApisMetaV1APIGroup[name]))}
Swagger.field_name(::Type{ IoK8sApimachineryPkgApisMetaV1APIGroup }, property_name::Symbol) =  _property_map_IoK8sApimachineryPkgApisMetaV1APIGroup[property_name]

function check_required(o::IoK8sApimachineryPkgApisMetaV1APIGroup)
    (getproperty(o, Symbol("name")) === nothing) && (return false)
    (getproperty(o, Symbol("versions")) === nothing) && (return false)
    true
end

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