Class AWS::EC2::PermissionCollection
In: lib/aws/ec2/permission_collection.rb
Parent: Object

Represents the collection of permissions for an EC2 resource. Each permission is a string containing the AWS account ID of a user who has permission to use the resource in question. The {Image} and {Snapshot} classes are currently the only ones that use this interface.

Methods

add   each   empty?   new   private?   public=   public?   remove   reset   size  

Included Modules

Model Enumerable

Public Class methods

Public Instance methods

Adds permissions for specific users to launch this AMI.

@param [Array of Strings] users The AWS account IDs of the

  users that should be able to launch this AMI.

@return [nil]

@yield [user_id] Each user ID that has explicit

  permissions to launch this AMI.

@return [Boolean] True if the collection is empty.

@return [Boolean] True if the resource is private (i.e. not

  public).

Sets whether the resource is public or not. This has no effect on the explicit AWS account IDs that may already have permissions to use the resource.

@param [Boolean] value If true, the resource is made public,

  otherwise the resource is made private.

@return [nil]

@return [Boolean] True if the resource is public.

Removes permissions for specific users to launch this AMI. @param [Array of Strings] users The AWS account IDs of the

  users that should no longer be able to launch this AMI.

@return [nil]

Resets the launch permissions to their default state. @return [nil]

@return [Integer] The number of users that have explicit

  permissions to launch this AMI.

[Validate]