public class ServiceStub extends com.vmware.vapi.internal.bindings.Stub implements Service
Service
API service.
WARNING: Internal class, subject to change in future versions.
ServiceTypes.Health, ServiceTypes.Info, ServiceTypes.StartupType, ServiceTypes.State, ServiceTypes.UpdateSpec
apiProvider, converter, ifaceId, retryPolicy, securityContext
_VAPI_SERVICE_ID
Constructor and Description |
---|
ServiceStub(ApiProvider apiProvider,
StubConfigurationBase config) |
ServiceStub(ApiProvider apiProvider,
com.vmware.vapi.internal.bindings.TypeConverter typeConverter,
StubConfigurationBase config) |
Modifier and Type | Method and Description |
---|---|
ServiceTypes.Info |
get(java.lang.String service)
Returns the state of a service.
|
void |
get(java.lang.String service,
AsyncCallback<ServiceTypes.Info> asyncCallback)
Returns the state of a service.
|
void |
get(java.lang.String service,
AsyncCallback<ServiceTypes.Info> asyncCallback,
InvocationConfig invocationConfig)
Returns the state of a service.
|
ServiceTypes.Info |
get(java.lang.String service,
InvocationConfig invocationConfig)
Returns the state of a service.
|
java.util.Map<java.lang.String,ServiceTypes.Info> |
listDetails()
Lists details of vCenter services.
|
void |
listDetails(AsyncCallback<java.util.Map<java.lang.String,ServiceTypes.Info>> asyncCallback)
Lists details of vCenter services.
|
void |
listDetails(AsyncCallback<java.util.Map<java.lang.String,ServiceTypes.Info>> asyncCallback,
InvocationConfig invocationConfig)
Lists details of vCenter services.
|
java.util.Map<java.lang.String,ServiceTypes.Info> |
listDetails(InvocationConfig invocationConfig)
Lists details of vCenter services.
|
void |
restart(java.lang.String service)
Restarts a service.
|
void |
restart(java.lang.String service,
AsyncCallback<java.lang.Void> asyncCallback)
Restarts a service.
|
void |
restart(java.lang.String service,
AsyncCallback<java.lang.Void> asyncCallback,
InvocationConfig invocationConfig)
Restarts a service.
|
void |
restart(java.lang.String service,
InvocationConfig invocationConfig)
Restarts a service.
|
void |
start(java.lang.String service)
Starts a service.
|
void |
start(java.lang.String service,
AsyncCallback<java.lang.Void> asyncCallback)
Starts a service.
|
void |
start(java.lang.String service,
AsyncCallback<java.lang.Void> asyncCallback,
InvocationConfig invocationConfig)
Starts a service.
|
void |
start(java.lang.String service,
InvocationConfig invocationConfig)
Starts a service.
|
void |
stop(java.lang.String service)
Stops a service.
|
void |
stop(java.lang.String service,
AsyncCallback<java.lang.Void> asyncCallback)
Stops a service.
|
void |
stop(java.lang.String service,
AsyncCallback<java.lang.Void> asyncCallback,
InvocationConfig invocationConfig)
Stops a service.
|
void |
stop(java.lang.String service,
InvocationConfig invocationConfig)
Stops a service.
|
void |
update(java.lang.String service,
ServiceTypes.UpdateSpec spec)
Updates the properties of a service.
|
void |
update(java.lang.String service,
ServiceTypes.UpdateSpec spec,
AsyncCallback<java.lang.Void> asyncCallback)
Updates the properties of a service.
|
void |
update(java.lang.String service,
ServiceTypes.UpdateSpec spec,
AsyncCallback<java.lang.Void> asyncCallback,
InvocationConfig invocationConfig)
Updates the properties of a service.
|
void |
update(java.lang.String service,
ServiceTypes.UpdateSpec spec,
InvocationConfig invocationConfig)
Updates the properties of a service.
|
public ServiceStub(ApiProvider apiProvider, com.vmware.vapi.internal.bindings.TypeConverter typeConverter, StubConfigurationBase config)
public ServiceStub(ApiProvider apiProvider, StubConfigurationBase config)
public void start(java.lang.String service)
Service
Synchronous method overload. Result of the invocation will be reported as a method return value.
service
- identifier of the service to start
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.public void start(java.lang.String service, InvocationConfig invocationConfig)
Service
Synchronous method overload. Result of the invocation will be
reported as a method return value.
Use invocationConfig
to specify configuration for this particular invocation.
service
- identifier of the service to start
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.invocationConfig
- Configuration for the method invocation.public void start(java.lang.String service, AsyncCallback<java.lang.Void> asyncCallback)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a stop or
restart operation is in progress, the start operation will not be allowed.
NotAllowedInCurrentState
- if start operation is issued on a service which has startup type ServiceTypes.StartupType.DISABLED
.
TimedOut
- if any timeout occurs during the execution of the start operation. Timeout
occurs when the service takes longer than StartTimeout to start.
Error
- if any other error occurs during the execution of the operation.
service
- identifier of the service to start
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.public void start(java.lang.String service, AsyncCallback<java.lang.Void> asyncCallback, InvocationConfig invocationConfig)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Use invocationConfig
to specify configuration for this particular invocation.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a stop or
restart operation is in progress, the start operation will not be allowed.
NotAllowedInCurrentState
- if start operation is issued on a service which has startup type ServiceTypes.StartupType.DISABLED
.
TimedOut
- if any timeout occurs during the execution of the start operation. Timeout
occurs when the service takes longer than StartTimeout to start.
Error
- if any other error occurs during the execution of the operation.
service
- identifier of the service to start
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.invocationConfig
- Configuration for the method invocation.public void stop(java.lang.String service)
Service
Synchronous method overload. Result of the invocation will be reported as a method return value.
service
- identifier of the service to stop
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.public void stop(java.lang.String service, InvocationConfig invocationConfig)
Service
Synchronous method overload. Result of the invocation will be
reported as a method return value.
Use invocationConfig
to specify configuration for this particular invocation.
service
- identifier of the service to stop
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.invocationConfig
- Configuration for the method invocation.public void stop(java.lang.String service, AsyncCallback<java.lang.Void> asyncCallback)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
Error
- if any other error occurs during the execution of the operation.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a stop
operation is in progress, issuing another stop operation will lead to this
error.
service
- identifier of the service to stop
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.public void stop(java.lang.String service, AsyncCallback<java.lang.Void> asyncCallback, InvocationConfig invocationConfig)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Use invocationConfig
to specify configuration for this particular invocation.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
Error
- if any other error occurs during the execution of the operation.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a stop
operation is in progress, issuing another stop operation will lead to this
error.
service
- identifier of the service to stop
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.invocationConfig
- Configuration for the method invocation.public void restart(java.lang.String service)
Service
Synchronous method overload. Result of the invocation will be reported as a method return value.
service
- identifier of the service to restart
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.public void restart(java.lang.String service, InvocationConfig invocationConfig)
Service
Synchronous method overload. Result of the invocation will be
reported as a method return value.
Use invocationConfig
to specify configuration for this particular invocation.
service
- identifier of the service to restart
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.invocationConfig
- Configuration for the method invocation.public void restart(java.lang.String service, AsyncCallback<java.lang.Void> asyncCallback)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
TimedOut
- if any timeout occurs during the execution of the restart operation.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a stop or
start operation is in progress, issuing a restart operation will lead to this
error.
NotAllowedInCurrentState
- if a restart operation is issued on a service which has startup type ServiceTypes.StartupType.DISABLED
Error
- if any other error occurs during the execution of the operation.
service
- identifier of the service to restart
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.public void restart(java.lang.String service, AsyncCallback<java.lang.Void> asyncCallback, InvocationConfig invocationConfig)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Use invocationConfig
to specify configuration for this particular invocation.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
TimedOut
- if any timeout occurs during the execution of the restart operation.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a stop or
start operation is in progress, issuing a restart operation will lead to this
error.
NotAllowedInCurrentState
- if a restart operation is issued on a service which has startup type ServiceTypes.StartupType.DISABLED
Error
- if any other error occurs during the execution of the operation.
service
- identifier of the service to restart
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.invocationConfig
- Configuration for the method invocation.public ServiceTypes.Info get(java.lang.String service)
Service
Synchronous method overload. Result of the invocation will be reported as a method return value.
service
- identifier of the service whose state is being queried.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.public ServiceTypes.Info get(java.lang.String service, InvocationConfig invocationConfig)
Service
Synchronous method overload. Result of the invocation will be
reported as a method return value.
Use invocationConfig
to specify configuration for this particular invocation.
service
- identifier of the service whose state is being queried.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.invocationConfig
- Configuration for the method invocation.public void get(java.lang.String service, AsyncCallback<ServiceTypes.Info> asyncCallback)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Invocation Result:
Service Info structure.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
Error
- if any other error occurs during the execution of the operation.
service
- identifier of the service whose state is being queried.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.public void get(java.lang.String service, AsyncCallback<ServiceTypes.Info> asyncCallback, InvocationConfig invocationConfig)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Use invocationConfig
to specify configuration for this particular invocation.
Invocation Result:
Service Info structure.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
Error
- if any other error occurs during the execution of the operation.
service
- identifier of the service whose state is being queried.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.invocationConfig
- Configuration for the method invocation.public void update(java.lang.String service, ServiceTypes.UpdateSpec spec)
Service
Synchronous method overload. Result of the invocation will be reported as a method return value.
service
- identifier of the service whose properties are being updated.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.spec
- Service Update specification.public void update(java.lang.String service, ServiceTypes.UpdateSpec spec, InvocationConfig invocationConfig)
Service
Synchronous method overload. Result of the invocation will be
reported as a method return value.
Use invocationConfig
to specify configuration for this particular invocation.
service
- identifier of the service whose properties are being updated.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.spec
- Service Update specification.invocationConfig
- Configuration for the method invocation.public void update(java.lang.String service, ServiceTypes.UpdateSpec spec, AsyncCallback<java.lang.Void> asyncCallback)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
Error
- if any other error occurs during the execution of the operation.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a start, stop
or restart operation is in progress, update operation will fail with this error.
NotAllowedInCurrentState
- if a request to set the ServiceTypes.UpdateSpec.getStartupType()
property of
spec
to ServiceTypes.StartupType.DISABLED
comes in for a
service that is not in ServiceTypes.State.STOPPED
state.
service
- identifier of the service whose properties are being updated.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.spec
- Service Update specification.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.public void update(java.lang.String service, ServiceTypes.UpdateSpec spec, AsyncCallback<java.lang.Void> asyncCallback, InvocationConfig invocationConfig)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Use invocationConfig
to specify configuration for this particular invocation.
Operation Errors:
NotFound
- if the service associated with service
does not exist.
Error
- if any other error occurs during the execution of the operation.
NotAllowedInCurrentState
- if the operation is denied in the current state of the service. If a start, stop
or restart operation is in progress, update operation will fail with this error.
NotAllowedInCurrentState
- if a request to set the ServiceTypes.UpdateSpec.getStartupType()
property of
spec
to ServiceTypes.StartupType.DISABLED
comes in for a
service that is not in ServiceTypes.State.STOPPED
state.
service
- identifier of the service whose properties are being updated.
The parameter must be an identifier for the resource type: com.vmware.vcenter.services.Service
.spec
- Service Update specification.asyncCallback
- Receives the status (progress, result or error) of the operation invocation.invocationConfig
- Configuration for the method invocation.public java.util.Map<java.lang.String,ServiceTypes.Info> listDetails()
Service
Synchronous method overload. Result of the invocation will be reported as a method return value.
Map
will be an identifier for the
resource type: com.vmware.vcenter.services.Service
.public java.util.Map<java.lang.String,ServiceTypes.Info> listDetails(InvocationConfig invocationConfig)
Service
Synchronous method overload. Result of the invocation will be
reported as a method return value.
Use invocationConfig
to specify configuration for this particular invocation.
invocationConfig
- Configuration for the method invocation.Map
will be an identifier for the
resource type: com.vmware.vcenter.services.Service
.public void listDetails(AsyncCallback<java.util.Map<java.lang.String,ServiceTypes.Info>> asyncCallback)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Invocation Result:
Map of service identifiers to service Info structures.
The key in the return value Map
will be an identifier for the
resource type: com.vmware.vcenter.services.Service
.
Operation Errors:
Error
- if any error occurs during the execution of the operation.
asyncCallback
- Receives the status (progress, result or error) of the operation invocation.public void listDetails(AsyncCallback<java.util.Map<java.lang.String,ServiceTypes.Info>> asyncCallback, InvocationConfig invocationConfig)
Service
Asynchronous method overload. Result of the invocation will be
reported via the specified asyncCallback
.
Use invocationConfig
to specify configuration for this particular invocation.
Invocation Result:
Map of service identifiers to service Info structures.
The key in the return value Map
will be an identifier for the
resource type: com.vmware.vcenter.services.Service
.
Operation Errors:
Error
- if any error occurs during the execution of the operation.
asyncCallback
- Receives the status (progress, result or error) of the operation invocation.invocationConfig
- Configuration for the method invocation.