You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by ff...@apache.org on 2019/06/11 14:24:06 UTC
[cxf] 01/02: CXF-8052: Cannot set JAXB schema compiler options
This is an automated email from the ASF dual-hosted git repository.
ffang pushed a commit to branch 3.2.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git
commit e8dac490d67bf5bfe3ee01d5ce115543771a1c69
Author: Ranjit Vadakkan <ra...@hexagon.com>
AuthorDate: Fri May 31 09:15:10 2019 -0400
CXF-8052: Cannot set JAXB schema compiler options
(cherry picked from commit fed13f51c8537c0e39b3ae984bd9ec1ca2fe9a47)
---
.../org/apache/cxf/endpoint/dynamic/DynamicClientFactory.java | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/rt/frontend/simple/src/main/java/org/apache/cxf/endpoint/dynamic/DynamicClientFactory.java b/rt/frontend/simple/src/main/java/org/apache/cxf/endpoint/dynamic/DynamicClientFactory.java
index e21d362..473d40d 100644
--- a/rt/frontend/simple/src/main/java/org/apache/cxf/endpoint/dynamic/DynamicClientFactory.java
+++ b/rt/frontend/simple/src/main/java/org/apache/cxf/endpoint/dynamic/DynamicClientFactory.java
@@ -337,6 +337,7 @@ public class DynamicClientFactory {
addSchemas(compiler.getOptions(), compiler, svc.getServiceInfos(), schemas);
addBindingFiles(bindingFiles, compiler);
+ applySchemaCompilerOptions();
S2JJAXBModel intermediateModel = compiler.bind();
listener.throwException();
@@ -442,12 +443,13 @@ public class DynamicClientFactory {
}
protected SchemaCompiler createSchemaCompiler() {
- SchemaCompiler compiler =
- JAXBUtils.createSchemaCompilerWithDefaultAllocator(new HashSet<>());
+ return JAXBUtils.createSchemaCompilerWithDefaultAllocator(new HashSet<>());
+ }
+
+ protected void applySchemaCompilerOptions() {
if (schemaCompilerOptions != null && schemaCompilerOptions.length > 0) {
compiler.getOptions().parseArguments(schemaCompilerOptions);
}
- return compiler;
}
private void addBindingFiles(List<String> bindingFiles, SchemaCompiler compiler) {