@Override public String toString() { return this.toString(false); }
@Override public String toString() { final StringBuffer b = new StringBuffer(); b.append("[app=").append(this.app.toString()).append(", lib=").append(this.lib.toString()).append(", filename=").append(this.filename).append(", scope=").append(this.scope).append(", trans=").append(this.getTransitive()).append("]"); return b.toString(); } }
public String toString() { final StringBuilder b = new StringBuilder(); final String classname = this.getClass().getName().substring(1 + this.getClass().getName().lastIndexOf(".")); b.append(classname + "[jar/war=").append(this.jarWriter.getOriginalJarFileName()); b.append(", libId=").append( (this.libraryId==null?"false":this.libraryId.toString())); b.append(", instr=").append(this.instrument); b.append(", instrCtx=").append( (JarAnalyzer.getAppContext()==null?"false":JarAnalyzer.getAppContext().toString(false)) ).append("]"); return b.toString(); }
public String toString(boolean _deep) { final StringBuilder builder = new StringBuilder(); if(_deep) { builder.append("Application ").append(this.toString(false)).append(System.getProperty("line.separator")); if(this.getConstructs()!=null) for(ConstructId cid: this.getConstructs()) builder.append(" ConstructId ").append(cid).append(System.getProperty("line.separator")); } else { builder.append("[").append(this.getMvnGroup()).append(":").append(this.getArtifact()).append(":").append(this.getVersion()).append("]"); } return builder.toString(); } }
@Override public String toString() { final StringBuffer b = new StringBuffer(); b.append("["); if(this.tenant!=null) b.append("tenant=").append(this.tenant.toString()); if(this.space !=null) { if(!b.toString().equals("[")) b.append(", "); b.append("space=").append(this.space.toString()); } if(this.application!=null) { if(!b.toString().equals("[")) b.append(", "); b.append("app=").append(this.application.toString()); } b.append("]"); return b.toString(); } }
/** * Reads configuration settings in order to instantiate an {@link Application}. * @return an {@link Application) * @throws ConfigurationException if the instantiation fails */ public static Application getAppContext() throws ConfigurationException { final Configuration c = VulasConfiguration.getGlobal().getConfiguration(); Application a = null; try { a = new Application(c.getString(APP_CTX_GROUP), c.getString(APP_CTX_ARTIF), c.getString(APP_CTX_VERSI)); } catch (IllegalArgumentException e) { throw new ConfigurationException("Application incomplete: " + e.getMessage(), e); } if(!a.isComplete()) throw new ConfigurationException("Application incomplete: " + a.toString()); return a; }
/** * Returns the context of this goal execution. If the context has not been set before, it is constructed * by reading tenant, space and app information from the configuration obtained from {@link AbstractGoal#getConfiguration()}. * @return */ public synchronized final GoalContext getGoalContext() { if(this.goalContext==null) { final Configuration c = this.getConfiguration().getConfiguration(); this.goalContext = new GoalContext(); // Tenant if(!this.getConfiguration().isEmpty(CoreConfiguration.TENANT_TOKEN)) this.goalContext.setTenant(new Tenant(c.getString(CoreConfiguration.TENANT_TOKEN))); // Space if(!this.getConfiguration().isEmpty(CoreConfiguration.SPACE_TOKEN)) { final Space space = new Space(); space.setSpaceToken(c.getString(CoreConfiguration.SPACE_TOKEN)); this.goalContext.setSpace(space); } // App if(Application.canBuildApplication(c.getString(CoreConfiguration.APP_CTX_GROUP), c.getString(CoreConfiguration.APP_CTX_ARTIF), c.getString(CoreConfiguration.APP_CTX_VERSI))) { final Application a = new Application(c.getString(CoreConfiguration.APP_CTX_GROUP), c.getString(CoreConfiguration.APP_CTX_ARTIF), c.getString(CoreConfiguration.APP_CTX_VERSI)); if(a.isComplete()) this.goalContext.setApplication(a); else log.warn("Incomplete application context: " + a.toString()); } } return this.goalContext; }
ctx.setApplication(a); else log.warn("Incomplete application context: " + a.toString()); return ctx;
WalaCallgraphConstructor.log.info("Starting call graph construction for " + this.appContext.toString(false)); try {