Parent

Class/Module Index [+]

Quicksearch

Fog::Compute::Brightbox::DatabaseServer

Public Instance Methods

destroy() click to toggle source
# File lib/fog/brightbox/models/compute/database_server.rb, line 73
def destroy
  requires :identity
  merge_attributes(service.destroy_database_server(identity))
  true
end
ready?() click to toggle source
# File lib/fog/brightbox/models/compute/database_server.rb, line 63
def ready?
  state == "active"
end
reset_password() click to toggle source
# File lib/fog/brightbox/models/compute/database_server.rb, line 79
def reset_password
  requires :identity
  merge_attributes(service.reset_password_database_server(identity))
  true
end
save() click to toggle source
# File lib/fog/brightbox/models/compute/database_server.rb, line 35
def save
  options = {
    :name => name,
    :description => description
  }

  options[:allow_access] = allow_access if allow_access

  # These may be nil which sets them to default values upstream
  # TODO: Dirty track the values so we don't send them when already nil
  options[:maintenance_weekday] = maintenance_weekday
  options[:maintenance_hour] = maintenance_hour

  if persisted?
    data = update_database_server(options)
  else
    options[:engine] = database_engine if database_engine
    options[:version] = database_version if database_version
    options[:database_type] = flavor_id if flavor_id
    options[:zone] = zone_id if zone_id

    data = create_database_server(options)
  end

  merge_attributes(data)
  true
end
snapshot() click to toggle source
# File lib/fog/brightbox/models/compute/database_server.rb, line 67
def snapshot
  requires :identity
  merge_attributes(service.snapshot_database_server(identity))
  true
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.