本文整理汇总了Java中com.sun.tools.internal.ws.wscompile.ErrorReceiver类的典型用法代码示例。如果您正苦于以下问题:Java ErrorReceiver类的具体用法?Java ErrorReceiver怎么用?Java ErrorReceiver使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ErrorReceiver类属于com.sun.tools.internal.ws.wscompile包,在下文中一共展示了ErrorReceiver类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public void init(Model model, WsimportOptions options, ErrorReceiver receiver, TJavaGeneratorExtension... extensions) {
init(model, options, receiver);
extensionHandlers = new ArrayList<TJavaGeneratorExtension>();
// register handlers for default extensions
// 2.2 Spec requires generation of @Action when wsam:Action is explicitly stated in wsdl
if (options.target.isLaterThan(Options.Target.V2_2)) {
register(new W3CAddressingJavaGeneratorExtension());
}
for (TJavaGeneratorExtension j : extensions) {
register(j);
}
this.extension = new JavaGeneratorExtensionFacade(extensionHandlers.toArray(new TJavaGeneratorExtension[extensionHandlers.size()]));
}
示例2: DOMForest
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public DOMForest(InternalizationLogic logic, @NotNull EntityResolver entityResolver, WsimportOptions options, ErrorReceiver errReceiver) {
this.options = options;
this.entityResolver = entityResolver;
this.errorReceiver = errReceiver;
this.logic = logic;
try {
// secure xml processing can be switched off if input requires it
boolean secureProcessingEnabled = options == null || !options.disableXmlSecurity;
DocumentBuilderFactory dbf = XmlUtil.newDocumentBuilderFactory(secureProcessingEnabled);
dbf.setNamespaceAware(true);
this.documentBuilder = dbf.newDocumentBuilder();
this.parserFactory = XmlUtil.newSAXParserFactory(secureProcessingEnabled);
this.parserFactory.setNamespaceAware(true);
} catch (ParserConfigurationException e) {
throw new AssertionError(e);
}
}
示例3: DOMForest
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public DOMForest(InternalizationLogic logic, @NotNull EntityResolver entityResolver, WsimportOptions options, ErrorReceiver errReceiver) {
this.options = options;
this.entityResolver = entityResolver;
this.errorReceiver = errReceiver;
this.logic = logic;
// secure xml processing can be switched off if input requires it
boolean disableXmlSecurity = options == null ? false : options.disableXmlSecurity;
DocumentBuilderFactory dbf = XmlUtil.newDocumentBuilderFactory(disableXmlSecurity);
this.parserFactory = XmlUtil.newSAXParserFactory(disableXmlSecurity);
try {
this.documentBuilder = dbf.newDocumentBuilder();
} catch (ParserConfigurationException e) {
throw new AssertionError(e);
}
}
示例4: SeiGenerator
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
private SeiGenerator(Model model, WsimportOptions options, ErrorReceiver receiver, TJavaGeneratorExtension... extensions) {
super(model, options, receiver);
extensionHandlers = new ArrayList<TJavaGeneratorExtension>();
// register handlers for default extensions
// 2.2 Spec requires generation of @Action when wsam:Action is explicitly stated in wsdl
if (options.target.isLaterThan(Options.Target.V2_2)) {
register(new W3CAddressingJavaGeneratorExtension());
}
for (TJavaGeneratorExtension j : extensions)
register(j);
this.extension = new JavaGeneratorExtensionFacade(extensionHandlers.toArray(new TJavaGeneratorExtension[0]));
}
示例5: DOMForest
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public DOMForest(InternalizationLogic logic, @NotNull EntityResolver entityResolver, WsimportOptions options, ErrorReceiver errReceiver) {
this.options = options;
this.entityResolver = entityResolver;
this.errorReceiver = errReceiver;
this.logic = logic;
try {
DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
dbf.setNamespaceAware(true);
this.documentBuilder = dbf.newDocumentBuilder();
this.parserFactory = SAXParserFactory.newInstance();
this.parserFactory.setNamespaceAware(true);
} catch (ParserConfigurationException e) {
throw new AssertionError(e);
}
}
示例6: generate
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public static void generate(Model model,
WsimportOptions options,
ErrorReceiver receiver){
CustomExceptionGenerator exceptionGen = new CustomExceptionGenerator();
exceptionGen.init(model, options, receiver);
exceptionGen.doGeneration();
}
示例7: generate
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public static List<String> generate(Model model, WsimportOptions options,
ErrorReceiver receiver) {
// options check
// Generate it according the implDestDir option
if (options.implDestDir == null)
return null;
JwsImplGenerator jwsImplGenerator = new JwsImplGenerator();
jwsImplGenerator.init(model, options, receiver);
jwsImplGenerator.doGeneration();
// print a warning message while implFiles.size() is zero
if (jwsImplGenerator.implFiles.isEmpty()) {
StringBuilder msg = new StringBuilder();
if (options.implServiceName != null)
msg.append("serviceName=[").append(options.implServiceName).append("] ");
if (options.implPortName != null)
msg.append("portName=[").append(options.implPortName).append("] ");
if (msg.length() > 0)
msg.append(", Not found in wsdl file.\n");
msg.append("No impl files generated!");
receiver.warning(null, msg.toString());
}
return jwsImplGenerator.implFiles;
}
示例8: init
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public void init(Model model, WsimportOptions options, ErrorReceiver receiver){
this.model = model;
this.options = options;
this.destDir = options.destDir;
this.receiver = receiver;
this.wsdlLocation = options.wsdlLocation;
this.targetVersion = options.target.getVersion();
this.cm = options.getCodeModel();
}
示例9: JAXBModelBuilder
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public JAXBModelBuilder(WsimportOptions options, ClassNameCollector classNameCollector, MetadataFinder finder, ErrorReceiver errReceiver) {
this._classNameAllocator = new ClassNameAllocatorImpl(classNameCollector);
this.errReceiver = errReceiver;
this.options = options;
this.forest = finder;
internalBuildJAXBModel();
}
示例10: run
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
@Override
public boolean run(Model model, WsimportOptions wo, ErrorReceiver er) throws SAXException {
JCodeModel cm = wo.getCodeModel();
// we want this to work without requiring JSR-250 jar.
annotation = cm.ref("javax.annotation.Generated");
for (Iterator<JPackage> i = cm.packages(); i.hasNext();) {
for (Iterator<JDefinedClass> j = i.next().classes(); j.hasNext();) {
annotate(j.next());
}
}
return true;
}
示例11: AbstractDocument
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
protected AbstractDocument(MetadataFinder forest, ErrorReceiver errReceiver) {
this.forest = forest;
this.errReceiver = errReceiver;
kinds = new HashMap();
importedEntities = new ArrayList();
importedDocuments = new HashSet();
includedEntities = new ArrayList();
includedDocuments = new HashSet();
}
示例12: TWSDLParserContextImpl
import com.sun.tools.internal.ws.wscompile.ErrorReceiver; //导入依赖的package包/类
public TWSDLParserContextImpl(DOMForest forest, AbstractDocument doc, ArrayList<ParserListener> listeners, ErrorReceiver errReceiver) {
this._document = doc;
this._listeners = listeners;
this._nsSupport = new NamespaceSupport();
this._wsdlLocation = new WSDLLocation();
this.forest = forest;
this.errorReceiver = errReceiver;
}