else writeLabel(writer, l.getLabel()); if (l instanceof DataPropertyOfColumnLink) writer.name("hNodeId").value( ((DataPropertyOfColumnLink)l).getSpecializedColumnHNodeId()); if (l instanceof ObjectPropertyLink) writer.name("objectPropertyType").value( ((ObjectPropertyLink)l).getObjectPropertyType().toString());
private LabeledLink getSpecializationLinkIfExists(LabeledLink link, Node sourceNode) { Set<LabeledLink> outgoingEdges = this.alignmentGraph.outgoingEdgesOf(sourceNode); for (LabeledLink olink:outgoingEdges) { // Check for the object property specialization if (olink instanceof ObjectPropertySpecializationLink ) { String splLinkId = ((ObjectPropertySpecializationLink) olink).getSpecializedLinkId(); if (splLinkId.equals(link.getId())) return olink; } // Check for the data property specialization else if (olink instanceof DataPropertyOfColumnLink) { DataPropertyOfColumnLink dlink = (DataPropertyOfColumnLink) olink; Node target = link.getTarget(); if (target instanceof ColumnNode) { ColumnNode cnode = (ColumnNode) target; if (dlink.getSpecializedColumnHNodeId().equals(cnode.getId())) return dlink; } } } return null; }
DataPropertyOfColumnLink dpLink = (DataPropertyOfColumnLink) link; String startHNodeId = dpLink .getSpecializedColumnHNodeId();
else if (this instanceof DataPropertyOfColumnLink) newLink = new DataPropertyOfColumnLink(newId, ((DataPropertyOfColumnLink)this).getSpecializedColumnHNodeId(), ((DataPropertyOfColumnLink)this).getSpecializedLinkId() );
else if (e instanceof DataPropertyOfColumnLink) link = new DataPropertyOfColumnLink(id, ((DataPropertyOfColumnLink)e).getSpecializedColumnHNodeId(), ((DataPropertyOfColumnLink)e).getSpecializedLinkId() );