Package gamedata

Class TileSet


  • public class TileSet
    extends java.lang.Object
    A database of available tile set resources.
    Since:
    3.0
    Author:
    Chris Jennings
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  TileSet.Category
      An enumeration of the general categories that a PageItem can fall into.
      static class  TileSet.Entry
      An entry in a tile set; that is, a description of a single tile from a tile set file.
      static class  TileSet.Parser
      A parser for tile set files.
      static class  TileSet.TileClass
      An enumeration of the possible class values for a tile's tile set entry.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void add​(java.lang.String resource)
      Adds a tile set resource to the list of tile set files.
      static java.util.Set<TileSet.Entry> getTileSetEntries()
      Returns all entries from all added tile sets as an immutable set.
      static java.lang.String[] getTileSets()
      Returns the names of all of the resource files that have been added by calling add(java.lang.String).
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • add

        public static void add​(java.lang.String resource)
        Adds a tile set resource to the list of tile set files. If the tile set has not been added previously, its entries will be parsed and added to the available tiles.
        Parameters:
        resource - the location of the tile set resource
      • getTileSets

        public static java.lang.String[] getTileSets()
        Returns the names of all of the resource files that have been added by calling add(java.lang.String).
        Returns:
        all added tile set resources
      • getTileSetEntries

        public static java.util.Set<TileSet.Entry> getTileSetEntries()
        Returns all entries from all added tile sets as an immutable set.
        Returns:
        the set of added tile set entries