Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.crosswire.jsword.util
Class OSType

    java.lang.Object
      org.crosswire.jsword.util.OSType

All Implemented Interfaces:
  Serializable

    public abstract class OSType

extends Object
implements Serializable

Types of Operating Systems for which specialized behavior is needed.

Author:
  DM Smith [dmsmith555 at yahoo dot com]
See Also:
  `for license details. The copyright to this program is held by it's authors.`, Serialized Form

Field Summary
`static OSType` | `DEFAULT`
`private static Logger` | `log` The log stream
`static OSType` | `MAC`
`private static String` | `MAC_USER_DATA_AREA` The Mac user settings parent directory
`private String` | `name` The name of the type
`private static int` | `nextObj`
`private int` | `obj`
`private static OSType` | `osType` The machine's osType
`protected URL` | `userArea` The user's private data area.
`private static URL` | `userHome` The user's home directory.
`private static OSType[]` | `VALUES`
`static OSType` | `WIN32`
`private static String` | `WIN32_USER_DATA_AREA` The Windows user settings parent directory

Constructor Summary
`OSType(String name)` Simple ctor

Method Summary
`boolean` | `equals(Object o)` Prevent subclasses from overriding canonical identity based Object methods
`static OSType` | `fromInteger(int i)` Lookup method to convert from an integer
`static OSType` | `fromString(String name)` Lookup method to convert from a String
`static OSType` | `getOSType()` Get the machine's OSType.
`abstract URL` | `getUserArea()` Get the user area for this OSType.
`abstract URL` | `getUserAreaFolder(String hiddenFolderName, String visibleFolderName)` A folder in the user area.
`static URL` | `getUserHome()`
`int` | `hashCode()` Prevent subclasses from overriding canonical identity based Object methods
`(package private) Object` | `readResolve()`
`int` | `toInteger()` Get an integer representation for this CaseType
`String` | `toString()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### MAC

    public static final OSType MAC

### WIN32

    public static final OSType WIN32

### DEFAULT

    public static final OSType DEFAULT

### name

    private String name

  The name of the type

### nextObj

    private static int nextObj

### obj

    private final int obj

### VALUES

    private static final OSType[] VALUES

### userArea

    protected URL userArea

  The user's private data area.

### WIN32_USER_DATA_AREA

    private static final String WIN32_USER_DATA_AREA

  The Windows user settings parent directory

  See Also:
    Constant Field Values

### MAC_USER_DATA_AREA

    private static final String MAC_USER_DATA_AREA

  The Mac user settings parent directory

  See Also:
    Constant Field Values

### osType

    private static OSType osType

  The machine's osType

### userHome

    private static URL userHome

  The user's home directory.

### log

    private static final Logger log

  The log stream

Constructor Detail

### OSType

    public OSType(String name)

  Simple ctor

Method Detail

### getUserArea

    public abstract URL getUserArea()

  Get the user area for this OSType.

  Returns:
    the user area

### getUserAreaFolder

    public abstract URL getUserAreaFolder(String hiddenFolderName,
                                          String visibleFolderName)

  A folder in the user area. This osType will determine which to use in constructing the URL to the folder.

  Parameters:
    `hiddenFolderName` - is typically a "unix" hidden folder name such as .jsword.
    `visibleFolderName` - is an visible folder name, such as JSword.
  Returns:
    the user area folder

### getUserHome

    public static URL getUserHome()

### toInteger

    public int toInteger()

  Get an integer representation for this CaseType

### getOSType

    public static OSType getOSType()

  Get the machine's OSType.

  Returns:
    the machine's OSType

### fromString

    public static OSType fromString(String name)

  Lookup method to convert from a String

### fromInteger

    public static OSType fromInteger(int i)

  Lookup method to convert from an integer

### equals

    public final boolean equals(Object o)

  Prevent subclasses from overriding canonical identity based Object methods

  Overrides:
    `equals` in class `Object`
  See Also:
    `Object.equals(java.lang.Object)`

### hashCode

    public final int hashCode()

  Prevent subclasses from overriding canonical identity based Object methods

  Overrides:
    `hashCode` in class `Object`
  See Also:
    `Object.hashCode()`

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

### readResolve

    Object readResolve()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Copyright ¨ 2003-2006
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD