Package org.apache.commons.vfs2.util
Class Os
- java.lang.Object
-
- org.apache.commons.vfs2.util.Os
-
@Deprecated public final class Os extends java.lang.Object
Deprecated.Use Apache Commons Lang'sSystemUtils
. Remove in 3.0.Class to help to determine the OS.
-
-
Field Summary
Fields Modifier and Type Field Description static OsFamily
OS_FAMILY_DOS
Deprecated.All DOS based OSes.static OsFamily
OS_FAMILY_MAC
Deprecated.All Mac based OSes.static OsFamily
OS_FAMILY_NETWARE
Deprecated.Netware.static OsFamily
OS_FAMILY_OS2
Deprecated.OS/2.static OsFamily
OS_FAMILY_OSX
Deprecated.OSX.static OsFamily
OS_FAMILY_UNIX
Deprecated.All Unix based OSes.static OsFamily
OS_FAMILY_WIN9X
Deprecated.All Windows 9x based OSes.static OsFamily
OS_FAMILY_WINDOWS
Deprecated.All Windows based OSes.static OsFamily
OS_FAMILY_WINNT
Deprecated.All Windows NT based OSes.
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static OsFamily
getFamily(java.lang.String name)
Deprecated.Locates an OsFamily by name (case-insensitive).static boolean
isArch(java.lang.String arch)
Deprecated.Determines if the OS on which Ant is executing matches the given OS architecture.static boolean
isFamily(java.lang.String family)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family.static boolean
isFamily(OsFamily family)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family.static boolean
isName(java.lang.String name)
Deprecated.Determines if the OS on which Ant is executing matches the given OS name.static boolean
isOs(java.lang.String family, java.lang.String name, java.lang.String arch, java.lang.String version)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family, name, architecture and version.static boolean
isOs(OsFamily family, java.lang.String name, java.lang.String arch, java.lang.String version)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family, name, architecture and version.static boolean
isVersion(java.lang.String version)
Deprecated.Determines if the OS on which Ant is executing matches the given OS version.
-
-
-
Field Detail
-
OS_FAMILY_WINDOWS
public static final OsFamily OS_FAMILY_WINDOWS
Deprecated.All Windows based OSes.
-
OS_FAMILY_DOS
public static final OsFamily OS_FAMILY_DOS
Deprecated.All DOS based OSes.
-
OS_FAMILY_WINNT
public static final OsFamily OS_FAMILY_WINNT
Deprecated.All Windows NT based OSes.
-
OS_FAMILY_WIN9X
public static final OsFamily OS_FAMILY_WIN9X
Deprecated.All Windows 9x based OSes.
-
OS_FAMILY_OS2
public static final OsFamily OS_FAMILY_OS2
Deprecated.OS/2.
-
OS_FAMILY_NETWARE
public static final OsFamily OS_FAMILY_NETWARE
Deprecated.Netware.
-
OS_FAMILY_UNIX
public static final OsFamily OS_FAMILY_UNIX
Deprecated.All Unix based OSes.
-
OS_FAMILY_MAC
public static final OsFamily OS_FAMILY_MAC
Deprecated.All Mac based OSes.
-
OS_FAMILY_OSX
public static final OsFamily OS_FAMILY_OSX
Deprecated.OSX.
-
-
Method Detail
-
getFamily
public static OsFamily getFamily(java.lang.String name)
Deprecated.Locates an OsFamily by name (case-insensitive).- Parameters:
name
- The family name to lookup.- Returns:
- the OS family, or null if not found.
-
isArch
public static boolean isArch(java.lang.String arch)
Deprecated.Determines if the OS on which Ant is executing matches the given OS architecture.- Parameters:
arch
- The architecture to check.- Returns:
- true if the architecture matches.
-
isFamily
public static boolean isFamily(OsFamily family)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family.- Parameters:
family
- The family to check.- Returns:
- true if the family matches.
-
isFamily
public static boolean isFamily(java.lang.String family)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family.- Parameters:
family
- The family to check.- Returns:
- true if the family matches.
-
isName
public static boolean isName(java.lang.String name)
Deprecated.Determines if the OS on which Ant is executing matches the given OS name.- Parameters:
name
- Description of Parameter- Returns:
- The Name value
- Since:
- 1.7
-
isOs
public static boolean isOs(OsFamily family, java.lang.String name, java.lang.String arch, java.lang.String version)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family, name, architecture and version.- Parameters:
family
- The OS familyname
- The OS namearch
- The OS architectureversion
- The OS version- Returns:
- The Os value
-
isOs
public static boolean isOs(java.lang.String family, java.lang.String name, java.lang.String arch, java.lang.String version)
Deprecated.Determines if the OS on which Ant is executing matches the given OS family, name, architecture and version.- Parameters:
family
- The OS familyname
- The OS namearch
- The OS architectureversion
- The OS version- Returns:
- The Os value
-
isVersion
public static boolean isVersion(java.lang.String version)
Deprecated.Determines if the OS on which Ant is executing matches the given OS version.- Parameters:
version
- The version to check.- Returns:
- true if the version matches.
-
-