android.os.Environment
来源:互联网 发布:centos 病毒检测工具 编辑:程序博客网 时间:2024/05/16 08:03
http://www.chinaup.org/docs/reference/android/os/Environment.html
Value
String MEDIA_BAD_REMOVAL getExternalStorageState() returns MEDIA_BAD_REMOVAL if the media was removed before it was unmounted.
"bad_removal"
String MEDIA_MOUNTED getExternalStorageState() returns MEDIA_MOUNTED if the media is present and mounted at its mount point
with read/write access. "mounted"
String MEDIA_MOUNTED_READ_ONLY getExternalStorageState() returns MEDIA_MOUNTED_READ_ONLY if the media is present and mounted at
its mount point with read only access. "mounted_ro"
String MEDIA_REMOVED getExternalStorageState() returns MEDIA_REMOVED if the media is not present. "removed"
String MEDIA_SHARED getExternalStorageState() returns MEDIA_SHARED if the media is present not mounted, and shared via USB mass
storage. "shared"
String MEDIA_UNMOUNTABLE getExternalStorageState() returns MEDIA_UNMOUNTABLE if the media is present but cannot be mounted.
"unmountable"
String MEDIA_UNMOUNTED getExternalStorageState() returns MEDIA_UNMOUNTED if the media is present but not mounted. "unmounted"
Public Constructors
Environment()
Public Methods
static File getDataDirectory()
Gets the Android data directory.
static File getDownloadCacheDirectory()
Gets the Android Download/Cache content directory.
static File getExternalStorageDirectory()
Gets the Android external storage directory.
static String getExternalStorageState()
Gets the current state of the external storage device.
static File getRootDirectory()
Gets the Android root directory.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Object clone()
Returns a new instance of the same class as the receiver, whose slots have been filled in with the values in the slots of the
receiver.
boolean equals(Object o)
Compares the argument to the receiver, and returns true if they represent the same object using a class specific comparison.
void finalize()
Called by the virtual machine when there are no longer any (non-weak) references to the receiver.
final Class<? extends Object> getClass()
Returns the unique instance of java.lang.Class which represents the class of the receiver.
int hashCode()
Returns an integer hash code for the receiver.
final void notify()
Causes one thread which is wait ing on the receiver to be made ready to run.
final void notifyAll()
Causes all threads which are wait ing on the receiver to be made ready to run.
String toString()
Returns a string containing a concise, human-readable description of the receiver.
final void wait(long time, int frac)
Causes the thread which sent this message to be made not ready to run either pending some change in the receiver (as indicated
by notify or notifyAll) or the expiration of the timeout.
final void wait(long time)
Causes the thread which sent this message to be made not ready to run either pending some change in the receiver (as indicated
by notify or notifyAll) or the expiration of the timeout.
final void wait()
Causes the thread which sent this message to be made not ready to run pending some change in the receiver (as indicated by
notify or notifyAll).
Details
Constants
public static final String MEDIA_BAD_REMOVAL
getExternalStorageState() returns MEDIA_BAD_REMOVAL if the media was removed before it was unmounted.
Constant Value: "bad_removal"
public static final String MEDIA_MOUNTED
getExternalStorageState() returns MEDIA_MOUNTED if the media is present and mounted at its mount point with read/write access.
Constant Value: "mounted"
public static final String MEDIA_MOUNTED_READ_ONLY
getExternalStorageState() returns MEDIA_MOUNTED_READ_ONLY if the media is present and mounted at its mount point with read only
access.
Constant Value: "mounted_ro"
public static final String MEDIA_REMOVED
getExternalStorageState() returns MEDIA_REMOVED if the media is not present.
Constant Value: "removed"
public static final String MEDIA_SHARED
getExternalStorageState() returns MEDIA_SHARED if the media is present not mounted, and shared via USB mass storage.
Constant Value: "shared"
public static final String MEDIA_UNMOUNTABLE
getExternalStorageState() returns MEDIA_UNMOUNTABLE if the media is present but cannot be mounted. Typically this happens if the
file system on the media is corrupted.
Constant Value: "unmountable"
public static final String MEDIA_UNMOUNTED
getExternalStorageState() returns MEDIA_UNMOUNTED if the media is present but not mounted.
Constant Value: "unmounted"
Public Constructors
public Environment()
Public Methods
public static File getDataDirectory()
Gets the Android data directory.
public static File getDownloadCacheDirectory()
Gets the Android Download/Cache content directory.
public static File getExternalStorageDirectory()
Gets the Android external storage directory.
public static String getExternalStorageState()
Gets the current state of the external storage device.
public static File getRootDirectory()
Gets the Android root directory.
- android.os.Environment
- android.os.Environment
- android.os.Environment
- android.os.Environment
- android.os.Environment.getExternalStorageState
- android.os.Environment
- android.os.Environment
- android.os.SystemProperties和android.os.Environment
- Android - API - android.os.Environment (访问手机环境)
- build android os ubuntu Setting up a Linux build environment
- android Environment
- Android Environment
- android Environment
- Setup Building Environment for Android ICS/FireFox OS from and clean Ubuntu10.04 LTS
- Environment variable in Mac OS X
- Mac OS Create case-sensitive build environment
- Android Scripting Environment
- Android compile environment
- 警惕Oracle DB操作高压线
- 有限状态机FSM的理解
- error C2065: 'CString' : undeclared identifier
- 文字滚动(上下左右)
- C语言中的文本流与二进制流的区别(一)
- android.os.Environment
- 日期处理大全
- C语言中文本文件 和 二进制文件 流的区别(二)
- LEMP构建高性能WEB服务器(CentOS+Nginx+PHP+MySQL) (v3)
- DropDownList绑定数据时选择数据问题
- openssl移植的arm开发板全过程
- ACM上一些常见问题解答
- Tomcat
- Mac OS Lion 10.7正式版种子文件