|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.commons.digester.RuleSetBase
com.threerings.media.tile.tools.xml.TileSetRuleSet
public abstract class TileSetRuleSet
The tileset rule set is used to parse the base attributes of a tileset instance. Derived classes would extend this and add rules for their own special tilesets.
| Field Summary | |
|---|---|
protected String |
_path
The full path at which me match our tilesets. |
protected String |
_tilesetPath
The tileset path we append to the prefix to get the full path. |
static String |
TILESET_PATH
The component of the digester path that is appended by the tileset rule set to match a tileset. |
| Fields inherited from class org.apache.commons.digester.RuleSetBase |
|---|
namespaceURI |
| Constructor Summary | |
|---|---|
TileSetRuleSet()
|
|
| Method Summary | |
|---|---|
void |
addRuleInstances(org.apache.commons.digester.Digester digester)
Adds the necessary rules to the digester to parse our tilesets. |
String |
getPath()
|
protected abstract Class<? extends TileSet> |
getTileSetClass()
A tileset rule set will create tilesets of a particular class, which must be provided by the derived class via this method. |
boolean |
isValid(Object target)
The ruleset can be provided to a ValidatedSetNextRule to ensure that the tileset
was fully parsed before doing something with it. |
void |
setPrefix(String prefix)
Instructs the tileset rule set to match tilesets with the supplied prefix. |
| Methods inherited from class org.apache.commons.digester.RuleSetBase |
|---|
getNamespaceURI |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String TILESET_PATH
protected String _tilesetPath
protected String _path
| Constructor Detail |
|---|
public TileSetRuleSet()
| Method Detail |
|---|
public String getPath()
public void setPrefix(String prefix)
tilesets.objectsets will match tilesets in the
following XML file:
<tilesets>
<objectsets>
<tileset>
// ...
</tileset>
</objectsets>
</tilesets>
This must be called before adding the ruleset to a digester.
public void addRuleInstances(org.apache.commons.digester.Digester digester)
_prefix
member).
addRuleInstances in interface org.apache.commons.digester.RuleSetaddRuleInstances in class org.apache.commons.digester.RuleSetBasepublic boolean isValid(Object target)
ValidatedSetNextRule to ensure that the tileset
was fully parsed before doing something with it.
isValid in interface ValidatedSetNextRule.Validatorprotected abstract Class<? extends TileSet> getTileSetClass()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||