view app/Global.java @ 23:cad8e054fe4b

modifying getConsensus action
author one
date Tue, 02 Oct 2012 23:46:55 +0900
parents 7b314898fddd
children f3db6edc61ad
line wrap: on
line source

import models.TPGraph;

import com.tinkerpop.blueprints.Graph;
import com.tinkerpop.blueprints.Vertex;

import play.Application;
import play.GlobalSettings;
import play.Logger;


public class Global extends GlobalSettings {

	@Override
	public void onStart(Application app) {
		TPGraph tpgraph = TPGraph.getInstance();
		tpgraph.setPath(null);
		Graph graph = tpgraph.newGraph();
		Vertex claimV = graph.addVertex(null);
		tpgraph.setClaimRootId(claimV.getId());
		Vertex userV = graph.addVertex(null);
		tpgraph.setUserRootId(userV.getId());
	}
	
	  @Override
	  public void onStop(Application app) {
		  Logger.info("Application shutdown...");	    
		  
	  }  	
	
	  
	
	
}