Commit 19ddb892 by qiuchaofei

1.关系对象添加id

parent 67cd875e
...@@ -579,6 +579,7 @@ public class MetadataServiceImpl implements IMetadataService { ...@@ -579,6 +579,7 @@ public class MetadataServiceImpl implements IMetadataService {
if(edgeMap.containsKey(edgeId)){ if(edgeMap.containsKey(edgeId)){
continue; continue;
} }
edge.setEdgeId(edgeId);
edge.setFromId(longMetaDataMap.get(startLong).getId()); edge.setFromId(longMetaDataMap.get(startLong).getId());
edge.setToId(longMetaDataMap.get(endLong).getId()); edge.setToId(longMetaDataMap.get(endLong).getId());
edge.setType(relationship.type()); edge.setType(relationship.type());
...@@ -670,6 +671,8 @@ public class MetadataServiceImpl implements IMetadataService { ...@@ -670,6 +671,8 @@ public class MetadataServiceImpl implements IMetadataService {
if(edgeMap.containsKey(edgeId)){ if(edgeMap.containsKey(edgeId)){
continue; continue;
} }
edge.setEdgeId(edgeId);
edge.setFromId(longMetaDataMap.get(startLong).getId()); edge.setFromId(longMetaDataMap.get(startLong).getId());
edge.setToId(longMetaDataMap.get(endLong).getId()); edge.setToId(longMetaDataMap.get(endLong).getId());
edge.setType(relationship.type()); edge.setType(relationship.type());
...@@ -704,6 +707,7 @@ public class MetadataServiceImpl implements IMetadataService { ...@@ -704,6 +707,7 @@ public class MetadataServiceImpl implements IMetadataService {
} }
for(Object obj : edgeMap.keySet()){ for(Object obj : edgeMap.keySet()){
Edge edge = edgeMap.get(obj); Edge edge = edgeMap.get(obj);
returnReslult.getEdges().add(edge); returnReslult.getEdges().add(edge);
} }
edgeMap.clear(); edgeMap.clear();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment