Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
tviegut committed Oct 24, 2024
1 parent 2f9abb7 commit 8fb95c0
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions CIMUtil/src/au/com/langdale/xmi/EAPParser.java
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ protected void gatherPackageIDs() throws EAProjectParserException {
if (row.getName().equals("Model"))
subject = top;
else
subject = createIndividual(row.getPackageEAGUID(), row.getName(), UML.Package);
subject = createIndividual(row.getXUID(), row.getName(), UML.Package);
packageIDs.putID(row.getPackageID(), subject);
}
}
Expand Down Expand Up @@ -190,7 +190,7 @@ protected void parseClasses() throws EAProjectParserException {
while (it.hasNext()) {
Row row = new Row(it.next());
if (row.getObjectType().equals("Class")) {
OntResource subject = createClass(row.getEAGUID(), row.getName());
OntResource subject = createClass(row.getXUID(), row.getName());
objectIDs.putID(row.getObjectID(), subject);
annotate(subject, row.getNote());
OntResource parent = packageIDs.getID(row.getPackageID());
Expand All @@ -209,7 +209,7 @@ protected void parseAttributes() throws EAProjectParserException {
Row row = new Row(it.next());
OntResource id = objectIDs.getID(row.getObjectID());
if (id != null) {
OntResource subject = createAttributeProperty(row.getEAGUID(), row.getName());
OntResource subject = createAttributeProperty(row.getXUID(), row.getName());
subject.addDomain(id);
annotate(subject, row.getNotes());
subject.addIsDefinedBy(id.getIsDefinedBy());
Expand Down Expand Up @@ -246,7 +246,7 @@ protected void parseAssociations() throws EAProjectParserException {
source.addSuperClass(destin);
} else {
Role roleA = extractProperty( //
row.getEAGUID(), //
row.getXUID(), //
source, //
destin, //
row.getDestRole(), //
Expand All @@ -256,7 +256,7 @@ protected void parseAssociations() throws EAProjectParserException {
true, //
row.getConnectorID());
Role roleB = extractProperty( //
row.getEAGUID(), //
row.getXUID(), //
destin, //
source, //
row.getSourceRole(), //
Expand Down Expand Up @@ -409,14 +409,14 @@ int getID() {
return getInt(COL_ID);
}

String getPackageEAGUID() {
String xuid = fields.get(COL_ea_guid).toString();
return "EAPK_" + xuid.substring(1, xuid.length() - 1).replace("-", "_");
}

String getEAGUID() {
String eaGUID = fields.get(COL_ea_guid).toString();
return eaGUID;
}

String getXUID() {
String xuid = fields.get(COL_ea_guid).toString();
return "EAID_" + xuid.substring(1, xuid.length() - 1).replace("-", "_");
return "_" + xuid.substring(1, xuid.length() - 1);
}

public String getClient() {
Expand Down

0 comments on commit 8fb95c0

Please sign in to comment.