public soot.toolkits.graph.interaction.InteractionHandler soot_toolkits_graph_interaction_InteractionHandler() { if (instance_soot_toolkits_graph_interaction_InteractionHandler == null) { synchronized (this) { if (instance_soot_toolkits_graph_interaction_InteractionHandler == null) instance_soot_toolkits_graph_interaction_InteractionHandler = new soot.toolkits.graph.interaction.InteractionHandler(g); } } return instance_soot_toolkits_graph_interaction_InteractionHandler; } protected void release_soot_toolkits_graph_interaction_InteractionHandler() {
public void handleBeforeAnalysisEvent(Object beforeFlow) { if (isInteractThisAnalysis()) { if (autoCon()) { doInteraction(new InteractionEvent(IInteractionConstants.NEW_BEFORE_ANALYSIS_INFO_AUTO, beforeFlow)); } else { doInteraction(new InteractionEvent(IInteractionConstants.NEW_BEFORE_ANALYSIS_INFO, beforeFlow)); } } }
public void handleCallGraphNextMethod() { if (!cgDone()) { getGrapher().setNextMethod(getNextMethod()); getGrapher().handleNextMethod(); } }
public void handleCallGraphStart(Object info, CallGraphGrapher grapher) { setGrapher(grapher); doInteraction(new InteractionEvent(IInteractionConstants.CALL_GRAPH_START, info)); if (!isCgReset()) { handleCallGraphNextMethod(); } else { setCgReset(false); handleReset(); } }
public void handleTransformDone(Transform t, Body b) { doneCurrent(true); if (isInteractThisAnalysis()) { doInteraction(new InteractionEvent(IInteractionConstants.DONE, null)); } }
public void handleCfgEvent(DirectedGraph<?> g) { if (currentPhaseEnabled()) { logger.debug("Analyzing: " + currentPhaseName()); doInteraction(new InteractionEvent(IInteractionConstants.NEW_ANALYSIS, currentPhaseName())); } if (isInteractThisAnalysis()) { doInteraction(new InteractionEvent(IInteractionConstants.NEW_CFG, g)); } }
public void handleNewAnalysis(Transform t, Body b) { // here save current phase name and only send if actual data flow analysis exists if (PhaseOptions.getBoolean(PhaseOptions.v().getPhaseOptions(t.getPhaseName()), "enabled")) { String name = t.getPhaseName() + " for method: " + b.getMethod().getName(); currentPhaseName(name); currentPhaseEnabled(true); doneCurrent(false); } else { currentPhaseEnabled(false); setInteractThisAnalysis(false); } }
public void handleReset() { if (!cgDone()) { getGrapher().reset(); } }
public void handleStopAtNodeEvent(Object u) { if (isInteractThisAnalysis()) { doInteraction(new InteractionEvent(IInteractionConstants.STOP_AT_NODE, u)); } }
if (InteractionHandler.v().getInteractionListener() == null) { logger.debug("Cannot run in interactive mode. No listeners available. Continuing in regular mode."); Options.v().set_interactive_mode(false);
private synchronized void doInteraction(InteractionEvent event) { getInteractionListener().setEvent(event); getInteractionListener().handleEvent(); }
public void handleCallGraphPart(Object info) { doInteraction(new InteractionEvent(IInteractionConstants.CALL_GRAPH_PART, info)); if (!isCgReset()) { handleCallGraphNextMethod(); } else { setCgReset(false); handleReset(); } }
public void handleCfgEvent(DirectedGraph g){ if (currentPhaseEnabled()){ G.v().out.println("Analyzing: "+currentPhaseName()); doInteraction(new InteractionEvent(IInteractionConstants.NEW_ANALYSIS, currentPhaseName())); } if (isInteractThisAnalysis()){ doInteraction(new InteractionEvent(IInteractionConstants.NEW_CFG, g)); } }
public void handleNewAnalysis(Transform t, Body b){ // here save current phase name and only send if actual data flow analysis exists if (PhaseOptions.getBoolean(PhaseOptions.v().getPhaseOptions( t.getPhaseName()), "enabled")){ String name = t.getPhaseName()+" for method: "+b.getMethod().getName(); currentPhaseName(name); currentPhaseEnabled(true); doneCurrent(false); } else { currentPhaseEnabled(false); setInteractThisAnalysis(false); } }
public void handleTransformDone(Transform t, Body b){ doneCurrent(true); if (isInteractThisAnalysis()){ doInteraction(new InteractionEvent(IInteractionConstants.DONE, null)); } }
public void handleReset(){ if (!cgDone()){ getGrapher().reset(); } }
public void handleStopAtNodeEvent(Object u){ if (isInteractThisAnalysis()){ doInteraction(new InteractionEvent(IInteractionConstants.STOP_AT_NODE, u)); } }
public void runPacks() { if (Options.v().src_prec() == Options.src_prec_class && Options.v().keep_line_number()){ LineNumberAdder lineNumAdder = LineNumberAdder.v(); lineNumAdder.internalTransform("", null); } retrieveAllBodies(); if (Options.v().interactive_mode()){ if (InteractionHandler.v().getInteractionListener() == null){ G.v().out.println("Cannot run in interactive mode. No listeners available. Continuing in regular mode."); Options.v().set_interactive_mode(false); } else { G.v().out.println("Running in interactive mode."); } } runBodyPacks(); handleInnerClasses(); }
private synchronized void doInteraction(InteractionEvent event){ getInteractionListener().setEvent(event); getInteractionListener().handleEvent(); }
public void handleCallGraphStart(Object info, CallGraphGrapher grapher){ setGrapher(grapher); doInteraction(new InteractionEvent(IInteractionConstants.CALL_GRAPH_START, info)); if (!isCgReset()){ handleCallGraphNextMethod(); } else { setCgReset(false); handleReset(); } }