Sha256: 8fa542d51c73d5c7c026be10d4857e3d9a76f7d9673ab36e6d8d9e351a7a1949
Contents?: true
Size: 733 Bytes
Versions: 12
Compression:
Stored size: 733 Bytes
Contents
# frozen_string_literal: true module Awspec::Type class BatchComputeEnvironment < ResourceBase def initialize(compenv) super @display_name = compenv end def resource_via_client @resource_via_client ||= find_batch_compute_environment(@display_name) end def id @id ||= resource_via_client.compute_environment_name if resource_via_client end STATES = %w[ENABLED DISABLED] STATES.each do |state| define_method "#{state.downcase}?" do resource_via_client.state == state end end TYPES = %w[MANAGED UNMANAGED] TYPES.each do |type| define_method "#{type.downcase}?" do resource_via_client.type == type end end end end
Version data entries
12 entries across 12 versions & 1 rubygems