Commit 11e02b24 authored by Hélène Ortiz's avatar Hélène Ortiz

3.1.3

parent 16e16dc2
......@@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>fr.ill.ics</groupId>
<artifactId>nomadcommandsystem</artifactId>
<version>3.1.3-SNAPSHOT</version>
<version>3.1.3</version>
<name>NomadCommandSystem</name>
<description>Java bridge for the communication with the Nomad server</description>
<scm>
......
......@@ -75,9 +75,6 @@ public class PropertyDatabase {
* @param standardPropertyDescriptor
*/
public void addStandardPropertyDescriptor(int servantId, StandardPropertyDescriptor standardPropertyDescriptor) {
//System.out.println("added property " + standardPropertyDescriptor.getName() + " to servant " + servantId);
properties.put(standardPropertyDescriptor.getId(), standardPropertyDescriptor);
if (!propertiesByServant.containsKey(servantId)) {
Set<Integer> set = new HashSet<Integer>();
......@@ -101,6 +98,12 @@ public class PropertyDatabase {
dynamicPropertiesByServant.get(servantId).add(dynamicPropertyDescriptor);
}
/**
*
* @param servantId
* @param descriptor
*/
public void addSpyPropertyDescriptor(int servantId, SpyPropertyDescriptor descriptor) {
if (!spyPropertiesByServant.containsKey(servantId)) {
......@@ -130,6 +133,18 @@ public class PropertyDatabase {
public StandardPropertyDescriptor getStandardPropertyDescriptor(int id) {
return properties.get(id);
}
public DynamicPropertyDescriptor getDynamicPropertyDescriptor(String genericPropertyName) {
Iterator<Entry<Integer, DynamicPropertyDescriptor>> it = dynamicProperties.entrySet().iterator();
while (it.hasNext()) {
Entry<Integer, DynamicPropertyDescriptor> entry = it.next();
if (entry.getValue().getName().equals(genericPropertyName)) {
return entry.getValue();
}
}
return null;
}
public void removeDynamicPropertyDescriptors(int servantId) {
......
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