org.jclouds.joyent.cloudapi.v6_5.domain
Class Package

java.lang.Object
  extended by org.jclouds.joyent.cloudapi.v6_5.domain.Package
All Implemented Interfaces:
Comparable<Package>

public class Package
extends Object
implements Comparable<Package>

Packages are named collections of resources that are used to describe the ‘sizes’ of either a smart machine or a virtual machine. These resources include (but are not limited to) RAM, CPUs, CPU Caps, Lightweight Threads, Disk Space, Swap size, and Logical Networks.

Author:
Gerald Pereira
See Also:
docs

Nested Class Summary
static class Package.Builder
           
 
Field Summary
protected  int diskSizeGb
           
protected  boolean isDefault
           
protected  int memorySizeMb
           
protected  String name
           
protected  int swapSizeMb
           
 
Constructor Summary
Package(String name, int memorySizeMb, int diskSizeGb, int swapSizeMb, boolean isDefault)
           
 
Method Summary
static Package.Builder builder()
           
 int compareTo(Package that)
           
 boolean equals(Object object)
           
 int getDiskSizeGb()
          How much disk space will be available (in Gb)
 int getMemorySizeMb()
          How much memory will by available (in Mb)
 String getName()
          The "friendly name for this package
 int getSwapSizeMb()
          How much swap memory will be available (in Mb)
 int hashCode()
           
 boolean isDefault()
          Whether this is the default package in this datacenter
 Package.Builder toBuilder()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

name

protected final String name

memorySizeMb

@Named(value="memory")
protected final int memorySizeMb

diskSizeGb

@Named(value="disk")
protected final int diskSizeGb

swapSizeMb

@Named(value="swap")
protected final int swapSizeMb

isDefault

@Named(value="default")
protected final boolean isDefault
Constructor Detail

Package

@ConstructorProperties(value={"name","memory","disk","swap","default"})
public Package(String name,
                                          int memorySizeMb,
                                          int diskSizeGb,
                                          int swapSizeMb,
                                          boolean isDefault)
Method Detail

builder

public static Package.Builder builder()

toBuilder

public Package.Builder toBuilder()

getName

public String getName()
The "friendly name for this package


getMemorySizeMb

public int getMemorySizeMb()
How much memory will by available (in Mb)


getDiskSizeGb

public int getDiskSizeGb()
How much disk space will be available (in Gb)


getSwapSizeMb

public int getSwapSizeMb()
How much swap memory will be available (in Mb)


isDefault

public boolean isDefault()
Whether this is the default package in this datacenter


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(Package that)
Specified by:
compareTo in interface Comparable<Package>


Copyright © 2009-2012 jclouds. All Rights Reserved.