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


@doc raw"""Information about the condition of a component.

    IoK8sApiCoreV1ComponentCondition(;
        error=nothing,
        message=nothing,
        status=nothing,
        type=nothing,
    )

    - error::String : Condition error code for a component. For example, a health check error code.
    - message::String : Message about the condition for a component. For example, information about a health check.
    - status::String : Status of the condition for a component. Valid values for \&quot;Healthy\&quot;: \&quot;True\&quot;, \&quot;False\&quot;, or \&quot;Unknown\&quot;.
    - type::String : Type of condition for a component. Valid value: \&quot;Healthy\&quot;
"""
mutable struct IoK8sApiCoreV1ComponentCondition <: SwaggerModel
    error::Any # spec type: Union{ Nothing, String } # spec name: error
    message::Any # spec type: Union{ Nothing, String } # spec name: message
    status::Any # spec type: Union{ Nothing, String } # spec name: status
    type::Any # spec type: Union{ Nothing, String } # spec name: type

    function IoK8sApiCoreV1ComponentCondition(;error=nothing, message=nothing, status=nothing, type=nothing)
        o = new()
        validate_property(IoK8sApiCoreV1ComponentCondition, Symbol("error"), error)
        setfield!(o, Symbol("error"), error)
        validate_property(IoK8sApiCoreV1ComponentCondition, Symbol("message"), message)
        setfield!(o, Symbol("message"), message)
        validate_property(IoK8sApiCoreV1ComponentCondition, Symbol("status"), status)
        setfield!(o, Symbol("status"), status)
        validate_property(IoK8sApiCoreV1ComponentCondition, Symbol("type"), type)
        setfield!(o, Symbol("type"), type)
        o
    end
end # type IoK8sApiCoreV1ComponentCondition

const _property_map_IoK8sApiCoreV1ComponentCondition = Dict{Symbol,Symbol}(Symbol("error")=>Symbol("error"), Symbol("message")=>Symbol("message"), Symbol("status")=>Symbol("status"), Symbol("type")=>Symbol("type"))
const _property_types_IoK8sApiCoreV1ComponentCondition = Dict{Symbol,String}(Symbol("error")=>"String", Symbol("message")=>"String", Symbol("status")=>"String", Symbol("type")=>"String")
Base.propertynames(::Type{ IoK8sApiCoreV1ComponentCondition }) = collect(keys(_property_map_IoK8sApiCoreV1ComponentCondition))
Swagger.property_type(::Type{ IoK8sApiCoreV1ComponentCondition }, name::Symbol) = Union{Nothing,eval(Base.Meta.parse(_property_types_IoK8sApiCoreV1ComponentCondition[name]))}
Swagger.field_name(::Type{ IoK8sApiCoreV1ComponentCondition }, property_name::Symbol) =  _property_map_IoK8sApiCoreV1ComponentCondition[property_name]

function check_required(o::IoK8sApiCoreV1ComponentCondition)
    (getproperty(o, Symbol("status")) === nothing) && (return false)
    (getproperty(o, Symbol("type")) === nothing) && (return false)
    true
end

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