Updated on May 7, 2012

OrgDelegate

The OrgDelegate allows a user to get information on one or more Organizations within the UForge platform. An Organization provides a set of resources, namely, one or more distributions, a Project Catalog and image formats to allow members to create Appliances and generate images. The user using this delegate must be a member of the Organization.

Constructor Summary

ConstructorSynopsis
OrgDelegate (com.usharesoft.client.common.connector.UForgeConnector connector) (null)

Creates a new OrgDelegate instance which allows a user to get information on one or more Organization within the UForge platform.

Method Summary

Return typeMethodSynopsis
Orgget

Returns the detailed information of an Organization.

Orgget

Returns the detailed information of an Organization.

Orgget

Returns the detailed information of an Organization.

DistributionsgetAllDistributions

Returns all distributions from the Organization that this user has access to. The user must be a member of the Organization.

DistributionsgetAllDistributions

Returns all distributions from the Organization that this user has access to. The user must be a member of the Organization.

ImageFormatsgetAllFormats

Returns all distributions from the Organization that this user has access to.The user must be a member of the Organization.

ImageFormatsgetAllFormats

Returns all distributions from the Organization that this user has access to.The user must be a member of the Organization.

DistributiongetDistribution

Returns a distribution from the Organization. The user must be a member of the Organization and have access to the distribution.

FilegetLicense

Downloads the license file for this Organization. The user must be a member of this Organization.

FilegetLicense

Downloads the license file for this Organization. The user must be a member of this Organization.

ProjectsgetProjects

Returns all the projects from the Organization's Project Catalog. Note that this will only return the project list that this user has access to. The user must be a member of this Organization.

Method Details

OrgDelegate

public OrgDelegate(UForgeConnector connector)

Creates a new OrgDelegate instance which allows a user to get information on one or more Organization within the UForge platform.

Parameters

Parameter NameDescription
UForgeConnector connector

all the authentication information required to correctly authorize an HTTPS request to UForge

get

public Org get(URI uri)

Returns the detailed information of an Organization.

Parameters

Parameter NameDescription
URI uri

the uri of the organization

get

public Org get(Org org)

Returns the detailed information of an Organization.

Parameters

Parameter NameDescription
Org org

the organization object to get

get

public Org get(String name)

Returns the detailed information of an Organization.

Parameters

Parameter NameDescription
String name

the name of the organization

getAllDistributions

public Distributions getAllDistributions(URI uri)

Returns all distributions from the Organization that this user has access to. The user must be a member of the Organization.

Parameters

Parameter NameDescription
URI uri

the uri of the organization

getAllDistributions

public Distributions getAllDistributions(Org org)

Returns all distributions from the Organization that this user has access to. The user must be a member of the Organization.

Parameters

Parameter NameDescription
Org org

the organization object

getAllFormats

public ImageFormats getAllFormats(URI uri)

Returns all distributions from the Organization that this user has access to.The user must be a member of the Organization.

Parameters

Parameter NameDescription
URI uri

the uri of the organization

getAllFormats

public ImageFormats getAllFormats(Org org)

Returns all distributions from the Organization that this user has access to.The user must be a member of the Organization.

Parameters

Parameter NameDescription
Org org

the organization object

getDistribution

public Distribution getDistribution(Org org, String name, String version, String arch)

Returns a distribution from the Organization. The user must be a member of the Organization and have access to the distribution.

Parameters

Parameter NameDescription
Org org

the organization object

String name

the name of the distribution

String version

the version of the distribution

String arch

the architecture of the distribution

getLicense

public File getLicense(URI uri, String localPath)

Downloads the license file for this Organization. The user must be a member of this Organization.

Parameters

Parameter NameDescription
URI uri

the uri of the organization object

String localPath

the full path where to download the license file

getLicense

public File getLicense(Org org, String localPath)

Downloads the license file for this Organization. The user must be a member of this Organization.

Parameters

Parameter NameDescription
Org org

the organization object

String localPath

the full path where to download the license file

getProjects

public Projects getProjects(Org org)

Returns all the projects from the Organization's Project Catalog. Note that this will only return the project list that this user has access to. The user must be a member of this Organization.

Parameters

Parameter NameDescription
Org org

the organization object