public class TileSetBundle extends HashIntMap<TileSet> implements ImageDataProvider
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>IntMap.IntEntry<V>DEFAULT_BUCKETS, DEFAULT_LOAD_FACTOR| Constructor and Description |
|---|
TileSetBundle() |
| Modifier and Type | Method and Description |
|---|---|
void |
addTileSet(int tileSetId,
TileSet set)
Adds a tileset to this tileset bundle.
|
Iterator<Integer> |
enumerateTileSetIds()
Enumerates the tileset ids in this tileset bundle.
|
Iterator<TileSet> |
enumerateTileSets()
Enumerates the tilesets in this tileset bundle.
|
String |
getIdent()
Returns a string identifier for this image data provider which wil
be used to differentiate it from other providers and thus should be
unique.
|
TileSet |
getTileSet(int tileSetId)
Retrieves a tileset from this tileset bundle.
|
void |
init(ResourceBundle bundle)
Initializes this resource bundle with a reference to the jarfile from which it was loaded
and from which it can load image data.
|
BufferedImage |
loadImage(String path)
Returns the image at the specified path.
|
clear, clone, containsKey, containsKey, containsValue, elements, ensureCapacity, entrySet, get, get, intEntrySet, intKeySet, keys, keySet, put, put, putAll, remove, remove, sizeequals, hashCode, isEmpty, putAll, toString, valuescompute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, isEmpty, merge, putAll, putIfAbsent, remove, replace, replace, replaceAll, valuespublic void init(ResourceBundle bundle)
public final void addTileSet(int tileSetId,
TileSet set)
public final TileSet getTileSet(int tileSetId)
public Iterator<Integer> enumerateTileSetIds()
public Iterator<TileSet> enumerateTileSets()
public String getIdent()
ImageDataProvidergetIdent in interface ImageDataProviderpublic BufferedImage loadImage(String path) throws IOException
ImageDataProviderloadImage in interface ImageDataProviderIOExceptionCopyright © 2015. All rights reserved.