Sha256: 53fff4d75c22e1da6dca60961f1b6f2de22ed53412444b8e2f1f400b32e4af7f
Contents?: true
Size: 782 Bytes
Versions: 10
Compression:
Stored size: 782 Bytes
Contents
# # Author:: Matt Eldridge (<matt.eldridge@us.ibm.com>) # © Copyright IBM Corporation 2014. # # LICENSE: MIT (http://opensource.org/licenses/MIT) # require 'fog/core/collection' require 'fog/softlayer/models/compute/image' module Fog module Compute class Softlayer class Images < Fog::Collection model Fog::Compute::Softlayer::Image # Returns an array of all public images. # # Fog::Softlayer.images.all def all load(service.request(:virtual_guest_block_device_template_group, :get_public_images).body) self end # Used to retrieve an image def get(uuid) self.class.new(:service => service).all.detect {|image| image.id == uuid} end end end end end
Version data entries
10 entries across 10 versions & 1 rubygems