Click or drag to resize

IWsEndUserGetPurchasedVLans Method

Get a list of VLANs and associated purchased from your set.

Using the method GetPurchasedVLans() WsEndUser of Aruba, you can get a list of class objects that represent virtual LAN VLAN purchased and then associated with the account specified in the authentication phase. VLAN objects thus obtained allow to see the main features of VLAN purchased: mainly the resource name, its identification code (ID) and the code of the server to which the VLAN is associated.

Namespace:  Aruba.Cloud.WsEndUser
Assembly:  Aruba.Cloud.WsEndUser (in Aruba.Cloud.WsEndUser.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
[OperationContractAttribute]
WsResult<VLan[]> GetPurchasedVLans()

Return Value

Type: WsResultVLan
The method returns an object WsResult<VLan[]> containing information about VLAN purchased. For more information about the VLAN returned, see the extent VLan.
Examples
In the following example describes a method, called TestGetPurchasedVLans(), which via a method call GetPurchasedVLans () to Aruba WsEndUser, get a list of objects calss VLAN.

In the example, as a result of the method call GetPurchasedVLans() is a valued object variable of List <VLan[]> that will go to hold all the objects VLAN purchased and returned by the method.

private List<VLan>TestGetPurchasedVLans()
{
List<VLan> listOfPurchasedVlan = new List<VLan>();

try
{
WsResultOfArrayOfVLan result = client.GetPurchasedVLans();

if (result.Success)
listOfPurchasedVlan = result.Value.ToList<VLan>();
}
catch (Exception ex)
{
throw new ApplicationException(String.Format(
"An error has occurred while retrieving purchased VLans. {0}", ex.Message));
}

return listOfPurchasedVlan;
}
See Also