|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.tools.ant.ProjectComponent org.apache.tools.ant.Task com.legstar.cixs.gen.ant.AbstractCixsGenerator com.legstar.cixs.jaxws.gen.AbstractCixsJaxwsGenerator com.legstar.cixs.jaxws.gen.Jaxws2CixsGenerator
public class Jaxws2CixsGenerator
This Ant task creates the various Jaxws artifacts needed to implement a Jaxws Web Service that acts as an adapter for a mainframe program. Web service clients can consume this adapter as any other Web Service but internally the adapter use the LegStar transport to call a a mainframe program.
Field Summary | |
---|---|
static String |
DEFAULT_WSDL_PORT_NAME_SUFFIX
Will be appended to service name to form a port name. |
static String |
DEFAULT_WSDL_SERVICE_NAME_SUFFIX
By default the web service name is built from component name and this suffix. |
static String |
DEFAULT_WSDL_TARGET_NAMESPACE_PREFIX
By default the web service namespace is built from component name and this prefix. |
static String |
JAXWS_TO_CIXS_GENERATOR_NAME
This generator name. |
static String |
OPERATION_FAULT_INFO_VLC_TEMPLATE
Velocity template for fault info. |
static String |
OPERATION_FAULT_VLC_TEMPLATE
Velocity template for fault. |
static String |
OPERATION_HOLDER_VLC_TEMPLATE
Velocity template for holder. |
static String |
OPERATION_HOST_PROGRAM_VLC_TEMPLATE
Velocity template for host program bean. |
static String |
OPERATION_PROGRAM_INVOKER_VLC_TEMPLATE
Velocity template for operation invokers. |
static String |
OPERATION_WRAPPER_VLC_TEMPLATE
Velocity template for wrapper. |
static String |
SERVICE_ANT_BUILD_JAR_VLC_TEMPLATE
Velocity template for service ant-build-jar. |
static String |
SERVICE_ANT_BUILD_WAR_VLC_TEMPLATE
Velocity template for service ant-build-war. |
static String |
SERVICE_ANT_DEPLOY_VLC_TEMPLATE
Velocity template for service ant-deploy. |
static String |
SERVICE_HEADER_VLC_TEMPLATE
Velocity template for service header. |
static String |
SERVICE_IMPLEMENTATION_VLC_TEMPLATE
Velocity template for service implementation. |
static String |
SERVICE_INTERFACE_VLC_TEMPLATE
Velocity template for service interface. |
static String |
SERVICE_OBJECTFACTORY_VLC_TEMPLATE
Velocity template for service ObjectFactory.java. |
static String |
SERVICE_PACKAGE_HTML_VLC_TEMPLATE
Velocity template for package html. |
static String |
SERVICE_PACKAGE_INFO_VLC_TEMPLATE
Velocity template for service package-info.java. |
static String |
SERVICE_SUN_JAXWS_XML_VLC_TEMPLATE
Velocity template for service sun-jaxws-xml. |
static String |
SERVICE_WEB_XML_VLC_TEMPLATE
Velocity template for service web-xml. |
Fields inherited from class com.legstar.cixs.jaxws.gen.AbstractCixsJaxwsGenerator |
---|
JAXWS_GENERATOR_NAME |
Fields inherited from class org.apache.tools.ant.Task |
---|
description, location, target, taskName, taskType, wrapper |
Fields inherited from class org.apache.tools.ant.ProjectComponent |
---|
project |
Constructor Summary | |
---|---|
Jaxws2CixsGenerator()
Constructor. |
Method Summary | |
---|---|
void |
addExtendedParameters(Map<String,Object> parameters)
Add common parameters expected by templates to come from a parameters map. |
void |
addWebServiceParameters(WebServiceParameters webServiceParameters)
|
void |
checkExtendedExtendedInput()
Give the inheriting generators a chance to add more controls. |
protected void |
completeModel()
Generate default values where they are missing in the model. |
protected void |
completeWebServiceParameters()
Provide default values to expose this adapter as a Web Service. |
static String |
generateAntBuildJar(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceAntFilesDir)
Create the JAX-WS Ant Build jar file. |
static String |
generateAntBuildWar(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceAntFilesDir)
Create the JAX-WS Ant Build War file. |
static String |
generateAntDeploy(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceAntFilesDir)
Create the deploy Ant Build file. |
void |
generateExtended(Map<String,Object> parameters)
Create more artifacts for a Jboss ESB service. |
static void |
generateFault(CixsOperation operation,
Map<String,Object> parameters,
File operationClassFilesDir)
Create a fault class (Jaxws Exception). |
static void |
generateFaultInfo(CixsOperation operation,
Map<String,Object> parameters,
File operationClassFilesDir)
Create a fault info class. |
static void |
generateHeader(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceClassFilesDir)
Create the Jaxws Header class file. |
static void |
generateHolders(CixsOperation operation,
Map<String,Object> parameters,
File operationClassFilesDir)
Create a holder classes for multi-structures input or output. |
static void |
generateHostProgram(CixsOperation operation,
Map<String,Object> parameters,
File operationClassFilesDir)
Create the host program bean. |
static void |
generateImplementation(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceClassFilesDir)
Create the Jaxws Implementation class file. |
static void |
generateInterface(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceClassFilesDir)
Create the Jaxws Interface class file. |
static String |
generateObjectFactory(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceClassFilesDir)
Create the Jaxb ObjectFctory.java class. |
static void |
generatePackageHtml(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceClassFilesDir)
Create a package level doc. |
static String |
generatePackageInfo(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceClassFilesDir)
Create the Jaxb package-info.java class. |
static void |
generateProgramInvoker(CixsOperation operation,
Map<String,Object> parameters,
File operationClassFilesDir)
Create a program invoker class. |
static void |
generateSunJaxwsXml(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceWebFilesDir)
Create the Jaxws Sun Jaxws Xml file. |
static void |
generateWebXml(CixsJaxwsService service,
Map<String,Object> parameters,
File serviceWebFilesDir)
Create the Jaxws Web Xml file. |
static void |
generateWrappers(CixsOperation operation,
Map<String,Object> parameters,
File operationClassFilesDir)
Create a wrapper class. |
AntBuildJaxws2CixsModel |
getAntModel()
|
String |
getGeneratorName()
|
WebServiceParameters |
getWebServiceParameters()
|
boolean |
isNoPackageInfo()
Prevents generation of package-info.java which does not compile under JDK 1.5. |
void |
setNoPackageInfo(boolean noPackageInfo)
Prevents generation of package-info.java which does not compile under JDK 1.5. |
void |
setWebServiceParameters(WebServiceParameters webServiceParameters)
|
Methods inherited from class com.legstar.cixs.jaxws.gen.AbstractCixsJaxwsGenerator |
---|
add, addCixsJaxwsService, checkExtendedInput, generate, getCixsJaxwsService, getCixsOperations, getTargetWarDir, getTargetWDDDir, getVersion, setCixsJaxwsService, setTargetWarDir, setTargetWDDDir |
Methods inherited from class com.legstar.cixs.gen.ant.AbstractCixsGenerator |
---|
add, addCixsService, execute, generateFile, generateFile, getCixsService, getCoxbBinDir, getCustBinDir, getHostCharset, getJaxbBinDir, getTargetAntDir, getTargetBinDir, getTargetDistDir, getTargetSrcDir, init, setCixsService, setCoxbBinDir, setCustBinDir, setHostCharset, setJaxbBinDir, setTargetAntDir, setTargetBinDir, setTargetDistDir, setTargetSrcDir |
Methods inherited from class org.apache.tools.ant.Task |
---|
getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType |
Methods inherited from class org.apache.tools.ant.ProjectComponent |
---|
getProject, setProject |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String JAXWS_TO_CIXS_GENERATOR_NAME
public static final String SERVICE_INTERFACE_VLC_TEMPLATE
public static final String SERVICE_IMPLEMENTATION_VLC_TEMPLATE
public static final String SERVICE_HEADER_VLC_TEMPLATE
public static final String SERVICE_ANT_BUILD_WAR_VLC_TEMPLATE
public static final String SERVICE_ANT_BUILD_JAR_VLC_TEMPLATE
public static final String SERVICE_ANT_DEPLOY_VLC_TEMPLATE
public static final String SERVICE_SUN_JAXWS_XML_VLC_TEMPLATE
public static final String SERVICE_WEB_XML_VLC_TEMPLATE
public static final String SERVICE_PACKAGE_HTML_VLC_TEMPLATE
public static final String OPERATION_FAULT_VLC_TEMPLATE
public static final String OPERATION_FAULT_INFO_VLC_TEMPLATE
public static final String OPERATION_HOLDER_VLC_TEMPLATE
public static final String OPERATION_HOST_PROGRAM_VLC_TEMPLATE
public static final String OPERATION_WRAPPER_VLC_TEMPLATE
public static final String OPERATION_PROGRAM_INVOKER_VLC_TEMPLATE
public static final String SERVICE_PACKAGE_INFO_VLC_TEMPLATE
public static final String SERVICE_OBJECTFACTORY_VLC_TEMPLATE
public static final String DEFAULT_WSDL_PORT_NAME_SUFFIX
public static final String DEFAULT_WSDL_SERVICE_NAME_SUFFIX
public static final String DEFAULT_WSDL_TARGET_NAMESPACE_PREFIX
Constructor Detail |
---|
public Jaxws2CixsGenerator()
Method Detail |
---|
public void addExtendedParameters(Map<String,Object> parameters)
addExtendedParameters
in class AbstractCixsJaxwsGenerator
parameters
- a parameters map to which parameters must be addedpublic void checkExtendedExtendedInput() throws com.legstar.codegen.CodeGenMakeException
checkExtendedExtendedInput
in class AbstractCixsJaxwsGenerator
com.legstar.codegen.CodeGenMakeException
- if control failspublic void generateExtended(Map<String,Object> parameters) throws com.legstar.codegen.CodeGenMakeException
generateExtended
in class AbstractCixsJaxwsGenerator
parameters
- a predefined set of parameters useful for generation
com.legstar.codegen.CodeGenMakeException
- if generation failsprotected void completeModel()
completeModel
in class AbstractCixsGenerator
protected void completeWebServiceParameters()
public static void generateInterface(CixsJaxwsService service, Map<String,Object> parameters, File serviceClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generatePackageHtml(CixsJaxwsService service, Map<String,Object> parameters, File serviceClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateImplementation(CixsJaxwsService service, Map<String,Object> parameters, File serviceClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateHeader(CixsJaxwsService service, Map<String,Object> parameters, File serviceClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static String generateAntBuildWar(CixsJaxwsService service, Map<String,Object> parameters, File serviceAntFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceAntFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static String generateAntBuildJar(CixsJaxwsService service, Map<String,Object> parameters, File serviceAntFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceAntFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static String generateAntDeploy(CixsJaxwsService service, Map<String,Object> parameters, File serviceAntFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceAntFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateWebXml(CixsJaxwsService service, Map<String,Object> parameters, File serviceWebFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceWebFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateSunJaxwsXml(CixsJaxwsService service, Map<String,Object> parameters, File serviceWebFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceWebFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateFault(CixsOperation operation, Map<String,Object> parameters, File operationClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
operation
- the cixs operationparameters
- miscellaneous help parametersoperationClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateFaultInfo(CixsOperation operation, Map<String,Object> parameters, File operationClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
operation
- the cixs operationparameters
- miscellaneous help parametersoperationClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateWrappers(CixsOperation operation, Map<String,Object> parameters, File operationClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
operation
- the cixs operationparameters
- miscellaneous help parametersoperationClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateHolders(CixsOperation operation, Map<String,Object> parameters, File operationClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
operation
- the cixs operationparameters
- miscellaneous help parametersoperationClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateProgramInvoker(CixsOperation operation, Map<String,Object> parameters, File operationClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
operation
- the cixs operationparameters
- miscellaneous help parametersoperationClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static void generateHostProgram(CixsOperation operation, Map<String,Object> parameters, File operationClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
operation
- the cixs operationparameters
- miscellaneous help parametersoperationClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static String generatePackageInfo(CixsJaxwsService service, Map<String,Object> parameters, File serviceClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic static String generateObjectFactory(CixsJaxwsService service, Map<String,Object> parameters, File serviceClassFilesDir) throws com.legstar.codegen.CodeGenMakeException
service
- the Jaxws service descriptionparameters
- miscellaneous help parametersserviceClassFilesDir
- where to store the generated file
com.legstar.codegen.CodeGenMakeException
- if generation failspublic AntBuildJaxws2CixsModel getAntModel()
getAntModel
in class AbstractCixsJaxwsGenerator
AbstractCixsGenerator.getAntModel()
public String getGeneratorName()
getGeneratorName
in class AbstractCixsGenerator
public WebServiceParameters getWebServiceParameters()
public void setWebServiceParameters(WebServiceParameters webServiceParameters)
webServiceParameters
- the set of parameters needed to expose a Web
Service to setpublic void addWebServiceParameters(WebServiceParameters webServiceParameters)
webServiceParameters
- the set of parameters needed to expose a Web
Service to setpublic boolean isNoPackageInfo()
public void setNoPackageInfo(boolean noPackageInfo)
noPackageInfo
- true if we should not generate package-info.java
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |