org.jclouds.openstack.domain
Class Resource

java.lang.Object
  extended by org.jclouds.openstack.domain.Resource
All Implemented Interfaces:
Comparable<Resource>
Direct Known Subclasses:
Server

public class Resource
extends Object
implements Comparable<Resource>

Resource found in a paginated collection

Author:
AdrianCole
See Also:

Nested Class Summary
static class Resource.Builder
           
 
Field Summary
protected  String id
           
protected  Set<Link> links
           
protected  String name
           
 
Constructor Summary
Resource(String id, String name, Set<Link> links)
           
 
Method Summary
static Resource.Builder builder()
           
 int compareTo(Resource that)
           
 boolean equals(Object object)
           
 String getId()
          When providing an ID, it is assumed that the resource exists in the current OpenStack deployment
 Set<Link> getLinks()
           
 String getName()
           
 int hashCode()
           
 Resource.Builder toBuilder()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

id

protected final String id

name

protected final String name

links

protected final Set<Link> links
Constructor Detail

Resource

public Resource(String id,
                String name,
                Set<Link> links)
Method Detail

builder

public static Resource.Builder builder()

toBuilder

public Resource.Builder toBuilder()

getId

public String getId()
When providing an ID, it is assumed that the resource exists in the current OpenStack deployment

Returns:
the id of the resource in the current OpenStack deployment

getName

public String getName()
Returns:
the name of the resource

getLinks

public Set<Link> getLinks()
Returns:
the links of the id address allocated to the new server

equals

public boolean equals(Object object)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

compareTo

public int compareTo(Resource that)
Specified by:
compareTo in interface Comparable<Resource>


Copyright © 2009-2012 jclouds. All Rights Reserved.