org.jclouds.ec2.domain
Class Reservation<T extends RunningInstance>

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractSet<E>
          extended by java.util.HashSet<E>
              extended by java.util.LinkedHashSet<T>
                  extended by org.jclouds.ec2.domain.Reservation<T>
All Implemented Interfaces:
Serializable, Cloneable, Comparable<Reservation<T>>, Iterable<T>, Collection<T>, Set<T>

public class Reservation<T extends RunningInstance>
extends LinkedHashSet<T>
implements Comparable<Reservation<T>>, Set<T>

Author:
Adrian Cole
See Also:
, Serialized Form

Constructor Summary
Reservation(String region, Iterable<String> groupIds, Iterable<T> instances, String ownerId, String requesterId, String reservationId)
           
 
Method Summary
 int compareTo(Reservation<T> o)
           
 boolean equals(Object obj)
           
 Set<String> getGroupIds()
          Names of the security groups.
 String getOwnerId()
          AWS Access Key ID of the user who owns the reservation.
 String getRegion()
          Instances are tied to Availability Zones.
 String getRequesterId()
          ID of the requester.
 String getReservationId()
          Unique ID of the reservation.
 int hashCode()
           
 
Methods inherited from class java.util.HashSet
add, clear, clone, contains, isEmpty, iterator, remove, size
 
Methods inherited from class java.util.AbstractSet
removeAll
 
Methods inherited from class java.util.AbstractCollection
addAll, containsAll, retainAll, toArray, toArray, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Set
add, addAll, clear, contains, containsAll, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
 

Constructor Detail

Reservation

public Reservation(String region,
                   Iterable<String> groupIds,
                   Iterable<T> instances,
                   @Nullable
                   String ownerId,
                   @Nullable
                   String requesterId,
                   @Nullable
                   String reservationId)
Method Detail

getRegion

public String getRegion()
Instances are tied to Availability Zones. However, the instance ID is tied to the Region.


compareTo

public int compareTo(Reservation<T> o)
Specified by:
compareTo in interface Comparable<Reservation<T extends RunningInstance>>

getGroupIds

public Set<String> getGroupIds()
Names of the security groups.


getOwnerId

public String getOwnerId()
AWS Access Key ID of the user who owns the reservation.


getRequesterId

public String getRequesterId()
ID of the requester.


getReservationId

public String getReservationId()
Unique ID of the reservation.


hashCode

public int hashCode()
Specified by:
hashCode in interface Collection<T extends RunningInstance>
Specified by:
hashCode in interface Set<T extends RunningInstance>
Overrides:
hashCode in class AbstractSet<T extends RunningInstance>

equals

public boolean equals(Object obj)
Specified by:
equals in interface Collection<T extends RunningInstance>
Specified by:
equals in interface Set<T extends RunningInstance>
Overrides:
equals in class AbstractSet<T extends RunningInstance>


Copyright © 2009-2011 jclouds. All Rights Reserved.