IJsonpWsEndUserSetEnqueueAssociateVLan Method
|
Assigns a VLAN to a specified network adapter. Using the method SetEnqueueAssociateVLan () WsEndUser of Aruba, you can associate
to a VLAN network adapter among those available from your specified during authentication. The bind operation
IP address to a network adapter can not be completed if the network or virtual network adapter listed do not exist or
belong to the account specified, or if the virtual server is Stopped or Running state. Similarly, the operation of association
between VLANs and network adapter will not succeed if the network adapter is already assigned to a VLAN, or if it exists in the queue
an operation on the resource in question, in a state different from error or Completed.
Namespace:
Aruba.Cloud.WsEndUser
Assembly:
Aruba.Cloud.WsEndUser (in Aruba.Cloud.WsEndUser.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax[OperationContractAttribute]
[WebGetAttribute(ResponseFormat = WebMessageFormat.Json, UriTemplate = "SetEnqueueAssociateVLan/{jsonp}/{userName}/{token}/{vlanResourceId}/{networkAdapterId}/{ipAddress}/{subNetMask}/{gateway}/{setIPOnVM}")]
Stream SetEnqueueAssociateVLan(
string jsonp,
string userName,
string token,
string vlanResourceId,
string networkAdapterId,
string ipAddress,
string subNetMask,
string gateway,
string setIPOnVM = null
)<OperationContractAttribute>
<WebGetAttribute(ResponseFormat := WebMessageFormat.Json, UriTemplate := "SetEnqueueAssociateVLan/{jsonp}/{userName}/{token}/{vlanResourceId}/{networkAdapterId}/{ipAddress}/{subNetMask}/{gateway}/{setIPOnVM}")>
Function SetEnqueueAssociateVLan (
jsonp As String,
userName As String,
token As String,
vlanResourceId As String,
networkAdapterId As String,
ipAddress As String,
subNetMask As String,
gateway As String,
Optional setIPOnVM As String = Nothing
) As Stream[OperationContractAttribute]
[WebGetAttribute(ResponseFormat = WebMessageFormat::Json, UriTemplate = L"SetEnqueueAssociateVLan/{jsonp}/{userName}/{token}/{vlanResourceId}/{networkAdapterId}/{ipAddress}/{subNetMask}/{gateway}/{setIPOnVM}")]
Stream^ SetEnqueueAssociateVLan(
String^ jsonp,
String^ userName,
String^ token,
String^ vlanResourceId,
String^ networkAdapterId,
String^ ipAddress,
String^ subNetMask,
String^ gateway,
String^ setIPOnVM = nullptr
)[<OperationContractAttribute>]
[<WebGetAttribute(ResponseFormat = WebMessageFormat.Json, UriTemplate = "SetEnqueueAssociateVLan/{jsonp}/{userName}/{token}/{vlanResourceId}/{networkAdapterId}/{ipAddress}/{subNetMask}/{gateway}/{setIPOnVM}")>]
abstract SetEnqueueAssociateVLan :
jsonp : string *
userName : string *
token : string *
vlanResourceId : string *
networkAdapterId : string *
ipAddress : string *
subNetMask : string *
gateway : string *
?setIPOnVM : string
(* Defaults:
let _setIPOnVM = defaultArg setIPOnVM null
*)
-> Stream
function SetEnqueueAssociateVLan(
jsonp : String,
userName : String,
token : String,
vlanResourceId : String,
networkAdapterId : String,
ipAddress : String,
subNetMask : String,
gateway : String,
setIPOnVM : String
) : Stream
Parameters
- jsonp
- Type: SystemString
- userName
- Type: SystemString
- token
- Type: SystemString
- vlanResourceId
- Type: SystemString
- networkAdapterId
- Type: SystemString
Value of type System.Int32 which is the unique identifier of the network adapter to associate with the VLAN.
- ipAddress
- Type: SystemString
- subNetMask
- Type: SystemString
- gateway
- Type: SystemString
- setIPOnVM (Optional)
- Type: SystemString
Return Value
Type:
Stream
The method returns an object WsResult containing information on the outcome of the method call.
Examples
The following example shows a user-defined method, called AssociateVLan (), which through a call to
SetEnqueueAssociateVLan method () to Aruba WsEndUser, associates a resource of type network adapter with code 1941 to a resource
VLAN type with code 2019.
private static void AssociateVLan()
{
try
{
WsResult result = client.SetEnqueueAssociateIpAddress(1941, 2019);
if (!result.Success)
{
throw new ApplicationException(String.Format(
"An error has occurred while invoking SetEnqueueAssociateIpAddress(). {0}", result.ResultMessage));
}
}
catch (Exception ex)
{
throw new ApplicationException(String.Format(
"An error has occurred while connecting a network adapter to a VLan {0}", ex.Message));
}
}
See Also