public class DefaultMapReader<G extends GameObject<G,A,R>,A extends MapArchObject<A>,R extends Archetype<G,A,R>> extends java.lang.Object implements MapReader<G,A>
MapReader
.Constructor and Description |
---|
DefaultMapReader(MapArchObjectParserFactory<A> mapArchObjectParserFactory,
MapArchObjectFactory<A> mapArchObjectFactory,
GameObjectParser<G,A,R> gameObjectParser,
java.io.File file)
Open a file for reading it as a map.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<G> |
getGameObjects()
Return the decoded game objects.
|
A |
getMapArchObject()
Returns the MapArchObject read from this MapFileDecode.
|
public DefaultMapReader(@NotNull MapArchObjectParserFactory<A> mapArchObjectParserFactory, @NotNull MapArchObjectFactory<A> mapArchObjectFactory, @NotNull GameObjectParser<G,A,R> gameObjectParser, @NotNull java.io.File file) throws java.io.IOException
mapArchObjectParserFactory
- the map arch object parser factory
instancemapArchObjectFactory
- the map arch object factory instancegameObjectParser
- the game object parser instancefile
- the file to openjava.io.IOException
- in case the file couldn't be readInvalidMapFormatException
- in case the file is in wrong format@NotNull public A getMapArchObject()
getMapArchObject
in interface MapReader<G extends GameObject<G,A,R>,A extends MapArchObject<A>>
@NotNull public java.util.List<G> getGameObjects()
getGameObjects
in interface MapReader<G extends GameObject<G,A,R>,A extends MapArchObject<A>>