Class PluginImpl
- java.lang.Object
-
- com.sun.tools.ws.wscompile.Plugin
-
- com.sun.tools.ws.wscompile.plugin.at_generated.PluginImpl
-
-
Constructor Summary
Constructors Constructor Description PluginImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetOptionName()Gets the option name to turn on this add-on.StringgetUsage()Gets the description of this add-on.booleanrun(Model model, WsimportOptions wo, ErrorReceiver er)Run the add-on.-
Methods inherited from class com.sun.tools.ws.wscompile.Plugin
onActivated, parseArgument
-
-
-
-
Method Detail
-
getOptionName
public String getOptionName()
Description copied from class:PluginGets the option name to turn on this add-on.For example, if "abc" is returned, "-abc" will turn on this plugin. A plugin needs to be turned on explicitly, or else no other methods of
Pluginwill be invoked.When an option matches the name returned from this method, WsImport will then invoke
Plugin.parseArgument(Options, String[], int), allowing plugins to handle arguments to this option.- Specified by:
getOptionNamein classPlugin
-
getUsage
public String getUsage()
Description copied from class:PluginGets the description of this add-on. Used to generate a usage screen.
-
run
public boolean run(Model model, WsimportOptions wo, ErrorReceiver er) throws SAXException
Description copied from class:PluginRun the add-on.This method is invoked after WsImport has internally finished the code generation. Plugins can tweak some of the generated code (or add more code) by altering
JCodeModelobtained fromWsimportOptions.getCodeModel()according to the currentWSDL modelandWsimportOptions.Note that this method is invoked only when a
Pluginis activated.- Specified by:
runin classPlugin- Parameters:
model- This object allows access to the WSDL model used for code generation.wo- This object allows access to various options used for code generation as well as access to the generated code.er- Errors should be reported to this handler.- Returns:
- If the add-on executes successfully, return true. If it detects some errors but those are reported and recovered gracefully, return false.
- Throws:
SAXException- After an error is reported toErrorReceiver, the same exception can be thrown to indicate a fatal irrecoverable error.ErrorReceiveritself may throw it, if it chooses not to recover from the error.
-
-