use of org.kie.dmn.model.api.KnowledgeSource in project drools by kiegroup.
the class KnowledgeSourceConverter method writeChildren.
@Override
protected void writeChildren(HierarchicalStreamWriter writer, MarshallingContext context, Object parent) {
super.writeChildren(writer, context, parent);
KnowledgeSource ks = (KnowledgeSource) parent;
for (AuthorityRequirement ar : ks.getAuthorityRequirement()) {
writeChildrenNode(writer, context, ar, AUTHORITY_REQUIREMENT);
}
if (ks.getType() != null)
writeChildrenNode(writer, context, ks.getType(), TYPE);
if (ks.getOwner() != null)
writeChildrenNode(writer, context, ks.getOwner(), OWNER);
}
use of org.kie.dmn.model.api.KnowledgeSource in project drools by kiegroup.
the class KnowledgeSourceConverter method writeChildren.
@Override
protected void writeChildren(HierarchicalStreamWriter writer, MarshallingContext context, Object parent) {
super.writeChildren(writer, context, parent);
KnowledgeSource ks = (KnowledgeSource) parent;
for (AuthorityRequirement ar : ks.getAuthorityRequirement()) {
writeChildrenNode(writer, context, ar, AUTHORITY_REQUIREMENT);
}
if (ks.getType() != null)
writeChildrenNode(writer, context, ks.getType(), TYPE);
if (ks.getOwner() != null)
writeChildrenNode(writer, context, ks.getOwner(), OWNER);
}
use of org.kie.dmn.model.api.KnowledgeSource in project drools by kiegroup.
the class KnowledgeSourceConverter method writeAttributes.
@Override
protected void writeAttributes(HierarchicalStreamWriter writer, Object parent) {
super.writeAttributes(writer, parent);
KnowledgeSource ks = (KnowledgeSource) parent;
if (ks.getLocationURI() != null)
writer.addAttribute(LOCATION_URI, ks.getLocationURI());
}
use of org.kie.dmn.model.api.KnowledgeSource in project drools by kiegroup.
the class KnowledgeSourceConverter method writeChildren.
@Override
protected void writeChildren(HierarchicalStreamWriter writer, MarshallingContext context, Object parent) {
super.writeChildren(writer, context, parent);
KnowledgeSource ks = (KnowledgeSource) parent;
for (AuthorityRequirement ar : ks.getAuthorityRequirement()) {
writeChildrenNode(writer, context, ar, AUTHORITY_REQUIREMENT);
}
if (ks.getType() != null)
writeChildrenNode(writer, context, ks.getType(), TYPE);
if (ks.getOwner() != null)
writeChildrenNode(writer, context, ks.getOwner(), OWNER);
}
use of org.kie.dmn.model.api.KnowledgeSource in project drools by kiegroup.
the class KnowledgeSourceConverter method assignAttributes.
@Override
protected void assignAttributes(HierarchicalStreamReader reader, Object parent) {
super.assignAttributes(reader, parent);
KnowledgeSource ks = (KnowledgeSource) parent;
String locationUri = reader.getAttribute(LOCATION_URI);
ks.setLocationURI(locationUri);
}
Aggregations