OneSystem (OpenNebula Cloud API)
Description: declaration: package: org.opennebula.client, class: OneSystem

Package org.opennebula.client

# Class OneSystem

java.lang.Object
org.opennebula.client.OneSystem

public class OneSystem extends Object

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected Client`
  `client`
  `static final String`
  `VERSION`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `OneSystem(Client client)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `compatibleVersion()`
  Returns whether of not the oned version is the same as the OCA version
  `OneResponse`
  `getConfiguration()`
  Calls OpenNebula and retrieves oned configuration
  `Node`
  `getConfigurationXML()`
  Calls OpenNebula and retrieves oned configuration
  `OneResponse`
  `getGroupQuotas()`
  Gets the default group quota limits
  `Node`
  `getGroupQuotasXML()`
  Gets the default group quota limits
  `OneResponse`
  `getOnedVersion()`
  Calls OpenNebula and retrieves the oned version
  `OneResponse`
  `getUserQuotas()`
  Gets the default user quota limits
  `Node`
  `getUserQuotasXML()`
  Gets the default user quota limits
  `OneResponse`
  `setGroupQuotas(String quota)`
  Sets the default group quota limits
  `OneResponse`
  `setUserQuotas(String quota)`
  Sets the default user quota limits

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### client

    protected Client client

  - ### VERSION

    public static final String VERSION
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### OneSystem

    public OneSystem(Client client)

- ## Method Details

  - ### getOnedVersion

    public OneResponse getOnedVersion()
    Calls OpenNebula and retrieves the oned version
    Returns:
      The server's xml-rpc response encapsulated

  - ### compatibleVersion

    public boolean compatibleVersion()
    Returns whether of not the oned version is the same as the OCA version
    Returns:
      true if oned is the same version

  - ### getConfiguration

    public OneResponse getConfiguration()
    Calls OpenNebula and retrieves oned configuration
    Returns:
      The server's xml-rpc response encapsulated

  - ### getConfigurationXML

    public Node getConfigurationXML()
    Calls OpenNebula and retrieves oned configuration
    Returns:
      The xml root node in case of success, null otherwise

  - ### getUserQuotas

    public OneResponse getUserQuotas()
    Gets the default user quota limits
    Returns:
      the default user quota in case of success, Error otherwise

  - ### getUserQuotasXML

    public Node getUserQuotasXML()
    Gets the default user quota limits
    Returns:
      The xml root node in case of success, null otherwise

  - ### setUserQuotas

    public OneResponse setUserQuotas(String quota)
    Sets the default user quota limits
    Parameters:
      `quota` - a template (XML or txt) with the new quota limits
    Returns:
      If an error occurs the error message contains the reason.

  - ### getGroupQuotas

    public OneResponse getGroupQuotas()
    Gets the default group quota limits
    Returns:
      the default group quota in case of success, Error otherwise

  - ### getGroupQuotasXML

    public Node getGroupQuotasXML()
    Gets the default group quota limits
    Returns:
      The xml root node in case of success, null otherwise

  - ### setGroupQuotas

    public OneResponse setGroupQuotas(String quota)
    Sets the default group quota limits
    Parameters:
      `quota` - a template (XML or txt) with the new quota limits
    Returns:
      If an error occurs the error message contains the reason.