Class: OCI::FleetAppsManagement::Models::SchemaDocument
- Inherits:
-
Object
- Object
- OCI::FleetAppsManagement::Models::SchemaDocument
- Defined in:
- lib/oci/fleet_apps_management/models/schema_document.rb
Overview
Schema Document representing Schema.yaml (/iaas/Content/ResourceManager/Concepts/terraformconfigresourcemanager_topic-schema.htm)
Constant Summary collapse
- SCHEMA_VERSION_ENUM =
[ SCHEMA_VERSION_V_1_0_0 = 'V_1_0_0'.freeze, SCHEMA_VERSION_V_1_1_0 = 'V_1_1_0'.freeze, SCHEMA_VERSION_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- LOCALE_ENUM =
[ LOCALE_EN = 'EN'.freeze, LOCALE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#can_allow_view_state ⇒ BOOLEAN
Indicates if the stack allows users to view state information.
-
#description ⇒ String
A detailed description of the stack or schema.
- #groupings ⇒ OCI::FleetAppsManagement::Models::VariableGroups
-
#informational_text ⇒ String
Informational text or notes relevant to the stack or its use.
-
#instructions ⇒ String
Setup or usage instructions for this stack.
-
#locale ⇒ String
The locale/language for the schema user interface (default is EN).
-
#logo_url ⇒ String
logo url.
-
#output_groups ⇒ Array<OCI::FleetAppsManagement::Models::OutputGroup>
Array of output group objects to group outputs for display or logical purposes.
-
#outputs ⇒ Hash<String, OCI::FleetAppsManagement::Models::BaseOutput>
A mapping of output variable names to their definitions.
-
#package_version ⇒ String
The version of the package associated with this schema.
-
#primary_output_button ⇒ String
primary output button value.
-
#schema_version ⇒ String
[Required] The version of the schema definition format in use for this document.
- #source ⇒ OCI::FleetAppsManagement::Models::StackSource
-
#stack_description ⇒ String
Additional details describing the stack's purpose or use-case.
-
#title ⇒ String
The display name or title for this schema document.
-
#troubleshooting ⇒ String
Troubleshooting tips, guidance, or steps for stack usage.
-
#variable_groups ⇒ Array<OCI::FleetAppsManagement::Models::VariableGroup>
An array of variable group definitions for organizing variables together.
-
#variables ⇒ Hash<String, OCI::FleetAppsManagement::Models::BaseVariable>
[Required] Key-value map of input variables defined for use by the stack.
-
#version ⇒ String
The version identifier for this schema document.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(other) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ SchemaDocument
constructor
Initializes the object.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
Constructor Details
#initialize(attributes = {}) ⇒ SchemaDocument
Initializes the object
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 206 207 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 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 176 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } self.title = attributes[:'title'] if attributes[:'title'] self.description = attributes[:'description'] if attributes[:'description'] self.stack_description = attributes[:'stackDescription'] if attributes[:'stackDescription'] raise 'You cannot provide both :stackDescription and :stack_description' if attributes.key?(:'stackDescription') && attributes.key?(:'stack_description') self.stack_description = attributes[:'stack_description'] if attributes[:'stack_description'] self.package_version = attributes[:'packageVersion'] if attributes[:'packageVersion'] raise 'You cannot provide both :packageVersion and :package_version' if attributes.key?(:'packageVersion') && attributes.key?(:'package_version') self.package_version = attributes[:'package_version'] if attributes[:'package_version'] self.version = attributes[:'version'] if attributes[:'version'] self.schema_version = attributes[:'schemaVersion'] if attributes[:'schemaVersion'] raise 'You cannot provide both :schemaVersion and :schema_version' if attributes.key?(:'schemaVersion') && attributes.key?(:'schema_version') self.schema_version = attributes[:'schema_version'] if attributes[:'schema_version'] self.locale = attributes[:'locale'] if attributes[:'locale'] self.locale = "EN" if locale.nil? && !attributes.key?(:'locale') # rubocop:disable Style/StringLiterals self.logo_url = attributes[:'logoUrl'] if attributes[:'logoUrl'] raise 'You cannot provide both :logoUrl and :logo_url' if attributes.key?(:'logoUrl') && attributes.key?(:'logo_url') self.logo_url = attributes[:'logo_url'] if attributes[:'logo_url'] self.source = attributes[:'source'] if attributes[:'source'] self.informational_text = attributes[:'informationalText'] if attributes[:'informationalText'] raise 'You cannot provide both :informationalText and :informational_text' if attributes.key?(:'informationalText') && attributes.key?(:'informational_text') self.informational_text = attributes[:'informational_text'] if attributes[:'informational_text'] self.instructions = attributes[:'instructions'] if attributes[:'instructions'] self.troubleshooting = attributes[:'troubleshooting'] if attributes[:'troubleshooting'] self.can_allow_view_state = attributes[:'canAllowViewState'] unless attributes[:'canAllowViewState'].nil? raise 'You cannot provide both :canAllowViewState and :can_allow_view_state' if attributes.key?(:'canAllowViewState') && attributes.key?(:'can_allow_view_state') self.can_allow_view_state = attributes[:'can_allow_view_state'] unless attributes[:'can_allow_view_state'].nil? self.variables = attributes[:'variables'] if attributes[:'variables'] self.groupings = attributes[:'groupings'] if attributes[:'groupings'] self.variable_groups = attributes[:'variableGroups'] if attributes[:'variableGroups'] raise 'You cannot provide both :variableGroups and :variable_groups' if attributes.key?(:'variableGroups') && attributes.key?(:'variable_groups') self.variable_groups = attributes[:'variable_groups'] if attributes[:'variable_groups'] self.outputs = attributes[:'outputs'] if attributes[:'outputs'] self.output_groups = attributes[:'outputGroups'] if attributes[:'outputGroups'] raise 'You cannot provide both :outputGroups and :output_groups' if attributes.key?(:'outputGroups') && attributes.key?(:'output_groups') self.output_groups = attributes[:'output_groups'] if attributes[:'output_groups'] self. = attributes[:'primaryOutputButton'] if attributes[:'primaryOutputButton'] raise 'You cannot provide both :primaryOutputButton and :primary_output_button' if attributes.key?(:'primaryOutputButton') && attributes.key?(:'primary_output_button') self. = attributes[:'primary_output_button'] if attributes[:'primary_output_button'] end |
Instance Attribute Details
#can_allow_view_state ⇒ BOOLEAN
Indicates if the stack allows users to view state information.
72 73 74 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 72 def can_allow_view_state @can_allow_view_state end |
#description ⇒ String
A detailed description of the stack or schema.
29 30 31 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 29 def description @description end |
#groupings ⇒ OCI::FleetAppsManagement::Models::VariableGroups
79 80 81 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 79 def groupings @groupings end |
#informational_text ⇒ String
Informational text or notes relevant to the stack or its use.
60 61 62 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 60 def informational_text @informational_text end |
#instructions ⇒ String
Setup or usage instructions for this stack.
64 65 66 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 64 def instructions @instructions end |
#locale ⇒ String
The locale/language for the schema user interface (default is EN).
49 50 51 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 49 def locale @locale end |
#logo_url ⇒ String
logo url.
53 54 55 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 53 def logo_url @logo_url end |
#output_groups ⇒ Array<OCI::FleetAppsManagement::Models::OutputGroup>
Array of output group objects to group outputs for display or logical purposes.
91 92 93 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 91 def output_groups @output_groups end |
#outputs ⇒ Hash<String, OCI::FleetAppsManagement::Models::BaseOutput>
A mapping of output variable names to their definitions.
87 88 89 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 87 def outputs @outputs end |
#package_version ⇒ String
The version of the package associated with this schema.
37 38 39 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 37 def package_version @package_version end |
#primary_output_button ⇒ String
primary output button value.
95 96 97 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 95 def @primary_output_button end |
#schema_version ⇒ String
[Required] The version of the schema definition format in use for this document.
45 46 47 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 45 def schema_version @schema_version end |
#source ⇒ OCI::FleetAppsManagement::Models::StackSource
56 57 58 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 56 def source @source end |
#stack_description ⇒ String
Additional details describing the stack's purpose or use-case.
33 34 35 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 33 def stack_description @stack_description end |
#title ⇒ String
The display name or title for this schema document.
25 26 27 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 25 def title @title end |
#troubleshooting ⇒ String
Troubleshooting tips, guidance, or steps for stack usage.
68 69 70 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 68 def troubleshooting @troubleshooting end |
#variable_groups ⇒ Array<OCI::FleetAppsManagement::Models::VariableGroup>
An array of variable group definitions for organizing variables together.
83 84 85 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 83 def variable_groups @variable_groups end |
#variables ⇒ Hash<String, OCI::FleetAppsManagement::Models::BaseVariable>
[Required] Key-value map of input variables defined for use by the stack.
76 77 78 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 76 def variables @variables end |
#version ⇒ String
The version identifier for this schema document.
41 42 43 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 41 def version @version end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 98 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'title': :'title', 'description': :'description', 'stack_description': :'stackDescription', 'package_version': :'packageVersion', 'version': :'version', 'schema_version': :'schemaVersion', 'locale': :'locale', 'logo_url': :'logoUrl', 'source': :'source', 'informational_text': :'informationalText', 'instructions': :'instructions', 'troubleshooting': :'troubleshooting', 'can_allow_view_state': :'canAllowViewState', 'variables': :'variables', 'groupings': :'groupings', 'variable_groups': :'variableGroups', 'outputs': :'outputs', 'output_groups': :'outputGroups', 'primary_output_button': :'primaryOutputButton' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
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 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 125 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'title': :'String', 'description': :'String', 'stack_description': :'String', 'package_version': :'String', 'version': :'String', 'schema_version': :'String', 'locale': :'String', 'logo_url': :'String', 'source': :'OCI::FleetAppsManagement::Models::StackSource', 'informational_text': :'String', 'instructions': :'String', 'troubleshooting': :'String', 'can_allow_view_state': :'BOOLEAN', 'variables': :'Hash<String, OCI::FleetAppsManagement::Models::BaseVariable>', 'groupings': :'OCI::FleetAppsManagement::Models::VariableGroups', 'variable_groups': :'Array<OCI::FleetAppsManagement::Models::VariableGroup>', 'outputs': :'Hash<String, OCI::FleetAppsManagement::Models::BaseOutput>', 'output_groups': :'Array<OCI::FleetAppsManagement::Models::OutputGroup>', 'primary_output_button': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 291 def ==(other) return true if equal?(other) self.class == other.class && title == other.title && description == other.description && stack_description == other.stack_description && package_version == other.package_version && version == other.version && schema_version == other.schema_version && locale == other.locale && logo_url == other.logo_url && source == other.source && informational_text == other.informational_text && instructions == other.instructions && troubleshooting == other.troubleshooting && can_allow_view_state == other.can_allow_view_state && variables == other.variables && groupings == other.groupings && variable_groups == other.variable_groups && outputs == other.outputs && output_groups == other.output_groups && == other. 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 358 359 360 361 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 339 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /^Array<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) public_method("#{key}=").call( attributes[self.class.attribute_map[key]] .map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? public_method("#{key}=").call( OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]) ) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(other) ⇒ Boolean
319 320 321 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 319 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
328 329 330 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 328 def hash [title, description, stack_description, package_version, version, schema_version, locale, logo_url, source, informational_text, instructions, troubleshooting, can_allow_view_state, variables, groupings, variable_groups, outputs, output_groups, ].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
372 373 374 375 376 377 378 379 380 381 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 372 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = public_method(attr).call next if value.nil? && !instance_variable_defined?("@#{attr}") hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
366 367 368 |
# File 'lib/oci/fleet_apps_management/models/schema_document.rb', line 366 def to_s to_hash.to_s end |