Class: EmassClient::ControlsGet
- Inherits:
-
Object
- Object
- EmassClient::ControlsGet
- Defined in:
- lib/emass_client/models/controls_get.rb
Defined Under Namespace
Classes: EnumAttributeValidator
Instance Attribute Summary collapse
-
#acronym ⇒ Object
- Required
-
Acronym of the system record.
-
#ccis ⇒ Object
- Read-only
-
Comma separated list of CCIs associated with the control.
-
#common_control_provider ⇒ Object
- Conditional
-
Indicate the type of Common Control Provider for an “Inherited” Security Control.
-
#compliance_status ⇒ Object
- Read-only
-
Compliance of the control.
-
#control_designation ⇒ Object
- Required
-
Control designations.
-
#estimated_completion_date ⇒ Object
- Required
-
Field is required for Implementation Plan.
-
#impact ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High).
-
#impact_description ⇒ Object
- Optional
-
Include description of Security Control’s impact.
-
#implementation_narrative ⇒ Object
- Required
-
Includes security control comments.
-
#implementation_status ⇒ Object
- Optional
-
Implementation Status of the Security Control for the information system.
-
#included_status ⇒ Object
- Read-only
-
Indicates the manner by which a control was included in the system’s categorization.
-
#is_inherited ⇒ Object
- Read-only
-
Indicates whether a control is inherited.
-
#likelihood ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High).
-
#modified_by_overlays ⇒ Object
- Read-only
-
List of overlays that affect the control.
-
#na_justification ⇒ Object
- Conditional
-
Provide justification for Security Controls deemed Not Applicable to the system.
-
#name ⇒ Object
- Read-only
-
Name of the system record.
-
#recommendations ⇒ Object
- Optional
-
Include recommendations.
-
#relevance_of_threat ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High).
-
#residual_risk_level ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High).
-
#responsible_entities ⇒ Object
- Required
-
Include written description of Responsible Entities that are responsible for the Security Control.
-
#severity ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High).
-
#slcm_comments ⇒ Object
- Conditional
-
Additional comments for Security Control regarding SLCM.
-
#slcm_criticality ⇒ Object
- Conditional
-
Criticality of Security Control regarding SLCM.
-
#slcm_frequency ⇒ Object
- Conditional
-
SLCM frequency.
-
#slcm_method ⇒ Object
- Conditional
-
SLCM method utilized.
-
#slcm_reporting ⇒ Object
- Conditional
-
Method for reporting Security Control for SLCM.
-
#slcm_tracking ⇒ Object
- Conditional
-
How Non-Compliant Security Controls will be tracked for SLCM.
-
#system_id ⇒ Object
- Required
-
Unique system record identifier.
-
#test_method ⇒ Object
- Optional
-
Identifies the assessment method / combination that will determine if the security requirements are implemented correctly.
-
#vulnerabilty_summary ⇒ Object
- Optional
-
Include vulnerability summary.
Class Method Summary collapse
-
.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.
-
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type.
-
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Integer
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ ControlsGet
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility).
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Constructor Details
#initialize(attributes = {}) ⇒ ControlsGet
Initializes the object
239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 |
# File 'lib/emass_client/models/controls_get.rb', line 239 def initialize(attributes = {}) if (!attributes.is_a?(Hash)) fail ArgumentError, "The input argument (attributes) must be a hash in `EmassClient::ControlsGet` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| if (!self.class.attribute_map.key?(k.to_sym)) fail ArgumentError, "`#{k}` is not a valid attribute in `EmassClient::ControlsGet`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect end h[k.to_sym] = v } if attributes.key?(:'system_id') self.system_id = attributes[:'system_id'] end if attributes.key?(:'name') self.name = attributes[:'name'] end if attributes.key?(:'acronym') self.acronym = attributes[:'acronym'] end if attributes.key?(:'ccis') self.ccis = attributes[:'ccis'] end if attributes.key?(:'is_inherited') self.is_inherited = attributes[:'is_inherited'] end if attributes.key?(:'modified_by_overlays') self. = attributes[:'modified_by_overlays'] end if attributes.key?(:'included_status') self.included_status = attributes[:'included_status'] end if attributes.key?(:'compliance_status') self.compliance_status = attributes[:'compliance_status'] end if attributes.key?(:'responsible_entities') self.responsible_entities = attributes[:'responsible_entities'] end if attributes.key?(:'implementation_status') self.implementation_status = attributes[:'implementation_status'] end if attributes.key?(:'common_control_provider') self.common_control_provider = attributes[:'common_control_provider'] end if attributes.key?(:'na_justification') self.na_justification = attributes[:'na_justification'] end if attributes.key?(:'control_designation') self.control_designation = attributes[:'control_designation'] end if attributes.key?(:'estimated_completion_date') self.estimated_completion_date = attributes[:'estimated_completion_date'] end if attributes.key?(:'implementation_narrative') self.implementation_narrative = attributes[:'implementation_narrative'] end if attributes.key?(:'slcm_criticality') self.slcm_criticality = attributes[:'slcm_criticality'] end if attributes.key?(:'slcm_frequency') self.slcm_frequency = attributes[:'slcm_frequency'] end if attributes.key?(:'slcm_method') self.slcm_method = attributes[:'slcm_method'] end if attributes.key?(:'slcm_reporting') self.slcm_reporting = attributes[:'slcm_reporting'] end if attributes.key?(:'slcm_tracking') self.slcm_tracking = attributes[:'slcm_tracking'] end if attributes.key?(:'slcm_comments') self.slcm_comments = attributes[:'slcm_comments'] end if attributes.key?(:'severity') self.severity = attributes[:'severity'] end if attributes.key?(:'vulnerabilty_summary') self.vulnerabilty_summary = attributes[:'vulnerabilty_summary'] end if attributes.key?(:'recommendations') self.recommendations = attributes[:'recommendations'] end if attributes.key?(:'relevance_of_threat') self.relevance_of_threat = attributes[:'relevance_of_threat'] end if attributes.key?(:'likelihood') self.likelihood = attributes[:'likelihood'] end if attributes.key?(:'impact') self.impact = attributes[:'impact'] end if attributes.key?(:'impact_description') self.impact_description = attributes[:'impact_description'] end if attributes.key?(:'residual_risk_level') self.residual_risk_level = attributes[:'residual_risk_level'] end if attributes.key?(:'test_method') self.test_method = attributes[:'test_method'] end end |
Instance Attribute Details
#acronym ⇒ Object
- Required
-
Acronym of the system record.
25 26 27 |
# File 'lib/emass_client/models/controls_get.rb', line 25 def acronym @acronym end |
#ccis ⇒ Object
- Read-only
-
Comma separated list of CCIs associated with the control.
28 29 30 |
# File 'lib/emass_client/models/controls_get.rb', line 28 def ccis @ccis end |
#common_control_provider ⇒ Object
- Conditional
-
Indicate the type of Common Control Provider for an “Inherited” Security Control.
49 50 51 |
# File 'lib/emass_client/models/controls_get.rb', line 49 def common_control_provider @common_control_provider end |
#compliance_status ⇒ Object
- Read-only
-
Compliance of the control.
40 41 42 |
# File 'lib/emass_client/models/controls_get.rb', line 40 def compliance_status @compliance_status end |
#control_designation ⇒ Object
- Required
-
Control designations
55 56 57 |
# File 'lib/emass_client/models/controls_get.rb', line 55 def control_designation @control_designation end |
#estimated_completion_date ⇒ Object
- Required
-
Field is required for Implementation Plan.
58 59 60 |
# File 'lib/emass_client/models/controls_get.rb', line 58 def estimated_completion_date @estimated_completion_date end |
#impact ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High)
97 98 99 |
# File 'lib/emass_client/models/controls_get.rb', line 97 def impact @impact end |
#impact_description ⇒ Object
- Optional
-
Include description of Security Control’s impact.
100 101 102 |
# File 'lib/emass_client/models/controls_get.rb', line 100 def impact_description @impact_description end |
#implementation_narrative ⇒ Object
- Required
-
Includes security control comments. Character Limit = 2,000.
61 62 63 |
# File 'lib/emass_client/models/controls_get.rb', line 61 def implementation_narrative @implementation_narrative end |
#implementation_status ⇒ Object
- Optional
-
Implementation Status of the Security Control for the information system.
46 47 48 |
# File 'lib/emass_client/models/controls_get.rb', line 46 def implementation_status @implementation_status end |
#included_status ⇒ Object
- Read-only
-
Indicates the manner by which a control was included in the system’s categorization.
37 38 39 |
# File 'lib/emass_client/models/controls_get.rb', line 37 def included_status @included_status end |
#is_inherited ⇒ Object
- Read-only
-
Indicates whether a control is inherited.
31 32 33 |
# File 'lib/emass_client/models/controls_get.rb', line 31 def is_inherited @is_inherited end |
#likelihood ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High)
94 95 96 |
# File 'lib/emass_client/models/controls_get.rb', line 94 def likelihood @likelihood end |
#modified_by_overlays ⇒ Object
- Read-only
-
List of overlays that affect the control.
34 35 36 |
# File 'lib/emass_client/models/controls_get.rb', line 34 def @modified_by_overlays end |
#na_justification ⇒ Object
- Conditional
-
Provide justification for Security Controls deemed Not Applicable to the system.
52 53 54 |
# File 'lib/emass_client/models/controls_get.rb', line 52 def na_justification @na_justification end |
#name ⇒ Object
- Read-only
-
Name of the system record.
22 23 24 |
# File 'lib/emass_client/models/controls_get.rb', line 22 def name @name end |
#recommendations ⇒ Object
- Optional
-
Include recommendations. Character Limit = 2,000.
88 89 90 |
# File 'lib/emass_client/models/controls_get.rb', line 88 def recommendations @recommendations end |
#relevance_of_threat ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High)
91 92 93 |
# File 'lib/emass_client/models/controls_get.rb', line 91 def relevance_of_threat @relevance_of_threat end |
#residual_risk_level ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High)
103 104 105 |
# File 'lib/emass_client/models/controls_get.rb', line 103 def residual_risk_level @residual_risk_level end |
#responsible_entities ⇒ Object
- Required
-
Include written description of Responsible Entities that are responsible for the Security Control. Character Limit = 2,000.
43 44 45 |
# File 'lib/emass_client/models/controls_get.rb', line 43 def responsible_entities @responsible_entities end |
#severity ⇒ Object
- Optional
-
Values include the following options (Very Low, Low, Moderate,High,Very High)
82 83 84 |
# File 'lib/emass_client/models/controls_get.rb', line 82 def severity @severity end |
#slcm_comments ⇒ Object
- Conditional
-
Additional comments for Security Control regarding SLCM. Character Limit = 4,000.
79 80 81 |
# File 'lib/emass_client/models/controls_get.rb', line 79 def slcm_comments @slcm_comments end |
#slcm_criticality ⇒ Object
- Conditional
-
Criticality of Security Control regarding SLCM. Character Limit = 2,000.
64 65 66 |
# File 'lib/emass_client/models/controls_get.rb', line 64 def slcm_criticality @slcm_criticality end |
#slcm_frequency ⇒ Object
- Conditional
-
SLCM frequency
67 68 69 |
# File 'lib/emass_client/models/controls_get.rb', line 67 def slcm_frequency @slcm_frequency end |
#slcm_method ⇒ Object
- Conditional
-
SLCM method utilized
70 71 72 |
# File 'lib/emass_client/models/controls_get.rb', line 70 def slcm_method @slcm_method end |
#slcm_reporting ⇒ Object
- Conditional
-
Method for reporting Security Control for SLCM. Character Limit = 2,000.
73 74 75 |
# File 'lib/emass_client/models/controls_get.rb', line 73 def slcm_reporting @slcm_reporting end |
#slcm_tracking ⇒ Object
- Conditional
-
How Non-Compliant Security Controls will be tracked for SLCM. Character Limit = 2,000.
76 77 78 |
# File 'lib/emass_client/models/controls_get.rb', line 76 def slcm_tracking @slcm_tracking end |
#system_id ⇒ Object
- Required
-
Unique system record identifier.
19 20 21 |
# File 'lib/emass_client/models/controls_get.rb', line 19 def system_id @system_id end |
#test_method ⇒ Object
- Optional
-
Identifies the assessment method / combination that will determine if the security requirements are implemented correctly.
106 107 108 |
# File 'lib/emass_client/models/controls_get.rb', line 106 def test_method @test_method end |
#vulnerabilty_summary ⇒ Object
- Optional
-
Include vulnerability summary. Character Limit = 2,000.
85 86 87 |
# File 'lib/emass_client/models/controls_get.rb', line 85 def vulnerabilty_summary @vulnerabilty_summary end |
Class Method Details
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about
167 168 169 |
# File 'lib/emass_client/models/controls_get.rb', line 167 def self.acceptable_attributes attribute_map.values end |
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
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 |
# File 'lib/emass_client/models/controls_get.rb', line 131 def self.attribute_map { :'system_id' => :'systemId', :'name' => :'name', :'acronym' => :'acronym', :'ccis' => :'ccis', :'is_inherited' => :'isInherited', :'modified_by_overlays' => :'modifiedByOverlays', :'included_status' => :'includedStatus', :'compliance_status' => :'complianceStatus', :'responsible_entities' => :'responsibleEntities', :'implementation_status' => :'implementationStatus', :'common_control_provider' => :'commonControlProvider', :'na_justification' => :'naJustification', :'control_designation' => :'controlDesignation', :'estimated_completion_date' => :'estimatedCompletionDate', :'implementation_narrative' => :'implementationNarrative', :'slcm_criticality' => :'slcmCriticality', :'slcm_frequency' => :'slcmFrequency', :'slcm_method' => :'slcmMethod', :'slcm_reporting' => :'slcmReporting', :'slcm_tracking' => :'slcmTracking', :'slcm_comments' => :'slcmComments', :'severity' => :'severity', :'vulnerabilty_summary' => :'vulnerabiltySummary', :'recommendations' => :'recommendations', :'relevance_of_threat' => :'relevanceOfThreat', :'likelihood' => :'likelihood', :'impact' => :'impact', :'impact_description' => :'impactDescription', :'residual_risk_level' => :'residualRiskLevel', :'test_method' => :'testMethod' } end |
.build_from_hash(attributes) ⇒ Object
Builds the object from hash
582 583 584 |
# File 'lib/emass_client/models/controls_get.rb', line 582 def self.build_from_hash(attributes) new.build_from_hash(attributes) end |
.openapi_nullable ⇒ Object
List of attributes with nullable: true
208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 |
# File 'lib/emass_client/models/controls_get.rb', line 208 def self.openapi_nullable Set.new([ :'name', :'ccis', :'is_inherited', :'modified_by_overlays', :'included_status', :'compliance_status', :'implementation_status', :'common_control_provider', :'na_justification', :'slcm_criticality', :'slcm_frequency', :'slcm_method', :'slcm_reporting', :'slcm_tracking', :'slcm_comments', :'severity', :'vulnerabilty_summary', :'recommendations', :'relevance_of_threat', :'likelihood', :'impact', :'impact_description', :'residual_risk_level', :'test_method' ]) end |
.openapi_types ⇒ Object
Attribute type mapping.
172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 |
# File 'lib/emass_client/models/controls_get.rb', line 172 def self.openapi_types { :'system_id' => :'Integer', :'name' => :'String', :'acronym' => :'String', :'ccis' => :'String', :'is_inherited' => :'Boolean', :'modified_by_overlays' => :'String', :'included_status' => :'String', :'compliance_status' => :'String', :'responsible_entities' => :'String', :'implementation_status' => :'String', :'common_control_provider' => :'String', :'na_justification' => :'String', :'control_designation' => :'String', :'estimated_completion_date' => :'Integer', :'implementation_narrative' => :'String', :'slcm_criticality' => :'String', :'slcm_frequency' => :'String', :'slcm_method' => :'String', :'slcm_reporting' => :'String', :'slcm_tracking' => :'String', :'slcm_comments' => :'String', :'severity' => :'String', :'vulnerabilty_summary' => :'String', :'recommendations' => :'String', :'relevance_of_threat' => :'String', :'likelihood' => :'String', :'impact' => :'String', :'impact_description' => :'String', :'residual_risk_level' => :'String', :'test_method' => :'String' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 |
# File 'lib/emass_client/models/controls_get.rb', line 532 def ==(o) return true if self.equal?(o) self.class == o.class && system_id == o.system_id && name == o.name && acronym == o.acronym && ccis == o.ccis && is_inherited == o.is_inherited && == o. && included_status == o.included_status && compliance_status == o.compliance_status && responsible_entities == o.responsible_entities && implementation_status == o.implementation_status && common_control_provider == o.common_control_provider && na_justification == o.na_justification && control_designation == o.control_designation && estimated_completion_date == o.estimated_completion_date && implementation_narrative == o.implementation_narrative && slcm_criticality == o.slcm_criticality && slcm_frequency == o.slcm_frequency && slcm_method == o.slcm_method && slcm_reporting == o.slcm_reporting && slcm_tracking == o.slcm_tracking && slcm_comments == o.slcm_comments && severity == o.severity && vulnerabilty_summary == o.vulnerabilty_summary && recommendations == o.recommendations && relevance_of_threat == o.relevance_of_threat && likelihood == o.likelihood && impact == o.impact && impact_description == o.impact_description && residual_risk_level == o.residual_risk_level && test_method == o.test_method end |
#_deserialize(type, value) ⇒ Object
Deserializes the data based on type
613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 |
# File 'lib/emass_client/models/controls_get.rb', line 613 def _deserialize(type, value) case type.to_sym when :Time Time.parse(value) when :Date Date.parse(value) when :String value.to_s when :Integer value.to_i when :Float value.to_f when :Boolean if value.to_s =~ /\A(true|t|yes|y|1)\z/i true else false end when :Object # generic object (usually a Hash), return directly value when /\AArray<(?<inner_type>.+)>\z/ inner_type = Regexp.last_match[:inner_type] value.map { |v| _deserialize(inner_type, v) } when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/ k_type = Regexp.last_match[:k_type] v_type = Regexp.last_match[:v_type] {}.tap do |hash| value.each do |k, v| hash[_deserialize(k_type, k)] = _deserialize(v_type, v) end end else # model # models (e.g. Pet) or oneOf klass = EmassClient.const_get(type) klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end |
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value
684 685 686 687 688 689 690 691 692 693 694 695 696 |
# File 'lib/emass_client/models/controls_get.rb', line 684 def _to_hash(value) if value.is_a?(Array) value.compact.map { |v| _to_hash(v) } elsif value.is_a?(Hash) {}.tap do |hash| value.each { |k, v| hash[k] = _to_hash(v) } end elsif value.respond_to? :to_hash value.to_hash else value end end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 |
# File 'lib/emass_client/models/controls_get.rb', line 589 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) attributes = attributes.transform_keys(&:to_sym) self.class.openapi_types.each_pair do |key, type| if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key) self.send("#{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[self.class.attribute_map[key]].is_a?(Array) self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) }) end elsif !attributes[self.class.attribute_map[key]].nil? self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]])) end end self end |
#eql?(o) ⇒ Boolean
569 570 571 |
# File 'lib/emass_client/models/controls_get.rb', line 569 def eql?(o) self == o end |
#hash ⇒ Integer
Calculates hash code according to all attributes.
575 576 577 |
# File 'lib/emass_client/models/controls_get.rb', line 575 def hash [system_id, name, acronym, ccis, is_inherited, , included_status, compliance_status, responsible_entities, implementation_status, common_control_provider, na_justification, control_designation, estimated_completion_date, implementation_narrative, slcm_criticality, slcm_frequency, slcm_method, slcm_reporting, slcm_tracking, slcm_comments, severity, vulnerabilty_summary, recommendations, relevance_of_threat, likelihood, impact, impact_description, residual_risk_level, test_method].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
375 376 377 378 |
# File 'lib/emass_client/models/controls_get.rb', line 375 def list_invalid_properties invalid_properties = Array.new invalid_properties end |
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility)
660 661 662 |
# File 'lib/emass_client/models/controls_get.rb', line 660 def to_body to_hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
666 667 668 669 670 671 672 673 674 675 676 677 678 |
# File 'lib/emass_client/models/controls_get.rb', line 666 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 |
#to_s ⇒ String
Returns the string representation of the object
654 655 656 |
# File 'lib/emass_client/models/controls_get.rb', line 654 def to_s to_hash.to_s end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 |
# File 'lib/emass_client/models/controls_get.rb', line 382 def valid? = EnumAttributeValidator.new('String', ["Privacy", "Requirements", "Concurrency", "unknown_default_open_api"]) return false unless .valid?(@modified_by_overlays) implementation_status_validator = EnumAttributeValidator.new('String', ["Planned", "Implemented", "Inherited", "Not Applicable", "Manually Inherited", "unknown_default_open_api"]) return false unless implementation_status_validator.valid?(@implementation_status) common_control_provider_validator = EnumAttributeValidator.new('String', ["DoD", "Component", "Enclave", "unknown_default_open_api"]) return false unless common_control_provider_validator.valid?(@common_control_provider) control_designation_validator = EnumAttributeValidator.new('String', ["Common", "System-Specific", "Hybrid", "unknown_default_open_api"]) return false unless control_designation_validator.valid?(@control_designation) slcm_frequency_validator = EnumAttributeValidator.new('String', ["Constantly", "Daily", "Weekly", "Monthly", "Quarterly", "Semi-Annually", "Annually", "Every Two Years", "Every Three Years", "Undetermined", "unknown_default_open_api"]) return false unless slcm_frequency_validator.valid?(@slcm_frequency) slcm_method_validator = EnumAttributeValidator.new('String', ["Automated", "Semi-Automated", "Manual", "Undetermined", "unknown_default_open_api"]) return false unless slcm_method_validator.valid?(@slcm_method) severity_validator = EnumAttributeValidator.new('String', ["Very Low", "Low", "Moderate", "High", "Very High", "unknown_default_open_api"]) return false unless severity_validator.valid?(@severity) relevance_of_threat_validator = EnumAttributeValidator.new('String', ["Very Low", "Low", "Moderate", "High", "Very High", "unknown_default_open_api"]) return false unless relevance_of_threat_validator.valid?(@relevance_of_threat) likelihood_validator = EnumAttributeValidator.new('String', ["Very Low", "Low", "Moderate", "High", "Very High", "unknown_default_open_api"]) return false unless likelihood_validator.valid?(@likelihood) impact_validator = EnumAttributeValidator.new('String', ["Very Low", "Low", "Moderate", "High", "Very High", "unknown_default_open_api"]) return false unless impact_validator.valid?(@impact) residual_risk_level_validator = EnumAttributeValidator.new('String', ["Very Low", "Low", "Moderate", "High", "Very High", "unknown_default_open_api"]) return false unless residual_risk_level_validator.valid?(@residual_risk_level) test_method_validator = EnumAttributeValidator.new('String', ["Test", "Interview", "Examine", "Test, Interview", "Test, Examine", "Interview, Examine", "Test, Interview, Examine", "unknown_default_open_api"]) return false unless test_method_validator.valid?(@test_method) true end |