Class: OCI::ManagementDashboard::Models::ManagementDashboardTileDetails
- Inherits:
-
Object
- Object
- OCI::ManagementDashboard::Models::ManagementDashboardTileDetails
- Defined in:
- lib/oci/management_dashboard/models/management_dashboard_tile_details.rb
Overview
Properties of the dashboard tile representing a saved search. Tiles are laid out in a twelve column grid system with (0,0) at upper left corner.
Constant Summary collapse
- STATE_ENUM =
[ STATE_DELETED = 'DELETED'.freeze, STATE_UNAUTHORIZED = 'UNAUTHORIZED'.freeze, STATE_DEFAULT = 'DEFAULT'.freeze, STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#column ⇒ Integer
[Required] Tile's column number.
-
#data_config ⇒ Array<Object>
[Required] It defines how data is fetched.
-
#description ⇒ String
Description of the tile.
-
#display_name ⇒ String
[Required] Display name of the saved search.
-
#drilldown_config ⇒ Object
[Required] Drill-down configuration to define the destination of a drill-down action.
-
#height ⇒ Integer
[Required] The number of rows the tile occupies.
-
#nls ⇒ Object
[Required] JSON that contains internationalization options.
-
#parameters_map ⇒ Object
Specifies the saved search parameters values.
-
#row ⇒ Integer
[Required] Tile's row number.
-
#saved_search_id ⇒ String
[Required] ID of the saved search.
-
#state ⇒ String
[Required] Current state of the saved search.
-
#ui_config ⇒ Object
[Required] It defines the visualization type of the widget saved search, the UI options of that visualization type, the binding of data to the visualization.
-
#width ⇒ Integer
[Required] The number of columns the tile occupies.
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 = {}) ⇒ ManagementDashboardTileDetails
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 = {}) ⇒ ManagementDashboardTileDetails
Initializes the object
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 186 187 188 189 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 134 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.display_name = attributes[:'displayName'] if attributes[:'displayName'] raise 'You cannot provide both :displayName and :display_name' if attributes.key?(:'displayName') && attributes.key?(:'display_name') self.display_name = attributes[:'display_name'] if attributes[:'display_name'] self.saved_search_id = attributes[:'savedSearchId'] if attributes[:'savedSearchId'] raise 'You cannot provide both :savedSearchId and :saved_search_id' if attributes.key?(:'savedSearchId') && attributes.key?(:'saved_search_id') self.saved_search_id = attributes[:'saved_search_id'] if attributes[:'saved_search_id'] self.row = attributes[:'row'] if attributes[:'row'] self.column = attributes[:'column'] if attributes[:'column'] self.height = attributes[:'height'] if attributes[:'height'] self.width = attributes[:'width'] if attributes[:'width'] self.nls = attributes[:'nls'] if attributes[:'nls'] self.ui_config = attributes[:'uiConfig'] if attributes[:'uiConfig'] raise 'You cannot provide both :uiConfig and :ui_config' if attributes.key?(:'uiConfig') && attributes.key?(:'ui_config') self.ui_config = attributes[:'ui_config'] if attributes[:'ui_config'] self.data_config = attributes[:'dataConfig'] if attributes[:'dataConfig'] raise 'You cannot provide both :dataConfig and :data_config' if attributes.key?(:'dataConfig') && attributes.key?(:'data_config') self.data_config = attributes[:'data_config'] if attributes[:'data_config'] self.state = attributes[:'state'] if attributes[:'state'] self.drilldown_config = attributes[:'drilldownConfig'] if attributes[:'drilldownConfig'] raise 'You cannot provide both :drilldownConfig and :drilldown_config' if attributes.key?(:'drilldownConfig') && attributes.key?(:'drilldown_config') self.drilldown_config = attributes[:'drilldown_config'] if attributes[:'drilldown_config'] self.parameters_map = attributes[:'parametersMap'] if attributes[:'parametersMap'] raise 'You cannot provide both :parametersMap and :parameters_map' if attributes.key?(:'parametersMap') && attributes.key?(:'parameters_map') self.parameters_map = attributes[:'parameters_map'] if attributes[:'parameters_map'] self.description = attributes[:'description'] if attributes[:'description'] end |
Instance Attribute Details
#column ⇒ Integer
[Required] Tile's column number.
35 36 37 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 35 def column @column end |
#data_config ⇒ Array<Object>
[Required] It defines how data is fetched. A functional saved search needs a valid dataConfig. See examples on how it can be constructed for various data sources.
55 56 57 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 55 def data_config @data_config end |
#description ⇒ String
Description of the tile.
71 72 73 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 71 def description @description end |
#display_name ⇒ String
[Required] Display name of the saved search.
23 24 25 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 23 def display_name @display_name end |
#drilldown_config ⇒ Object
[Required] Drill-down configuration to define the destination of a drill-down action.
63 64 65 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 63 def drilldown_config @drilldown_config end |
#height ⇒ Integer
[Required] The number of rows the tile occupies.
39 40 41 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 39 def height @height end |
#nls ⇒ Object
[Required] JSON that contains internationalization options.
47 48 49 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 47 def nls @nls end |
#parameters_map ⇒ Object
Specifies the saved search parameters values
67 68 69 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 67 def parameters_map @parameters_map end |
#row ⇒ Integer
[Required] Tile's row number.
31 32 33 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 31 def row @row end |
#saved_search_id ⇒ String
[Required] ID of the saved search.
27 28 29 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 27 def saved_search_id @saved_search_id end |
#state ⇒ String
[Required] Current state of the saved search.
59 60 61 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 59 def state @state end |
#ui_config ⇒ Object
[Required] It defines the visualization type of the widget saved search, the UI options of that visualization type, the binding of data to the visualization.
51 52 53 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 51 def ui_config @ui_config end |
#width ⇒ Integer
[Required] The number of columns the tile occupies.
43 44 45 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 43 def width @width end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 74 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'display_name': :'displayName', 'saved_search_id': :'savedSearchId', 'row': :'row', 'column': :'column', 'height': :'height', 'width': :'width', 'nls': :'nls', 'ui_config': :'uiConfig', 'data_config': :'dataConfig', 'state': :'state', 'drilldown_config': :'drilldownConfig', 'parameters_map': :'parametersMap', 'description': :'description' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 95 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'display_name': :'String', 'saved_search_id': :'String', 'row': :'Integer', 'column': :'Integer', 'height': :'Integer', 'width': :'Integer', 'nls': :'Object', 'ui_config': :'Object', 'data_config': :'Array<Object>', 'state': :'String', 'drilldown_config': :'Object', 'parameters_map': :'Object', 'description': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 211 def ==(other) return true if equal?(other) self.class == other.class && display_name == other.display_name && saved_search_id == other.saved_search_id && row == other.row && column == other.column && height == other.height && width == other.width && nls == other.nls && ui_config == other.ui_config && data_config == other.data_config && state == other.state && drilldown_config == other.drilldown_config && parameters_map == other.parameters_map && description == other.description end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 253 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
233 234 235 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 233 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
242 243 244 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 242 def hash [display_name, saved_search_id, row, column, height, width, nls, ui_config, data_config, state, drilldown_config, parameters_map, description].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
286 287 288 289 290 291 292 293 294 295 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 286 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
280 281 282 |
# File 'lib/oci/management_dashboard/models/management_dashboard_tile_details.rb', line 280 def to_s to_hash.to_s end |