| 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.springrts.ai.oo.DataDirs
public class DataDirs
| Method Summary | |
|---|---|
 String | 
allocatePath(String relPath,
             boolean writeable,
             boolean create,
             boolean dir,
             boolean common)
 | 
 int | 
compareTo(DataDirs other)
 | 
 boolean | 
equals(Object otherObject)
 | 
 String | 
getConfigDir()
This interfaces main data dir, which is where the shared library and the InterfaceInfo.lua file are located, e.g.: /usr/share/games/spring/AI/Skirmish/RAI/0.601/  | 
 byte | 
getPathSeparator()
Returns '/' on posix and '\\' on windows  | 
 Roots | 
getRoots()
 | 
 String | 
getWriteableDir()
This interfaces writeable data dir, which is where eg logs, caches and learning data should be stored, e.g.: /home/userX/.spring/AI/Skirmish/RAI/0.601/  | 
 int | 
hashCode()
 | 
 boolean | 
locatePath(String path,
           int path_sizeMax,
           String relPath,
           boolean writeable,
           boolean create,
           boolean dir,
           boolean common)
Returns an absolute path which consists of: data-dir + Skirmish-AI-path + relative-path.  | 
 String | 
toString()
 | 
| Methods inherited from class java.lang.Object | 
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait | 
| Method Detail | 
|---|
public int compareTo(DataDirs other)
compareTo in interface Comparable<DataDirs>public boolean equals(Object otherObject)
equals in class Objectpublic int hashCode()
hashCode in class Objectpublic String toString()
toString in class Objectpublic byte getPathSeparator()
public String getConfigDir()
public String getWriteableDir()
public boolean locatePath(String path,
                          int path_sizeMax,
                          String relPath,
                          boolean writeable,
                          boolean create,
                          boolean dir,
                          boolean common)
path - store for the resulting absolute pathpath_sizeMax - storage size of the abovewriteable - if true, only the writeable data-dir is consideredcreate - if true, and realPath is not found, its dir structure
                     is created recursively under the writeable data-dirdir - if true, realPath specifies a dir, which means if
                     create is true, the whole path will be created,
                     including the last partcommon - if true, the version independent data-dir is formed,
                     which uses "common" instead of the version, eg:
                     "/home/userX/.spring/AI/Skirmish/RAI/common/..."
DataDirs_Roots_locatePath
public String allocatePath(String relPath,
                           boolean writeable,
                           boolean create,
                           boolean dir,
                           boolean common)
locatePath()public Roots getRoots()
  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||