class Fastly::BelongsToServiceAndVersion

Encapsulates behavior of objects requiring both service and version

Attributes

version[W]

Public Instance Methods

service() click to toggle source

Return the Service object this belongs to

# File lib/fastly/belongs_to_service_and_version.rb, line 9
def service
  @service ||= fetcher.get(Service, service_id)
end
version() click to toggle source

Get the Version object this belongs to

# File lib/fastly/belongs_to_service_and_version.rb, line 14
def version
  @version_obj ||= fetcher.get(Fastly::Version, service_id, version_number)
end
version_number() click to toggle source

Get the number of the Version this belongs to

# File lib/fastly/belongs_to_service_and_version.rb, line 19
def version_number
  @version ||= nil
end