use of net.sourceforge.processdash.data.ImmutableStringData in project processdash by dtuma.
the class ProcessDashboard method registerEnvironmentalData.
private void registerEnvironmentalData() {
try {
Map env = new HashMap();
String os = InternalSettings.getOSPrefix();
env.put("OS.TYPE", new ImmutableStringData(os, false, true));
env.put("OS.IS_" + os.toUpperCase(), ImmutableDoubleData.TRUE);
if (!os.equals("windows"))
env.put("OS.IS_UNIX", ImmutableDoubleData.TRUE);
data.mountPhantomData("//Env", env);
} catch (InvalidDatafileFormat e) {
logger.log(Level.WARNING, "Unexpected error", e);
}
}
use of net.sourceforge.processdash.data.ImmutableStringData in project processdash by dtuma.
the class FindLastExpression method caseTStringLiteral.
public void caseTStringLiteral(TStringLiteral node) {
String stringVal = interpolateResources(trimDelim(node));
add(new PushConstant(new ImmutableStringData(stringVal)));
}
use of net.sourceforge.processdash.data.ImmutableStringData in project processdash by dtuma.
the class EVTaskDependency method saveDependencies.
public static void saveDependencies(DataContext data, String taskPath, Collection<EVTaskDependency> dependencies) {
SimpleData value = null;
if (dependencies != null && !dependencies.isEmpty()) {
StringBuffer xml = new StringBuffer();
xml.append("<list>");
for (EVTaskDependency d : dependencies) {
d.getAsXML(xml, false);
}
if (xml.length() > 6) {
xml.append("</list>");
value = new ImmutableStringData(xml.toString());
}
}
String dataName = DataRepository.createDataName(taskPath, TASK_DEPENDENCIES_DATA_NAME);
data.putValue(dataName, value);
}
Aggregations