com.shephertz.app42.paas.sdk.jme.appTab
Class SchemeService

java.lang.Object
  extended by com.shephertz.app42.paas.sdk.jme.appTab.SchemeService

public class SchemeService
extends java.lang.Object

See Also:
PackageService, SchemeData, App42Response

Constructor Summary
SchemeService(java.lang.String apiKey, java.lang.String secretKey, java.lang.String baseURL)
          This is a constructor that takes
 
Method Summary
 SchemeData addBandwidthInToPackage(java.lang.String schemeName, java.lang.String packageName, java.lang.String bandwidthName)
          Add bandwidthPackage into the existing package
 SchemeData addFeatureInToPackage(java.lang.String schemeName, java.lang.String packageName, java.util.Vector featureList)
          Add a feature into existing package
 SchemeData addLimitToBandwidth(java.lang.String schemeName, java.lang.String packageName, java.lang.String bandwidthName, java.lang.Double price, java.lang.String unit, java.lang.Double bandwidth)
           
 SchemeData addLimitToStorage(java.lang.String schemeName, java.lang.String packageName, java.lang.String storageName, java.lang.Double price, java.lang.String unit, java.lang.Double space)
          Add StoageLimit into existing package
 SchemeData addStorageInToPackage(java.lang.String schemeName, java.lang.String packageName, java.lang.String storageName)
          Add a storagePackage into the existing package
 SchemeData createPackage(java.lang.String schemeName, SchemeData.PackageData pkgData)
          Create a package for the specified scheme
 SchemeData createPackageWithUsage(java.lang.String schemeName, SchemeData.PackageData pkgData)
          Create a package with different types of packages
 SchemeData createScheme(java.lang.String schemeName, java.lang.String description)
          Create a schemeName which should be unique
 SchemeData getAllPackages(java.lang.String schemeName)
          Fetch the details based on scheme
 java.util.Vector getAllSchemes()
          Get all the details of scheme
 SchemeData getPackageByPackageName(java.lang.String schemeName, java.lang.String packageName)
          Fetch the details of package for a scheme
 SchemeData getSchemeByName(java.lang.String schemeName)
          Get the scheme details based on schemeName
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SchemeService

public SchemeService(java.lang.String apiKey,
                     java.lang.String secretKey,
                     java.lang.String baseURL)
This is a constructor that takes

Parameters:
apiKey -
secretKey -
baseURL -
Method Detail

addBandwidthInToPackage

public SchemeData addBandwidthInToPackage(java.lang.String schemeName,
                                          java.lang.String packageName,
                                          java.lang.String bandwidthName)
                                   throws App42Exception
Add bandwidthPackage into the existing package

Parameters:
schemeName - - Name of the scheme in which you add package
packageName - - Name of the package in which you wan't to add bandwidth, description.
bandwidthName - -Name of the bandwidth you wan't to add in package
Returns:
The created packageData object
Throws:
App42Exception

addFeatureInToPackage

public SchemeData addFeatureInToPackage(java.lang.String schemeName,
                                        java.lang.String packageName,
                                        java.util.Vector featureList)
                                 throws App42Exception
Add a feature into existing package

Parameters:
schemeName - - Name of the scheme in which feature has to be added
packageName - - Name of the package in which feature has to be added
featureList - - List of features Name you want't to add in package
Returns:
The PackageData Object
Throws:
App42Exception

addLimitToBandwidth

public SchemeData addLimitToBandwidth(java.lang.String schemeName,
                                      java.lang.String packageName,
                                      java.lang.String bandwidthName,
                                      java.lang.Double price,
                                      java.lang.String unit,
                                      java.lang.Double bandwidth)
                               throws App42Exception
Parameters:
schemeName - - Name of the scheme in which bandwidthLimit has to be added
packageName - - Name of the package in which bandwidthLimit has to be added
bandwidthName - - Name of the bandwidth in which limit has to be added
price - - Price for the limit object
unit - - Unit for the limit object
bandwidth - - Bandwidth for the limit object
Returns:
The SchemeData Object
Throws:
App42Exception

addLimitToStorage

public SchemeData addLimitToStorage(java.lang.String schemeName,
                                    java.lang.String packageName,
                                    java.lang.String storageName,
                                    java.lang.Double price,
                                    java.lang.String unit,
                                    java.lang.Double space)
                             throws App42Exception
Add StoageLimit into existing package

Parameters:
schemeName - - Name of the scheme in which storageLimit has to be added
packageName - - Name of the package in which storageLimit has to be added
storageName - -Name of the storage in which limit has to be added
price - - Price for the limit object
unit - - Unit for the limit object
space - - Space for the limit object
Returns:
Throws:
App42Exception

addStorageInToPackage

public SchemeData addStorageInToPackage(java.lang.String schemeName,
                                        java.lang.String packageName,
                                        java.lang.String storageName)
                                 throws App42Exception
Add a storagePackage into the existing package

Parameters:
schemeName - - Name of the scheme in which you add package
packageName - - Name of the package in which you wan't to add storage, description.
storageName - -Name of the storage you wan't to add in package
Returns:
The created packageData object
Throws:
App42Exception

createPackage

public SchemeData createPackage(java.lang.String schemeName,
                                SchemeData.PackageData pkgData)
                         throws App42Exception
Create a package for the specified scheme

Parameters:
schemeName - - Name for which you want to create package
pkgData - - Details of the package like name, duration, price, currency, description.
Returns:
The created packageData object
Throws:
App42Exception

createPackageWithUsage

public SchemeData createPackageWithUsage(java.lang.String schemeName,
                                         SchemeData.PackageData pkgData)
                                  throws App42Exception
Create a package with different types of packages

Parameters:
schemeName - - Name of the scheme for which you want to create a package
pkgData - - pkgData contails the details of package
Returns:
- The PackageData Object
Throws:
App42Exception

createScheme

public SchemeData createScheme(java.lang.String schemeName,
                               java.lang.String description)
                        throws App42Exception
Create a schemeName which should be unique

Parameters:
schemeName - - Name of the scheme you want to be create
description - - Description of the scheme
Returns:
The SchemeData Object
Throws:
App42Exception

getAllPackages

public SchemeData getAllPackages(java.lang.String schemeName)
                          throws App42Exception
Fetch the details based on scheme

Parameters:
schemeName - - Name of the scheme you wan't to retrieve
Returns:
- The PackageData Object
Throws:
App42Exception

getAllSchemes

public java.util.Vector getAllSchemes()
                               throws App42Exception
Get all the details of scheme

Returns:
The SchemeData Object
Throws:
App42Exception

getPackageByPackageName

public SchemeData getPackageByPackageName(java.lang.String schemeName,
                                          java.lang.String packageName)
                                   throws App42Exception
Fetch the details of package for a scheme

Parameters:
schemeName - - Name of the scheme from which package has to be fetched
packageName - - Name of the package from which package has to be fetched
Returns:
- The PackageData Object
Throws:
App42Exception

getSchemeByName

public SchemeData getSchemeByName(java.lang.String schemeName)
                           throws App42Exception
Get the scheme details based on schemeName

Parameters:
schemeName - - Name of the scheme to retrieve
Returns:
- The SchemeData Object
Throws:
App42Exception