|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.freecol.common.io.FreeColDataFile
net.sf.freecol.common.io.FreeColModFile
public class FreeColModFile
A modification.
| Nested Class Summary | |
|---|---|
protected static class |
FreeColModFile.ModDescriptor
|
static class |
FreeColModFile.ModInfo
|
| Field Summary | |
|---|---|
static java.lang.String[] |
FILE_ENDINGS
|
private java.lang.String |
id
|
private static java.lang.String |
MOD_DESCRIPTOR_FILE
|
private FreeColModFile.ModInfo |
modInfo
|
private static java.lang.String |
SPECIFICATION_FILE
|
| Constructor Summary | |
|---|---|
|
FreeColModFile(FreeColModFile.ModInfo mi)
Opens the given file for reading. |
|
FreeColModFile(java.lang.String id)
Opens the given file for reading. |
protected |
FreeColModFile(java.lang.String id,
java.io.File file)
Opens the given file for reading. |
| Method Summary | |
|---|---|
protected java.lang.String[] |
getFileEndings()
File endings that are supported for this type of data file. |
java.lang.String |
getId()
Gets the ID of this mod. |
protected FreeColModFile.ModDescriptor |
getModDescriptor()
Returns an object representing this mod. |
private java.io.InputStream |
getModDescriptorInputStream()
Gets the input stream to the mod meta file. |
FreeColModFile.ModInfo |
getModInfo()
|
java.io.InputStream |
getSpecificationInputStream()
Gets the input stream to the specification. |
| Methods inherited from class net.sf.freecol.common.io.FreeColDataFile |
|---|
getFileFilter, getInputStream, getResourceMapping, getURI |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static final java.lang.String SPECIFICATION_FILE
private static final java.lang.String MOD_DESCRIPTOR_FILE
public static final java.lang.String[] FILE_ENDINGS
private java.lang.String id
private final FreeColModFile.ModInfo modInfo
| Constructor Detail |
|---|
public FreeColModFile(java.lang.String id)
id - The id of the mod to load.
java.io.IOException - if thrown while opening the file.public FreeColModFile(FreeColModFile.ModInfo mi)
mi - An id object.
java.io.IOException - if thrown while opening the file.
protected FreeColModFile(java.lang.String id,
java.io.File file)
id - The id of the mod.file - The file to be read.
java.io.IOException - if thrown while opening the file.| Method Detail |
|---|
public java.io.InputStream getSpecificationInputStream()
throws java.io.IOException
InputStream to the file
"specification.xml" within this data file.
java.io.IOException - if thrown while opening the
input stream.
protected FreeColModFile.ModDescriptor getModDescriptor()
throws java.io.IOException
java.io.IOException - if thrown while reading the
"mod.xml" file.
private java.io.InputStream getModDescriptorInputStream()
throws java.io.IOException
InputStream to the file
"mod.xml" within this data file.
java.io.IOException - if thrown while opening the
input stream.protected java.lang.String[] getFileEndings()
getFileEndings in class FreeColDataFilepublic java.lang.String getId()
public FreeColModFile.ModInfo getModInfo()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||