mirror of https://github.com/apache/jclouds.git
JCLOUDS-220. Adding projectId to a bunch of CloudStack API options
This commit is contained in:
parent
375cb2075d
commit
2fcd90c394
|
@ -40,6 +40,15 @@ public class AssociateIPAddressOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* Project for the IP
|
||||||
|
*/
|
||||||
|
public AssociateIPAddressOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -65,6 +74,14 @@ public class AssociateIPAddressOptions extends AccountInDomainOptions {
|
||||||
AssociateIPAddressOptions options = new AssociateIPAddressOptions();
|
AssociateIPAddressOptions options = new AssociateIPAddressOptions();
|
||||||
return options.domainId(domainId);
|
return options.domainId(domainId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see AssociateIPAddressOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static AssociateIPAddressOptions projectId(String projectId) {
|
||||||
|
AssociateIPAddressOptions options = new AssociateIPAddressOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -102,6 +102,15 @@ public class CreateNetworkOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* the project this network will be in.
|
||||||
|
*/
|
||||||
|
public CreateNetworkOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
/**
|
/**
|
||||||
* @see CreateNetworkOptions#isDefault
|
* @see CreateNetworkOptions#isDefault
|
||||||
|
@ -182,6 +191,14 @@ public class CreateNetworkOptions extends AccountInDomainOptions {
|
||||||
CreateNetworkOptions options = new CreateNetworkOptions();
|
CreateNetworkOptions options = new CreateNetworkOptions();
|
||||||
return options.domainId(domainId);
|
return options.domainId(domainId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see CreateNetworkOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static CreateNetworkOptions projectId(String projectId) {
|
||||||
|
CreateNetworkOptions options = new CreateNetworkOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -48,6 +48,14 @@ public class CreateVMGroupOptions extends BaseHttpRequestOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId the project the vm group will be in
|
||||||
|
*/
|
||||||
|
public CreateVMGroupOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
/**
|
/**
|
||||||
* @see org.jclouds.cloudstack.options.CreateVMGroupOptions#account
|
* @see org.jclouds.cloudstack.options.CreateVMGroupOptions#account
|
||||||
|
@ -64,6 +72,14 @@ public class CreateVMGroupOptions extends BaseHttpRequestOptions {
|
||||||
CreateVMGroupOptions options = new CreateVMGroupOptions();
|
CreateVMGroupOptions options = new CreateVMGroupOptions();
|
||||||
return options.domainId(id);
|
return options.domainId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.jclouds.cloudstack.options.CreateVMGroupOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static CreateVMGroupOptions projectId(String id) {
|
||||||
|
CreateVMGroupOptions options = new CreateVMGroupOptions();
|
||||||
|
return options.projectId(id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,6 +67,10 @@ public class CreateVlanIPRangeOptions extends AccountInDomainOptions {
|
||||||
return new CreateVlanIPRangeOptions().networkId(networkId);
|
return new CreateVlanIPRangeOptions().networkId(networkId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static CreateVlanIPRangeOptions projectId(String projectId) {
|
||||||
|
return new CreateVlanIPRangeOptions().projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -118,4 +122,9 @@ public class CreateVlanIPRangeOptions extends AccountInDomainOptions {
|
||||||
this.queryParameters.replaceValues("networkid", ImmutableSet.of(networkId+""));
|
this.queryParameters.replaceValues("networkid", ImmutableSet.of(networkId+""));
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public CreateVlanIPRangeOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId+""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -169,6 +169,14 @@ public class DeployVirtualMachineOptions extends AccountInDomainOptions {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId The project this VM will be in.
|
||||||
|
*/
|
||||||
|
public DeployVirtualMachineOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param securityGroupId
|
* @param securityGroupId
|
||||||
* security group applied to the virtual machine. Should be passed
|
* security group applied to the virtual machine. Should be passed
|
||||||
|
@ -298,6 +306,14 @@ public class DeployVirtualMachineOptions extends AccountInDomainOptions {
|
||||||
return options.networkIds(networkIds);
|
return options.networkIds(networkIds);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see DeployVirtualMachineOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static DeployVirtualMachineOptions projectId(String id) {
|
||||||
|
DeployVirtualMachineOptions options = new DeployVirtualMachineOptions();
|
||||||
|
return options.projectId(id);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see DeployVirtualMachineOptions#securityGroupId
|
* @see DeployVirtualMachineOptions#securityGroupId
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -63,6 +63,11 @@ public class ListEventsOptions extends BaseHttpRequestOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public ListEventsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public ListEventsOptions keyword(String keyword) {
|
public ListEventsOptions keyword(String keyword) {
|
||||||
this.queryParameters.replaceValues("keyword", ImmutableSet.of(keyword));
|
this.queryParameters.replaceValues("keyword", ImmutableSet.of(keyword));
|
||||||
return this;
|
return this;
|
||||||
|
@ -110,6 +115,11 @@ public class ListEventsOptions extends BaseHttpRequestOptions {
|
||||||
return options.id(id);
|
return options.id(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static ListEventsOptions projectId(String projectId) {
|
||||||
|
final ListEventsOptions options = new ListEventsOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
public static ListEventsOptions keyword(String keyword) {
|
public static ListEventsOptions keyword(String keyword) {
|
||||||
final ListEventsOptions options = new ListEventsOptions();
|
final ListEventsOptions options = new ListEventsOptions();
|
||||||
return options.keyword(keyword);
|
return options.keyword(keyword);
|
||||||
|
|
|
@ -48,6 +48,15 @@ public class ListFirewallRulesOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* List firewall rules in this project.
|
||||||
|
*/
|
||||||
|
public ListFirewallRulesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param keyword
|
* @param keyword
|
||||||
* list by keyword
|
* list by keyword
|
||||||
|
@ -85,6 +94,14 @@ public class ListFirewallRulesOptions extends AccountInDomainOptions {
|
||||||
return options.ipAddressId(ipAddressId);
|
return options.ipAddressId(ipAddressId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListFirewallRulesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListFirewallRulesOptions projectId(String projectId) {
|
||||||
|
ListFirewallRulesOptions options = new ListFirewallRulesOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListFirewallRulesOptions#keyword
|
* @see ListFirewallRulesOptions#keyword
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -59,6 +59,16 @@ public class ListIPForwardingRulesOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* Lists all rules applied to VMs in the given project.
|
||||||
|
*/
|
||||||
|
public ListIPForwardingRulesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -100,6 +110,14 @@ public class ListIPForwardingRulesOptions extends AccountInDomainOptions {
|
||||||
ListIPForwardingRulesOptions options = new ListIPForwardingRulesOptions();
|
ListIPForwardingRulesOptions options = new ListIPForwardingRulesOptions();
|
||||||
return options.virtualMachineId(virtualMachineId);
|
return options.virtualMachineId(virtualMachineId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListIPForwardingRulesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListIPForwardingRulesOptions projectId(String projectId) {
|
||||||
|
ListIPForwardingRulesOptions options = new ListIPForwardingRulesOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -67,6 +67,14 @@ public class ListISOsOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId list ISOs in the given project
|
||||||
|
*/
|
||||||
|
public ListISOsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param isoFilter possible values are "featured", "self", "self-executable","executable", and "community".
|
* @param isoFilter possible values are "featured", "self", "self-executable","executable", and "community".
|
||||||
*/
|
*/
|
||||||
|
@ -174,6 +182,13 @@ public class ListISOsOptions extends AccountInDomainOptions {
|
||||||
return new ListISOsOptions().id(id);
|
return new ListISOsOptions().id(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId list ISOs in project
|
||||||
|
*/
|
||||||
|
public static ListISOsOptions projectId(String projectId) {
|
||||||
|
return new ListISOsOptions().projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param isoFilter possible values are "featured", "self", "self-executable","executable", and "community".
|
* @param isoFilter possible values are "featured", "self", "self-executable","executable", and "community".
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -74,6 +74,14 @@ public class ListLoadBalancerRulesOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId the project ID
|
||||||
|
*/
|
||||||
|
public ListLoadBalancerRulesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param page the number of the page
|
* @param page the number of the page
|
||||||
*/
|
*/
|
||||||
|
@ -148,6 +156,14 @@ public class ListLoadBalancerRulesOptions extends AccountInDomainOptions {
|
||||||
return options.zoneId(zoneId);
|
return options.zoneId(zoneId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListLoadBalancerRulesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListLoadBalancerRulesOptions projectId(String projectId) {
|
||||||
|
ListLoadBalancerRulesOptions options = new ListLoadBalancerRulesOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListLoadBalancerRulesOptions#page
|
* @see ListLoadBalancerRulesOptions#page
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -88,6 +88,16 @@ public class ListNetworksOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* the project ID of the network
|
||||||
|
*/
|
||||||
|
public ListNetworksOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param trafficType
|
* @param trafficType
|
||||||
* type of the traffic
|
* type of the traffic
|
||||||
|
@ -162,6 +172,14 @@ public class ListNetworksOptions extends AccountInDomainOptions {
|
||||||
return options.zoneId(id);
|
return options.zoneId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListNetworksOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListNetworksOptions projectId(String id) {
|
||||||
|
ListNetworksOptions options = new ListNetworksOptions();
|
||||||
|
return options.projectId(id);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListNetworksOptions#trafficType
|
* @see ListNetworksOptions#trafficType
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -49,6 +49,15 @@ public class ListPortForwardingRulesOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* list the rules in this project
|
||||||
|
*/
|
||||||
|
public ListPortForwardingRulesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
|
||||||
|
}
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -67,6 +76,14 @@ public class ListPortForwardingRulesOptions extends AccountInDomainOptions {
|
||||||
return options.ipAddressId(ipAddressId);
|
return options.ipAddressId(ipAddressId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListPortForwardingRulesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListPortForwardingRulesOptions projectId(String projectId) {
|
||||||
|
ListPortForwardingRulesOptions options = new ListPortForwardingRulesOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListPortForwardingRulesOptions#accountInDomain
|
* @see ListPortForwardingRulesOptions#accountInDomain
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -59,6 +59,16 @@ public class ListPublicIPAddressesOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* list ip addresss by project.
|
||||||
|
*/
|
||||||
|
public ListPublicIPAddressesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param VLANId
|
* @param VLANId
|
||||||
* lists all public IP addresses by VLAN ID
|
* lists all public IP addresses by VLAN ID
|
||||||
|
@ -147,6 +157,14 @@ public class ListPublicIPAddressesOptions extends AccountInDomainOptions {
|
||||||
return options.networkId(id);
|
return options.networkId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListPublicIPAddressesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListPublicIPAddressesOptions projectId(String id) {
|
||||||
|
ListPublicIPAddressesOptions options = new ListPublicIPAddressesOptions();
|
||||||
|
return options.projectId(id);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListPublicIPAddressesOptions#VLANId
|
* @see ListPublicIPAddressesOptions#VLANId
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -61,6 +61,17 @@ public class ListResourceLimitsOptions extends BaseHttpRequestOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Lists resource limits by project.
|
||||||
|
*
|
||||||
|
* @param projectId the project
|
||||||
|
* @return ListResourceLimitsOptions
|
||||||
|
*/
|
||||||
|
public ListResourceLimitsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(String.valueOf(projectId + "")));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* List by keyword
|
* List by keyword
|
||||||
*
|
*
|
||||||
|
@ -116,6 +127,14 @@ public class ListResourceLimitsOptions extends BaseHttpRequestOptions {
|
||||||
return options.id(id);
|
return options.id(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListResourceLimitsOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListResourceLimitsOptions projectId(String projectId) {
|
||||||
|
ListResourceLimitsOptions options = new ListResourceLimitsOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListResourceLimitsOptions#keyword(String)
|
* @see ListResourceLimitsOptions#keyword(String)
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -36,6 +36,15 @@ public class ListSSHKeyPairsOptions extends BaseHttpRequestOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* the project to list in
|
||||||
|
*/
|
||||||
|
public ListSSHKeyPairsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectId", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
/**
|
/**
|
||||||
* @see ListSSHKeyPairsOptions#name
|
* @see ListSSHKeyPairsOptions#name
|
||||||
|
@ -45,5 +54,13 @@ public class ListSSHKeyPairsOptions extends BaseHttpRequestOptions {
|
||||||
return options.name(name);
|
return options.name(name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListSSHKeyPairsOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListSSHKeyPairsOptions projectId(String projectId) {
|
||||||
|
ListSSHKeyPairsOptions options = new ListSSHKeyPairsOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -60,6 +60,15 @@ public class ListSecurityGroupsOptions extends AssociateIPAddressOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* the ID of the project to search in.
|
||||||
|
*/
|
||||||
|
public ListSecurityGroupsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -86,6 +95,14 @@ public class ListSecurityGroupsOptions extends AssociateIPAddressOptions {
|
||||||
return options.virtualMachineId(virtualMachineId);
|
return options.virtualMachineId(virtualMachineId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListSecurityGroupsOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListSecurityGroupsOptions projectId(String projectId) {
|
||||||
|
ListSecurityGroupsOptions options = new ListSecurityGroupsOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see DeployVirtualMachineOptions#accountInDomain
|
* @see DeployVirtualMachineOptions#accountInDomain
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -87,6 +87,14 @@ public class ListSnapshotsOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId the project to list in
|
||||||
|
*/
|
||||||
|
public ListSnapshotsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -152,6 +160,13 @@ public class ListSnapshotsOptions extends AccountInDomainOptions {
|
||||||
public static ListSnapshotsOptions volumeId(String volumeId) {
|
public static ListSnapshotsOptions volumeId(String volumeId) {
|
||||||
return new ListSnapshotsOptions().volumeId(volumeId);
|
return new ListSnapshotsOptions().volumeId(volumeId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId the project to list in
|
||||||
|
*/
|
||||||
|
public static ListSnapshotsOptions projectId(String projectId) {
|
||||||
|
return new ListSnapshotsOptions().projectId(projectId);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -72,6 +72,16 @@ public class ListTemplatesOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* list templates by projectId.
|
||||||
|
*/
|
||||||
|
public ListTemplatesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param hypervisor
|
* @param hypervisor
|
||||||
* the hypervisor for which to restrict the search
|
* the hypervisor for which to restrict the search
|
||||||
|
@ -131,6 +141,14 @@ public class ListTemplatesOptions extends AccountInDomainOptions {
|
||||||
return options.zoneId(id);
|
return options.zoneId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListTemplatesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListTemplatesOptions projectId(String projectId) {
|
||||||
|
ListTemplatesOptions options = new ListTemplatesOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListTemplatesOptions#hypervisor
|
* @see ListTemplatesOptions#hypervisor
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -43,6 +43,11 @@ public class ListUsageRecordsOptions extends AccountInDomainOptions {
|
||||||
return options.accountId(accountId);
|
return options.accountId(accountId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static ListUsageRecordsOptions projectId(String projectId) {
|
||||||
|
ListUsageRecordsOptions options = new ListUsageRecordsOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
public static ListUsageRecordsOptions keyword(String keyword) {
|
public static ListUsageRecordsOptions keyword(String keyword) {
|
||||||
ListUsageRecordsOptions options = new ListUsageRecordsOptions();
|
ListUsageRecordsOptions options = new ListUsageRecordsOptions();
|
||||||
return options.keyword(keyword);
|
return options.keyword(keyword);
|
||||||
|
@ -64,6 +69,11 @@ public class ListUsageRecordsOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public ListUsageRecordsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public ListUsageRecordsOptions keyword(String keyword) {
|
public ListUsageRecordsOptions keyword(String keyword) {
|
||||||
this.queryParameters.replaceValues("keyword", ImmutableSet.of(keyword));
|
this.queryParameters.replaceValues("keyword", ImmutableSet.of(keyword));
|
||||||
return this;
|
return this;
|
||||||
|
|
|
@ -56,6 +56,14 @@ public class ListVMGroupsOptions extends BaseHttpRequestOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId id of the project the vm group is in
|
||||||
|
*/
|
||||||
|
public ListVMGroupsOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param keyword keyword to search on
|
* @param keyword keyword to search on
|
||||||
*/
|
*/
|
||||||
|
@ -97,6 +105,14 @@ public class ListVMGroupsOptions extends BaseHttpRequestOptions {
|
||||||
return options.domainId(id);
|
return options.domainId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see org.jclouds.cloudstack.options.ListVMGroupsOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListVMGroupsOptions projectId(String id) {
|
||||||
|
ListVMGroupsOptions options = new ListVMGroupsOptions();
|
||||||
|
return options.projectId(id);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see org.jclouds.cloudstack.options.ListVMGroupsOptions#keyword
|
* @see org.jclouds.cloudstack.options.ListVMGroupsOptions#keyword
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -97,6 +97,16 @@ public class ListVirtualMachinesOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId
|
||||||
|
* list virtual machines by projectId.
|
||||||
|
*/
|
||||||
|
public ListVirtualMachinesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param zoneId
|
* @param zoneId
|
||||||
* list virtual machines by zoneId.
|
* list virtual machines by zoneId.
|
||||||
|
@ -191,6 +201,14 @@ public class ListVirtualMachinesOptions extends AccountInDomainOptions {
|
||||||
return options.podId(id);
|
return options.podId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListVirtualMachinesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListVirtualMachinesOptions projectId(String id) {
|
||||||
|
ListVirtualMachinesOptions options = new ListVirtualMachinesOptions();
|
||||||
|
return options.projectId(id);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ListVirtualMachinesOptions#zoneId
|
* @see ListVirtualMachinesOptions#zoneId
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -55,6 +55,10 @@ public class ListVlanIPRangesOptions extends AccountInDomainOptions {
|
||||||
return new ListVlanIPRangesOptions().podId(podId);
|
return new ListVlanIPRangesOptions().podId(podId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static ListVlanIPRangesOptions projectId(String projectId) {
|
||||||
|
return new ListVlanIPRangesOptions().projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
public static ListVlanIPRangesOptions vlan(long vlan) {
|
public static ListVlanIPRangesOptions vlan(long vlan) {
|
||||||
return new ListVlanIPRangesOptions().vlan(vlan);
|
return new ListVlanIPRangesOptions().vlan(vlan);
|
||||||
}
|
}
|
||||||
|
@ -103,6 +107,11 @@ public class ListVlanIPRangesOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public ListVlanIPRangesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId+""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public ListVlanIPRangesOptions vlan(String vlan) {
|
public ListVlanIPRangesOptions vlan(String vlan) {
|
||||||
this.queryParameters.replaceValues("vlan", ImmutableSet.of(vlan));
|
this.queryParameters.replaceValues("vlan", ImmutableSet.of(vlan));
|
||||||
return this;
|
return this;
|
||||||
|
|
|
@ -107,6 +107,15 @@ public class ListVolumesOptions extends AccountInDomainOptions {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId list volumes by projectId.
|
||||||
|
*/
|
||||||
|
public ListVolumesOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
|
|
||||||
|
@ -198,6 +207,14 @@ public class ListVolumesOptions extends AccountInDomainOptions {
|
||||||
ListVolumesOptions options = new ListVolumesOptions();
|
ListVolumesOptions options = new ListVolumesOptions();
|
||||||
return options.zoneId(id);
|
return options.zoneId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @see ListVolumesOptions#projectId(String)
|
||||||
|
*/
|
||||||
|
public static ListVolumesOptions projectId(String id) {
|
||||||
|
ListVolumesOptions options = new ListVolumesOptions();
|
||||||
|
return options.projectId(id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -69,6 +69,14 @@ public class RegisterISOOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId the project this ISO will be in.
|
||||||
|
*/
|
||||||
|
public RegisterISOOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public static class Builder {
|
public static class Builder {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -119,6 +127,13 @@ public class RegisterISOOptions extends AccountInDomainOptions {
|
||||||
public static RegisterISOOptions osTypeId(String osTypeId) {
|
public static RegisterISOOptions osTypeId(String osTypeId) {
|
||||||
return new RegisterISOOptions().osTypeId(osTypeId);
|
return new RegisterISOOptions().osTypeId(osTypeId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param projectId the project this ISO will be in.
|
||||||
|
*/
|
||||||
|
public static RegisterISOOptions projectId(String projectId) {
|
||||||
|
return new RegisterISOOptions().projectId(projectId);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,6 +46,14 @@ public class RegisterTemplateOptions extends AccountInDomainOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* the project for this template.
|
||||||
|
*/
|
||||||
|
public RegisterTemplateOptions projectId(String projectId) {
|
||||||
|
this.queryParameters.replaceValues("projectid", ImmutableSet.of(projectId + ""));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* true if the template or its derivatives are extractable; default is true
|
* true if the template or its derivatives are extractable; default is true
|
||||||
*/
|
*/
|
||||||
|
@ -98,6 +106,11 @@ public class RegisterTemplateOptions extends AccountInDomainOptions {
|
||||||
return options.checksum(checksum);
|
return options.checksum(checksum);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static RegisterTemplateOptions projectId(String projectId) {
|
||||||
|
RegisterTemplateOptions options = new RegisterTemplateOptions();
|
||||||
|
return options.projectId(projectId);
|
||||||
|
}
|
||||||
|
|
||||||
public static RegisterTemplateOptions isExtractable(boolean isExtractable) {
|
public static RegisterTemplateOptions isExtractable(boolean isExtractable) {
|
||||||
RegisterTemplateOptions options = new RegisterTemplateOptions();
|
RegisterTemplateOptions options = new RegisterTemplateOptions();
|
||||||
return options.isExtractable(isExtractable);
|
return options.isExtractable(isExtractable);
|
||||||
|
|
|
@ -39,6 +39,14 @@ public class UpdateTemplatePermissionsOptions extends BaseHttpRequestOptions {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* a list of projects. If specified, "op" parameter has to be passed in.
|
||||||
|
*/
|
||||||
|
public UpdateTemplatePermissionsOptions projectIds(Iterable<String> projectIds) {
|
||||||
|
this.queryParameters.replaceValues("projectids", ImmutableSet.of(Joiner.on(',').join(projectIds)));
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* true if the template/iso is extractable, false other wise. Can be set only by root admin
|
* true if the template/iso is extractable, false other wise. Can be set only by root admin
|
||||||
*/
|
*/
|
||||||
|
@ -82,6 +90,11 @@ public class UpdateTemplatePermissionsOptions extends BaseHttpRequestOptions {
|
||||||
return options.accounts(accounts);
|
return options.accounts(accounts);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static UpdateTemplatePermissionsOptions projectIds(Iterable<String> projectIds) {
|
||||||
|
UpdateTemplatePermissionsOptions options = new UpdateTemplatePermissionsOptions();
|
||||||
|
return options.projectIds(projectIds);
|
||||||
|
}
|
||||||
|
|
||||||
public static UpdateTemplatePermissionsOptions isExtractable(boolean isExtractable) {
|
public static UpdateTemplatePermissionsOptions isExtractable(boolean isExtractable) {
|
||||||
UpdateTemplatePermissionsOptions options = new UpdateTemplatePermissionsOptions();
|
UpdateTemplatePermissionsOptions options = new UpdateTemplatePermissionsOptions();
|
||||||
return options.isExtractable(isExtractable);
|
return options.isExtractable(isExtractable);
|
||||||
|
|
Loading…
Reference in New Issue