final String moduleName = module.getName();
for (final RpcDefinition rpc : rpcs) {
final ContainerSchemaNode input = rpc.getInput();
- if (!input.getChildNodes().isEmpty()) {
+ if (input !=null && input.getChildNodes() != null &&
+ !input.getChildNodes().isEmpty()) {
final JSONObject properties = processChildren(input.getChildNodes(), moduleName, models, true, schemaContext);
final String filename = "(" + rpc.getQName().getLocalName() + ")input";
}
final ContainerSchemaNode output = rpc.getOutput();
- if (!output.getChildNodes().isEmpty()) {
+ if (output !=null && output.getChildNodes() != null &&
+ !output.getChildNodes().isEmpty()) {
final JSONObject properties = processChildren(output.getChildNodes(), moduleName, models, true, schemaContext);
final String filename = "(" + rpc.getQName().getLocalName() + ")output";
final JSONObject childSchema = getSchemaTemplate();
return schemaJSON;
}
-}
\ No newline at end of file
+}