public void setKilled(boolean b) { if (myAccess.getCompiledScript().getCurrentMap() != null) { Mappable myMap = (Mappable) myAccess.getCompiledScript().getCurrentMap().myObject; if (myMap != null && myMap instanceof com.dexels.navajo.adapter.SQLMap) { ((SQLMap) myMap).setKillConnection(); } } myAccess.getCompiledScript().setKill(b); }
private void showMapDetails(Message parent, MappableTreeNode m) throws NavajoException, MappingException, UserException { Mappable myMap = (Mappable) m.myObject; addProperty(parent, "Map", m.getMapName(), Property.STRING_PROPERTY, 50); addProperty(parent, "Totaltime", new Integer(m.getTotaltime()), Property.STRING_PROPERTY, 50); Class<?> ccc = null; try { ccc = Class.forName("com.dexels.navajo.adapter.SPMap"); } catch (ClassNotFoundException e) { } if (myMap instanceof com.dexels.navajo.adapter.SQLMap || (ccc != null && (ccc.isInstance(myMap)))) { SQLMap mySQL = (SQLMap) myMap; Message parameters = getMessage(parent, "MapParameters"); addProperty(parameters, "Datasource", mySQL.getDatasource(), Property.STRING_PROPERTY, 50); addProperty( parameters, "DatabaseProductName", mySQL.getDatabaseProductName(), Property.STRING_PROPERTY, 100); addProperty( parameters, "DatabaseVersion", mySQL.getDatabaseVersion(), Property.STRING_PROPERTY, 100); addProperty( parameters, "SessionId", mySQL.getDatabaseSessionId(), Property.STRING_PROPERTY, -1); addProperty(parameters, "Query", mySQL.getQuery(), Property.STRING_PROPERTY, -1); } // Show parents. if (m.getParent() != null) { Message parentMap = getMessage(parent, "ParentMap"); showMapDetails(parentMap, m.getParent()); } }