Retrieve the Service
Content in Java
The following example shows the call to
retrieveServiceContent
.
Call
retrieveServiceContent
// Step 2 Retrieve the service content Map<String, Object> ctxt = ((BindingProvider) vimPort).getRequestContext(); ctxt.put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, vcServerUrl); ctxt.put(BindingProvider.SESSION_MAINTAIN_PROPERTY, false); ManagedObjectReference SVC_INST_REF = new ManagedObjectReference(); SVC_INST_REF.setType("ServiceInstance"); SVC_INST_REF.setValue("ServiceInstance"); ServiceContent serviceContent = vimPort.retrieveServiceContent(SVC_INST_REF);