Should be stable now

This commit is contained in:
boy0001 2015-01-29 18:45:14 +11:00
parent 3487d7d4c4
commit 7143da0ebf
8 changed files with 79 additions and 39 deletions

View file

@ -24,8 +24,8 @@ package com.intellectualcrafters.plot.flag;
import org.apache.commons.lang.StringUtils;
public class Flag {
private final AbstractFlag key;
private final Object value;
private AbstractFlag key;
private Object value;
/**
* Flag object used to store basic information for a Plot. Flags are a key/value pair. For a flag to be usable by a
@ -54,6 +54,13 @@ public class Flag {
throw new IllegalArgumentException(key.getValueDesc());
}
}
public void setKey(AbstractFlag key) {
this.key = key;
if (this.value instanceof String) {
this.value = key.parseValueRaw((String) this.value);
}
}
/**
* Warning: Unchecked