Class: SDM::BigQuery

Inherits:
Object
  • Object
show all
Defined in:
lib/models/porcelain.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(egress_filter: nil, endpoint: nil, healthy: nil, id: nil, name: nil, port_override: nil, private_key: nil, project: nil, secret_store_id: nil, tags: nil, username: nil) ⇒ BigQuery

Returns a new instance of BigQuery.



1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
# File 'lib/models/porcelain.rb', line 1433

def initialize(
  egress_filter: nil,
  endpoint: nil,
  healthy: nil,
  id: nil,
  name: nil,
  port_override: nil,
  private_key: nil,
  project: nil,
  secret_store_id: nil,
  tags: nil,
  username: nil
)
  @egress_filter = egress_filter == nil ? "" : egress_filter
  @endpoint = endpoint == nil ? "" : endpoint
  @healthy = healthy == nil ? false : healthy
  @id = id == nil ? "" : id
  @name = name == nil ? "" : name
  @port_override = port_override == nil ? 0 : port_override
  @private_key = private_key == nil ? "" : private_key
  @project = project == nil ? "" : project
  @secret_store_id = secret_store_id == nil ? "" : secret_store_id
  @tags = tags == nil ? SDM::_porcelain_zero_value_tags() : tags
  @username = username == nil ? "" : username
end

Instance Attribute Details

#egress_filterObject

A filter applied to the routing logic to pin datasource to nodes.



1411
1412
1413
# File 'lib/models/porcelain.rb', line 1411

def egress_filter
  @egress_filter
end

#endpointObject

Returns the value of attribute endpoint.



1413
1414
1415
# File 'lib/models/porcelain.rb', line 1413

def endpoint
  @endpoint
end

#healthyObject

True if the datasource is reachable and the credentials are valid.



1415
1416
1417
# File 'lib/models/porcelain.rb', line 1415

def healthy
  @healthy
end

#idObject

Unique identifier of the Resource.



1417
1418
1419
# File 'lib/models/porcelain.rb', line 1417

def id
  @id
end

#nameObject

Unique human-readable name of the Resource.



1419
1420
1421
# File 'lib/models/porcelain.rb', line 1419

def name
  @name
end

#port_overrideObject

Returns the value of attribute port_override.



1421
1422
1423
# File 'lib/models/porcelain.rb', line 1421

def port_override
  @port_override
end

#private_keyObject

Returns the value of attribute private_key.



1423
1424
1425
# File 'lib/models/porcelain.rb', line 1423

def private_key
  @private_key
end

#projectObject

Returns the value of attribute project.



1425
1426
1427
# File 'lib/models/porcelain.rb', line 1425

def project
  @project
end

#secret_store_idObject

ID of the secret store containing credentials for this resource, if any.



1427
1428
1429
# File 'lib/models/porcelain.rb', line 1427

def secret_store_id
  @secret_store_id
end

#tagsObject

Tags is a map of key, value pairs.



1429
1430
1431
# File 'lib/models/porcelain.rb', line 1429

def tags
  @tags
end

#usernameObject

Returns the value of attribute username.



1431
1432
1433
# File 'lib/models/porcelain.rb', line 1431

def username
  @username
end

Instance Method Details

#to_json(options = {}) ⇒ Object



1459
1460
1461
1462
1463
1464
1465
# File 'lib/models/porcelain.rb', line 1459

def to_json(options = {})
  hash = {}
  self.instance_variables.each do |var|
    hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var
  end
  hash.to_json
end