Class: OCI::DatabaseToolsRuntime::Models::PropertySetApexDocumentGenerator

Inherits:
PropertySet
  • Object
show all
Defined in:
lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb

Overview

Contains the details of an APEX Document Generator property set

Constant Summary collapse

[
  PRINT_SERVER_TYPE_DOCUMENT_GENERATOR = 'DOCUMENT_GENERATOR'.freeze,
  PRINT_SERVER_TYPE_NONE = 'NONE'.freeze,
  PRINT_SERVER_TYPE_STANDARD = 'STANDARD'.freeze,
  PRINT_SERVER_TYPE_ADVANCED = 'ADVANCED'.freeze,
  PRINT_SERVER_TYPE_AOP = 'AOP'.freeze,
  PRINT_SERVER_TYPE_OTHER = 'OTHER'.freeze,
  PRINT_SERVER_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze
AUTONOMOUS_DATABASE_RESOURCE_PRINCIPAL_STATUS_ENUM =
[
  AUTONOMOUS_DATABASE_RESOURCE_PRINCIPAL_STATUS_ENABLED = 'ENABLED'.freeze,
  AUTONOMOUS_DATABASE_RESOURCE_PRINCIPAL_STATUS_DISABLED = 'DISABLED'.freeze,
  AUTONOMOUS_DATABASE_RESOURCE_PRINCIPAL_STATUS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze

Constants inherited from PropertySet

OCI::DatabaseToolsRuntime::Models::PropertySet::KEY_ENUM

Instance Attribute Summary collapse

Attributes inherited from PropertySet

#is_mutable, #key

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from PropertySet

get_subtype

Constructor Details

#initialize(attributes = {}) ⇒ PropertySetApexDocumentGenerator

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash

Options Hash (attributes):



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
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 112

def initialize(attributes = {})
  return unless attributes.is_a?(Hash)

  attributes['key'] = 'APEX_DOCUMENT_GENERATOR'

  super(attributes)

  # convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

  self.print_server_type = attributes[:'printServerType'] if attributes[:'printServerType']

  raise 'You cannot provide both :printServerType and :print_server_type' if attributes.key?(:'printServerType') && attributes.key?(:'print_server_type')

  self.print_server_type = attributes[:'print_server_type'] if attributes[:'print_server_type']

  self.credential_key = attributes[:'credentialKey'] if attributes[:'credentialKey']

  raise 'You cannot provide both :credentialKey and :credential_key' if attributes.key?(:'credentialKey') && attributes.key?(:'credential_key')

  self.credential_key = attributes[:'credential_key'] if attributes[:'credential_key']

  self.autonomous_database_resource_principal_status = attributes[:'autonomousDatabaseResourcePrincipalStatus'] if attributes[:'autonomousDatabaseResourcePrincipalStatus']

  raise 'You cannot provide both :autonomousDatabaseResourcePrincipalStatus and :autonomous_database_resource_principal_status' if attributes.key?(:'autonomousDatabaseResourcePrincipalStatus') && attributes.key?(:'autonomous_database_resource_principal_status')

  self.autonomous_database_resource_principal_status = attributes[:'autonomous_database_resource_principal_status'] if attributes[:'autonomous_database_resource_principal_status']

  self.object_storage_namespace = attributes[:'objectStorageNamespace'] if attributes[:'objectStorageNamespace']

  raise 'You cannot provide both :objectStorageNamespace and :object_storage_namespace' if attributes.key?(:'objectStorageNamespace') && attributes.key?(:'object_storage_namespace')

  self.object_storage_namespace = attributes[:'object_storage_namespace'] if attributes[:'object_storage_namespace']

  self.object_storage_bucket_compartment_id = attributes[:'objectStorageBucketCompartmentId'] if attributes[:'objectStorageBucketCompartmentId']

  raise 'You cannot provide both :objectStorageBucketCompartmentId and :object_storage_bucket_compartment_id' if attributes.key?(:'objectStorageBucketCompartmentId') && attributes.key?(:'object_storage_bucket_compartment_id')

  self.object_storage_bucket_compartment_id = attributes[:'object_storage_bucket_compartment_id'] if attributes[:'object_storage_bucket_compartment_id']

  self.object_storage_endpoint = attributes[:'objectStorageEndpoint'] if attributes[:'objectStorageEndpoint']

  raise 'You cannot provide both :objectStorageEndpoint and :object_storage_endpoint' if attributes.key?(:'objectStorageEndpoint') && attributes.key?(:'object_storage_endpoint')

  self.object_storage_endpoint = attributes[:'object_storage_endpoint'] if attributes[:'object_storage_endpoint']

  self.function_id = attributes[:'functionId'] if attributes[:'functionId']

  raise 'You cannot provide both :functionId and :function_id' if attributes.key?(:'functionId') && attributes.key?(:'function_id')

  self.function_id = attributes[:'function_id'] if attributes[:'function_id']

  self.invoke_endpoint = attributes[:'invokeEndpoint'] if attributes[:'invokeEndpoint']

  raise 'You cannot provide both :invokeEndpoint and :invoke_endpoint' if attributes.key?(:'invokeEndpoint') && attributes.key?(:'invoke_endpoint')

  self.invoke_endpoint = attributes[:'invoke_endpoint'] if attributes[:'invoke_endpoint']
end

Instance Attribute Details

#autonomous_database_resource_principal_statusString

The status of the Autonomous Database Serverless Resource Principal (OCI$RESOURCE_PRINCIPAL)

Returns:

  • (String)


39
40
41
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 39

def autonomous_database_resource_principal_status
  @autonomous_database_resource_principal_status
end

#credential_keyString

The name of the credential used by APEX to manage Object Storage Buckets and Objects as well as invoke the Document Generator function

Returns:

  • (String)


35
36
37
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 35

def credential_key
  @credential_key
end

#function_idString

The OCID of the Document Generator function

Returns:

  • (String)


55
56
57
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 55

def function_id
  @function_id
end

#invoke_endpointString

The base endpoint URL to use to invoke the Document Generator function

Returns:

  • (String)


59
60
61
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 59

def invoke_endpoint
  @invoke_endpoint
end

#object_storage_bucket_compartment_idString

The OCID of the compartment containing the Object Storage Buckets managed by APEX

Returns:

  • (String)


47
48
49
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 47

def object_storage_bucket_compartment_id
  @object_storage_bucket_compartment_id
end

#object_storage_endpointString

Object Storage Endpoint

Returns:

  • (String)


51
52
53
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 51

def object_storage_endpoint
  @object_storage_endpoint
end

#object_storage_namespaceString

The Object Storage Namespace containing the Object Storage Buckets managed by APEX

Returns:

  • (String)


43
44
45
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 43

def object_storage_namespace
  @object_storage_namespace
end

The print server type

Returns:

  • (String)


31
32
33
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 31

def print_server_type
  @print_server_type
end

Class Method Details

.attribute_mapObject

Attribute mapping from ruby-style variable name to JSON key.



62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 62

def self.attribute_map
  {
    # rubocop:disable Style/SymbolLiteral
    'key': :'key',
    'is_mutable': :'isMutable',
    'print_server_type': :'printServerType',
    'credential_key': :'credentialKey',
    'autonomous_database_resource_principal_status': :'autonomousDatabaseResourcePrincipalStatus',
    'object_storage_namespace': :'objectStorageNamespace',
    'object_storage_bucket_compartment_id': :'objectStorageBucketCompartmentId',
    'object_storage_endpoint': :'objectStorageEndpoint',
    'function_id': :'functionId',
    'invoke_endpoint': :'invokeEndpoint'
    # rubocop:enable Style/SymbolLiteral
  }
end

.swagger_typesObject

Attribute type mapping.



80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 80

def self.swagger_types
  {
    # rubocop:disable Style/SymbolLiteral
    'key': :'String',
    'is_mutable': :'BOOLEAN',
    'print_server_type': :'String',
    'credential_key': :'String',
    'autonomous_database_resource_principal_status': :'String',
    'object_storage_namespace': :'String',
    'object_storage_bucket_compartment_id': :'String',
    'object_storage_endpoint': :'String',
    'function_id': :'String',
    'invoke_endpoint': :'String'
    # rubocop:enable Style/SymbolLiteral
  }
end

Instance Method Details

#==(other) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • other (Object)

    the other object to be compared



204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 204

def ==(other)
  return true if equal?(other)

  self.class == other.class &&
    key == other.key &&
    is_mutable == other.is_mutable &&
    print_server_type == other.print_server_type &&
    credential_key == other.credential_key &&
    autonomous_database_resource_principal_status == other.autonomous_database_resource_principal_status &&
    object_storage_namespace == other.object_storage_namespace &&
    object_storage_bucket_compartment_id == other.object_storage_bucket_compartment_id &&
    object_storage_endpoint == other.object_storage_endpoint &&
    function_id == other.function_id &&
    invoke_endpoint == other.invoke_endpoint
end

#build_from_hash(attributes) ⇒ Object

Builds the object from hash

Parameters:

  • attributes (Hash)

    Model attributes in the form of hash

Returns:

  • (Object)

    Returns the model itself



243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 243

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

Parameters:

  • other (Object)

    the other object to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


223
224
225
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 223

def eql?(other)
  self == other
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



232
233
234
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 232

def hash
  [key, is_mutable, print_server_type, credential_key, autonomous_database_resource_principal_status, object_storage_namespace, object_storage_bucket_compartment_id, object_storage_endpoint, function_id, invoke_endpoint].hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



276
277
278
279
280
281
282
283
284
285
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 276

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_sString

Returns the string representation of the object

Returns:

  • (String)

    String presentation of the object



270
271
272
# File 'lib/oci/database_tools_runtime/models/property_set_apex_document_generator.rb', line 270

def to_s
  to_hash.to_s
end