sparqlGraphLibrary/src/main/java/com/ge/research/semtk/belmont/NodeGroup.java
public void addJson(JSONArray nodeArr, OntologyInfo uncompressOInfo) throws Exception  {
		this.oInfo = uncompressOInfo;
		for (int j = 0; j < nodeArr.size(); ++j) {
			JSONObject nodeJson = (JSONObject) nodeArr.get(j);
			
			Node curr  = new Node(nodeJson, this, uncompressOInfo);
			Node check = this.getNodeBySparqlID(curr.getSparqlID());
			
			// create nodes we have never seen
			if(check == null){
				this.addOneNode(curr, null, null, null, false);
			}
			// modify the existing node:
			else{

				// if the node is in both the nodesList and orphan list, modify it. 
				check = null;
				for(Node nd : this.orphanOnCreate){
					if(curr.sparqlID.equals(nd.sparqlID)){						
						check = nd;
						break;
					}
				}
				if(check != null){
					// remove from the orphan list. we do not want to mod this node more than once. 
				//	this.orphanOnCreate.remove(check);
					check.updateFromJson(nodeJson);
				}
				else{
					throw new Exception( "--uncreated node referenced: " + curr.sparqlID );
				}
					
			}
			
		}
		this.orphanOnCreate.clear();
	}
/**
	 * Add json to a nodegroup
	 * @param nodeArr
	 * @param uncompressOInfo If non-null, use this to uncompress any Node properties
	 * @throws Exception 
	 * @
	 */
Add json to a nodegroup
@param nodeArr
@param uncompressOInfo If non-null, use this to uncompress any Node properties
@throws Exception
.
Add json to a nodegroup @param nodeArr @param uncompressOInfo If non - null use this to uncompress any Node properties @throws Exception .
public void addJson(JSONArray nodeArr, OntologyInfo uncompressOInfo) throws Exception  {
		this.oInfo = uncompressOInfo;
		for (int j = 0; j < nodeArr.size(); ++j) {
			JSONObject nodeJson = (JSONObject) nodeArr.get(j);
			Node curr  = new Node(nodeJson, this, uncompressOInfo);
			Node check = this.getNodeBySparqlID(curr.getSparqlID());
			if(check == null){
				this.addOneNode(curr, null, null, null, false);
			}
			else{
				check = null;
				for(Node nd : this.orphanOnCreate){
					if(curr.sparqlID.equals(nd.sparqlID)){						
						check = nd;
						break;
					}
				}
				if(check != null){
					check.updateFromJson(nodeJson);
				}
				else{
					throw new Exception( "--uncreated node referenced: " + curr.sparqlID );
				}
			}
		}
		this.orphanOnCreate.clear();
	}
public void addJson ( JSONArray nodeArr , OntologyInfo uncompressOInfo ) throws Exception { this . oInfo = uncompressOInfo ; for ( int j = 0 ; j < nodeArr . size ( ) ; ++ j ) { JSONObject nodeJson = ( JSONObject ) nodeArr . get ( j ) ; Node curr = new Node ( nodeJson , this , uncompressOInfo ) ; Node check = this . getNodeBySparqlID ( curr . getSparqlID ( ) ) ; if ( check == null ) { this . addOneNode ( curr , null , null , null , false ) ; } else { check = null ; for ( Node nd : this . orphanOnCreate ) { if ( curr . sparqlID . equals ( nd . sparqlID ) ) { check = nd ; break ; } } if ( check != null ) { check . updateFromJson ( nodeJson ) ; } else { throw new Exception ( "--uncreated node referenced: " + curr . sparqlID ) ; } } } this . orphanOnCreate . clear ( ) ; }
Add json to a nodegroup
 @param nodeArr
 @param uncompressOInfo If non-null, use this to uncompress any Node properties
 @throws Exception
 @
Add json to a nodegroup @param nodeArr @param uncompressOInfo If non - null use this to uncompress any Node properties @throws Exception @
// create nodes we have never seen // modify the existing node: // if the node is in both the nodesList and orphan list, modify it.  // remove from the orphan list. we do not want to mod this node more than once.  //	this.orphanOnCreate.remove(check);