Sha256: b1b2b09596669a9e3d43e3f225ad87b383731f4a39fb174670986b5e62ff4eea
Contents?: true
Size: 937 Bytes
Versions: 4
Compression:
Stored size: 937 Bytes
Contents
module Fog module Compute class Cloudstack class Real # List all public, private, and privileged templates. # # {CloudStack API Reference}[http://cloudstack.apache.org/docs/api/apidocs-4.4/root_admin/listTemplates.html] def list_templates(*args) options = {} if args[0].is_a? Hash options = args[0] options.merge!('command' => 'listTemplates') else options.merge!('command' => 'listTemplates', 'templatefilter' => args[0]) end request(options) end end class Mock def list_templates(options={}) templates = self.data[:images].values { "listtemplatesresponse" => { "count" => templates.size, "template"=> templates } } end end end end end
Version data entries
4 entries across 4 versions & 2 rubygems