public enum WriteType extends Enum<WriteType>
Enum Constant and Description |
---|
ASYNC_THROUGH
Write the file asynchronously to the under fs (either must cache or must through).
|
CACHE_THROUGH
Write the file synchronously to the under fs, and also try to cache it,
|
MUST_CACHE
Write the file and must cache it.
|
THROUGH
Write the file synchronously to the under fs, no cache.
|
TRY_CACHE
Write the file and try to cache it.
|
Modifier and Type | Method and Description |
---|---|
static WriteType |
getOpType(String op)
Parse the write type
|
int |
getValue()
Return the value of the write type
|
boolean |
isAsync() |
boolean |
isCache() |
boolean |
isMustCache() |
boolean |
isThrough() |
static WriteType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static WriteType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final WriteType MUST_CACHE
public static final WriteType TRY_CACHE
public static final WriteType CACHE_THROUGH
public static final WriteType THROUGH
public static final WriteType ASYNC_THROUGH
public static WriteType[] values()
for (WriteType c : WriteType.values()) System.out.println(c);
public static WriteType valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static WriteType getOpType(String op) throws IOException
op
- the String format of the write typeIOException
public int getValue()
public boolean isAsync()
public boolean isCache()
public boolean isMustCache()
public boolean isThrough()
Copyright © 2014. All rights reserved.