class OneviewSDK::API600::C7000::ServerProfileTemplate

Server Profile Template resource implementation on API600 C7000

Public Class Methods

new(client, params = {}, api_ver = nil) click to toggle source

Create a resource object, associate it with a client, and set its properties. @param [OneviewSDK::Client] client The client object for the OneView appliance @param [Hash] params The options for this resource (key-value pairs) @param [Integer] api_ver The api version to use when interracting with this resource.

# File lib/oneview-sdk/resource/api600/c7000/server_profile_template.rb, line 24
def initialize(client, params = {}, api_ver = nil)
  @data ||= {}
  # Default values
  @data['type'] ||= 'ServerProfileTemplateV4'
  super
end

Public Instance Methods

get_available_networks(client, query = nil) click to toggle source

Retrieves the list of Ethernet networks, Fibre channel networks and network sets that are available to a server profile template along with their respective ports. @param [OneviewSDK::Client] client The client object for the OneView appliance. @param [Hash] query Query paramaters @option query [String] 'enclosure_group_uri' Enclosure group URI @option query [String] 'server_hardware_type_uri' Server hardware type URI @option query [String] 'profile_template_uri' Server profile template URI @option query [String] 'scope_uris' An expression to restrict the resources returned according to the scopes to which they are assigned @option query [String] 'view' The FunctionType (Ethernet or FibreChannel) to filter the list of networks returned @return [Hash] Hash containing the required information

# File lib/oneview-sdk/resource/api600/c7000/server_profile_template.rb, line 41
def get_available_networks(client, query = nil)
  query_uri = OneviewSDK::Resource.build_query(query) if query
  response = client.rest_get("#{BASE_URI}/available-networks#{query_uri}")
  client.response_handler(response)
end