org.jclouds.savvis.vpdc.binders
Class BaseBindVMSpecToXmlPayload<T>
java.lang.Object
org.jclouds.rest.binders.BindToStringPayload
org.jclouds.savvis.vpdc.binders.BaseBindVMSpecToXmlPayload<T>
- All Implemented Interfaces:
- Binder, MapBinder
- Direct Known Subclasses:
- BindVMSpecsToXmlPayload, BindVMSpecToXmlPayload
public abstract class BaseBindVMSpecToXmlPayload<T>
- extends BindToStringPayload
- implements MapBinder
- Author:
- Adrian Cole
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BaseBindVMSpecToXmlPayload
public BaseBindVMSpecToXmlPayload()
bindToRequest
public <R extends HttpRequest> R bindToRequest(R request,
Object toBind)
- Specified by:
bindToRequest
in interface Binder
- Overrides:
bindToRequest
in class BindToStringPayload
findSpecInArgsOrNull
protected abstract T findSpecInArgsOrNull(GeneratedHttpRequest<?> gRequest)
bindToRequest
public <R extends HttpRequest> R bindToRequest(R request,
Map<String,String> postParams)
- Description copied from interface:
MapBinder
- creates and binds the POST payload to the request using parameters specified.
- Specified by:
bindToRequest
in interface MapBinder
- See Also:
PayloadParam
generateXml
public String generateXml(T spec)
bindSpec
protected abstract void bindSpec(T spec,
com.jamesmurty.utils.XMLBuilder rootBuilder)
throws ParserConfigurationException,
FactoryConfigurationError
- Throws:
ParserConfigurationException
FactoryConfigurationError
checkSpec
protected void checkSpec(VMSpec spec)
addOperatingSystemAndVirtualHardware
protected void addOperatingSystemAndVirtualHardware(VMSpec spec,
com.jamesmurty.utils.XMLBuilder vAppBuilder)
buildRoot
protected com.jamesmurty.utils.XMLBuilder buildRoot()
throws ParserConfigurationException,
FactoryConfigurationError
- Throws:
ParserConfigurationException
FactoryConfigurationError
buildChildren
protected com.jamesmurty.utils.XMLBuilder buildChildren(com.jamesmurty.utils.XMLBuilder rootBuilder)
throws ParserConfigurationException,
FactoryConfigurationError
- Throws:
ParserConfigurationException
FactoryConfigurationError
buildRootForName
protected com.jamesmurty.utils.XMLBuilder buildRootForName(com.jamesmurty.utils.XMLBuilder rootBuilder,
String name)
throws ParserConfigurationException,
FactoryConfigurationError
- Throws:
ParserConfigurationException
FactoryConfigurationError
ifNullDefaultTo
protected String ifNullDefaultTo(String value,
String defaultValue)
Copyright © 2009-2011 jclouds. All Rights Reserved.