Class: Authentik::Api::AgentConfig
- Inherits:
-
ApiModelBase
- Object
- ApiModelBase
- Authentik::Api::AgentConfig
- Defined in:
- lib/authentik/api/models/agent_config.rb
Overview
Base serializer class which doesn’t implement create/update methods
Defined Under Namespace
Classes: EnumAttributeValidator
Instance Attribute Summary collapse
-
#auth_terminate_session_on_expiry ⇒ Object
Returns the value of attribute auth_terminate_session_on_expiry.
-
#authorization_flow ⇒ Object
Returns the value of attribute authorization_flow.
-
#device_id ⇒ Object
Returns the value of attribute device_id.
-
#jwks_auth ⇒ Object
Returns the value of attribute jwks_auth.
-
#jwks_challenge ⇒ Object
Returns the value of attribute jwks_challenge.
-
#license_status ⇒ Object
Returns the value of attribute license_status.
-
#nss_gid_offset ⇒ Object
Returns the value of attribute nss_gid_offset.
-
#nss_uid_offset ⇒ Object
Returns the value of attribute nss_uid_offset.
-
#refresh_interval ⇒ Object
Returns the value of attribute refresh_interval.
-
#system_config ⇒ Object
Returns the value of attribute system_config.
Class Method Summary collapse
-
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about.
-
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about.
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.build_from_hash(attributes) ⇒ Object
Builds the object from hash.
-
.openapi_nullable ⇒ Object
List of attributes with nullable: true.
-
.openapi_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Integer
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ AgentConfig
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Methods inherited from ApiModelBase
_deserialize, #_to_hash, #to_body, #to_s
Constructor Details
#initialize(attributes = {}) ⇒ AgentConfig
Initializes the object
108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 |
# File 'lib/authentik/api/models/agent_config.rb', line 108 def initialize(attributes = {}) if (!attributes.is_a?(Hash)) fail ArgumentError, "The input argument (attributes) must be a hash in `Authentik::Api::AgentConfig` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key acceptable_attribute_map = self.class.acceptable_attribute_map attributes = attributes.each_with_object({}) { |(k, v), h| if (!acceptable_attribute_map.key?(k.to_sym)) fail ArgumentError, "`#{k}` is not a valid attribute in `Authentik::Api::AgentConfig`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect end h[k.to_sym] = v } if attributes.key?(:'device_id') self.device_id = attributes[:'device_id'] else self.device_id = nil end if attributes.key?(:'refresh_interval') self.refresh_interval = attributes[:'refresh_interval'] else self.refresh_interval = nil end if attributes.key?(:'authorization_flow') self. = attributes[:'authorization_flow'] else self. = nil end if attributes.key?(:'jwks_auth') if (value = attributes[:'jwks_auth']).is_a?(Hash) self.jwks_auth = value end else self.jwks_auth = nil end if attributes.key?(:'jwks_challenge') if (value = attributes[:'jwks_challenge']).is_a?(Hash) self.jwks_challenge = value end else self.jwks_challenge = nil end if attributes.key?(:'nss_uid_offset') self.nss_uid_offset = attributes[:'nss_uid_offset'] else self.nss_uid_offset = nil end if attributes.key?(:'nss_gid_offset') self.nss_gid_offset = attributes[:'nss_gid_offset'] else self.nss_gid_offset = nil end if attributes.key?(:'auth_terminate_session_on_expiry') self.auth_terminate_session_on_expiry = attributes[:'auth_terminate_session_on_expiry'] else self.auth_terminate_session_on_expiry = nil end if attributes.key?(:'system_config') self.system_config = attributes[:'system_config'] else self.system_config = nil end if attributes.key?(:'license_status') self.license_status = attributes[:'license_status'] else self.license_status = nil end end |
Instance Attribute Details
#auth_terminate_session_on_expiry ⇒ Object
Returns the value of attribute auth_terminate_session_on_expiry.
27 28 29 |
# File 'lib/authentik/api/models/agent_config.rb', line 27 def auth_terminate_session_on_expiry @auth_terminate_session_on_expiry end |
#authorization_flow ⇒ Object
Returns the value of attribute authorization_flow.
17 18 19 |
# File 'lib/authentik/api/models/agent_config.rb', line 17 def @authorization_flow end |
#device_id ⇒ Object
Returns the value of attribute device_id.
13 14 15 |
# File 'lib/authentik/api/models/agent_config.rb', line 13 def device_id @device_id end |
#jwks_auth ⇒ Object
Returns the value of attribute jwks_auth.
19 20 21 |
# File 'lib/authentik/api/models/agent_config.rb', line 19 def jwks_auth @jwks_auth end |
#jwks_challenge ⇒ Object
Returns the value of attribute jwks_challenge.
21 22 23 |
# File 'lib/authentik/api/models/agent_config.rb', line 21 def jwks_challenge @jwks_challenge end |
#license_status ⇒ Object
Returns the value of attribute license_status.
31 32 33 |
# File 'lib/authentik/api/models/agent_config.rb', line 31 def license_status @license_status end |
#nss_gid_offset ⇒ Object
Returns the value of attribute nss_gid_offset.
25 26 27 |
# File 'lib/authentik/api/models/agent_config.rb', line 25 def nss_gid_offset @nss_gid_offset end |
#nss_uid_offset ⇒ Object
Returns the value of attribute nss_uid_offset.
23 24 25 |
# File 'lib/authentik/api/models/agent_config.rb', line 23 def nss_uid_offset @nss_uid_offset end |
#refresh_interval ⇒ Object
Returns the value of attribute refresh_interval.
15 16 17 |
# File 'lib/authentik/api/models/agent_config.rb', line 15 def refresh_interval @refresh_interval end |
#system_config ⇒ Object
Returns the value of attribute system_config.
29 30 31 |
# File 'lib/authentik/api/models/agent_config.rb', line 29 def system_config @system_config end |
Class Method Details
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about
72 73 74 |
# File 'lib/authentik/api/models/agent_config.rb', line 72 def self.acceptable_attribute_map attribute_map end |
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about
77 78 79 |
# File 'lib/authentik/api/models/agent_config.rb', line 77 def self.acceptable_attributes acceptable_attribute_map.values end |
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
56 57 58 59 60 61 62 63 64 65 66 67 68 69 |
# File 'lib/authentik/api/models/agent_config.rb', line 56 def self.attribute_map { :'device_id' => :'device_id', :'refresh_interval' => :'refresh_interval', :'authorization_flow' => :'authorization_flow', :'jwks_auth' => :'jwks_auth', :'jwks_challenge' => :'jwks_challenge', :'nss_uid_offset' => :'nss_uid_offset', :'nss_gid_offset' => :'nss_gid_offset', :'auth_terminate_session_on_expiry' => :'auth_terminate_session_on_expiry', :'system_config' => :'system_config', :'license_status' => :'license_status' } end |
.build_from_hash(attributes) ⇒ Object
Builds the object from hash
339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 |
# File 'lib/authentik/api/models/agent_config.rb', line 339 def self.build_from_hash(attributes) return nil unless attributes.is_a?(Hash) attributes = attributes.transform_keys(&:to_sym) transformed_hash = {} openapi_types.each_pair do |key, type| if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = nil elsif type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the attribute # is documented as an array but the input is not if attributes[attribute_map[key]].is_a?(Array) transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) } end elsif !attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]]) end end new(transformed_hash) end |
.openapi_nullable ⇒ Object
List of attributes with nullable: true
98 99 100 101 102 103 104 |
# File 'lib/authentik/api/models/agent_config.rb', line 98 def self.openapi_nullable Set.new([ :'authorization_flow', :'jwks_challenge', :'license_status' ]) end |
.openapi_types ⇒ Object
Attribute type mapping.
82 83 84 85 86 87 88 89 90 91 92 93 94 95 |
# File 'lib/authentik/api/models/agent_config.rb', line 82 def self.openapi_types { :'device_id' => :'String', :'refresh_interval' => :'Integer', :'authorization_flow' => :'String', :'jwks_auth' => :'Hash<String, Object>', :'jwks_challenge' => :'Hash<String, Object>', :'nss_uid_offset' => :'Integer', :'nss_gid_offset' => :'Integer', :'auth_terminate_session_on_expiry' => :'Boolean', :'system_config' => :'Config', :'license_status' => :'LicenseStatusEnum' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
309 310 311 312 313 314 315 316 317 318 319 320 321 322 |
# File 'lib/authentik/api/models/agent_config.rb', line 309 def ==(o) return true if self.equal?(o) self.class == o.class && device_id == o.device_id && refresh_interval == o.refresh_interval && == o. && jwks_auth == o.jwks_auth && jwks_challenge == o.jwks_challenge && nss_uid_offset == o.nss_uid_offset && nss_gid_offset == o.nss_gid_offset && auth_terminate_session_on_expiry == o.auth_terminate_session_on_expiry && system_config == o.system_config && license_status == o.license_status end |
#eql?(o) ⇒ Boolean
326 327 328 |
# File 'lib/authentik/api/models/agent_config.rb', line 326 def eql?(o) self == o end |
#hash ⇒ Integer
Calculates hash code according to all attributes.
332 333 334 |
# File 'lib/authentik/api/models/agent_config.rb', line 332 def hash [device_id, refresh_interval, , jwks_auth, jwks_challenge, nss_uid_offset, nss_gid_offset, auth_terminate_session_on_expiry, system_config, license_status].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 |
# File 'lib/authentik/api/models/agent_config.rb', line 189 def list_invalid_properties warn '[DEPRECATED] the `list_invalid_properties` method is obsolete' invalid_properties = Array.new if @device_id.nil? invalid_properties.push('invalid value for "device_id", device_id cannot be nil.') end if @refresh_interval.nil? invalid_properties.push('invalid value for "refresh_interval", refresh_interval cannot be nil.') end if @jwks_auth.nil? invalid_properties.push('invalid value for "jwks_auth", jwks_auth cannot be nil.') end if @nss_uid_offset.nil? invalid_properties.push('invalid value for "nss_uid_offset", nss_uid_offset cannot be nil.') end if @nss_gid_offset.nil? invalid_properties.push('invalid value for "nss_gid_offset", nss_gid_offset cannot be nil.') end if @auth_terminate_session_on_expiry.nil? invalid_properties.push('invalid value for "auth_terminate_session_on_expiry", auth_terminate_session_on_expiry cannot be nil.') end if @system_config.nil? invalid_properties.push('invalid value for "system_config", system_config cannot be nil.') end invalid_properties end |
#to_hash ⇒ Hash
Returns the object in the form of hash
361 362 363 364 365 366 367 368 369 370 371 372 373 |
# File 'lib/authentik/api/models/agent_config.rb', line 361 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = self.send(attr) if value.nil? is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end hash[param] = _to_hash(value) end hash end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
225 226 227 228 229 230 231 232 233 234 235 |
# File 'lib/authentik/api/models/agent_config.rb', line 225 def valid? warn '[DEPRECATED] the `valid?` method is obsolete' return false if @device_id.nil? return false if @refresh_interval.nil? return false if @jwks_auth.nil? return false if @nss_uid_offset.nil? return false if @nss_gid_offset.nil? return false if @auth_terminate_session_on_expiry.nil? return false if @system_config.nil? true end |