Commit 4dfcc59b authored by helene ortiz's avatar helene ortiz
Browse files

No commit message

No commit message
parent b0f9882a
......@@ -20,7 +20,9 @@ package fr.ill.ics.core.property;
import java.io.File;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.List;
......@@ -50,6 +52,7 @@ import fr.ill.ics.nscclient.servant.ResourceNotFoundException;
import fr.ill.ics.nscclient.servant.SpyPropertyDescriptor;
import fr.ill.ics.util.ConfigManager;
import fr.ill.ics.util.FileHelper;
import fr.ill.ics.util.exception.ConfigurationException;
import fr.ill.ics.util.exception.ConfigurationException.PluginType;
import fr.ill.ics.util.exception.PropertyNotFoundException;
......@@ -1121,4 +1124,23 @@ public class PropertyManager {
}
return exists;
}
public Collection<String> getChildrenOfAllDynamicProperties(String controllerName) {
Set<String> properties = new HashSet<String>();
Set<String> dynamicProperties = new HashSet<String>();
Iterator<String> it = PropertyManager.getInstance().getDynamicPropertiesForController(controllerName).iterator();
String controllerType = ControllerManager.getInstance().getType(controllerName);
while (it.hasNext()) {
String dynamicPropertyNamePrefix = it.next();
String sizePropertyName = PropertyManager.getInstance().getSizePropertyName(controllerType, dynamicPropertyNamePrefix);
if (sizePropertyName == null) {
ConfigurationException ce = new ConfigurationException(ConfigManager.getInstance().getString("sizePropertyNameInformationIsMissingMessage"), controllerType, dynamicPropertyNamePrefix, getClass().getCanonicalName(), "getDynamicPropertiesOfController");
} else {
dynamicProperties.addAll(PropertyManager.getInstance().getDynamicPropertyChildNames(controllerName, dynamicPropertyNamePrefix, sizePropertyName));
}
}
return dynamicProperties;
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment