|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.flume.formatter.output.BucketPath
public class BucketPath
Field Summary | |
---|---|
static String |
TAG_REGEX
These are useful to other classes which might want to search for tags in strings. |
static Pattern |
tagPattern
|
Constructor Summary | |
---|---|
BucketPath()
|
Method Summary | |
---|---|
static boolean |
containsTag(String in)
Deprecated. |
static String |
escapeString(String in,
Map<String,String> headers)
Replace all substrings of form %{tagname} with get(tagname).toString() and all shorthand substrings of form %x with a special value. |
static String |
escapeString(String in,
Map<String,String> headers,
boolean needRounding,
int unit,
int roundDown)
A wrapper around escapeString(String, Map, TimeZone, boolean, int, int,
boolean)
with the timezone set to the default. |
static String |
escapeString(String in,
Map<String,String> headers,
TimeZone timeZone,
boolean needRounding,
int unit,
int roundDown,
boolean useLocalTimeStamp)
Replace all substrings of form %{tagname} with get(tagname).toString() and all shorthand substrings of form %x with a special value. |
static String |
expandShorthand(char c)
Deprecated. |
static Clock |
getClock()
|
static Map<String,String> |
getEscapeMapping(String in,
Map<String,String> headers)
Deprecated. |
static Map<String,String> |
getEscapeMapping(String in,
Map<String,String> headers,
boolean needRounding,
int unit,
int roundDown)
Deprecated. |
static String |
replaceShorthand(char c,
Map<String,String> headers)
Deprecated. |
static String |
replaceShorthand(char c,
Map<String,String> headers,
boolean needRounding,
int unit,
int roundDown)
Deprecated. |
static String |
replaceShorthand(char c,
Map<String,String> headers,
TimeZone timeZone,
boolean needRounding,
int unit,
int roundDown,
boolean useLocalTimestamp)
Deprecated. |
protected static String |
replaceShorthand(char c,
Map<String,String> headers,
TimeZone timeZone,
boolean needRounding,
int unit,
int roundDown,
boolean useLocalTimestamp,
long ts)
Not intended as a public API |
static void |
setClock(Clock clk)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String TAG_REGEX
public static final Pattern tagPattern
Constructor Detail |
---|
public BucketPath()
Method Detail |
---|
@Deprecated public static boolean containsTag(String in)
@Deprecated public static String expandShorthand(char c)
@Deprecated public static String replaceShorthand(char c, Map<String,String> headers)
This static method will be REMOVED in a future version of Flume
@Deprecated public static String replaceShorthand(char c, Map<String,String> headers, boolean needRounding, int unit, int roundDown)
replaceShorthand(char, Map, TimeZone, boolean, int,
int, boolean)
with the timezone set to the default.
This static method will be REMOVED in a future version of Flume
@Deprecated public static String replaceShorthand(char c, Map<String,String> headers, TimeZone timeZone, boolean needRounding, int unit, int roundDown, boolean useLocalTimestamp)
This static method will be REMOVED in a future version of Flume
c
- - The character to replace.headers
- - Event headerstimeZone
- - The timezone to use for formatting the timestampneedRounding
- - Should the timestamp be rounded down?unit
- - if needRounding is true, what unit to round down to. This
must be one of the units specified by Calendar
-
HOUR, MINUTE or SECOND. Defaults to second, if none of these are present.
Ignored if needRounding is false.roundDown
- - if needRounding is true,
The time should be rounded to the largest multiple of this
value, smaller than the time supplied, defaults to 1, if <= 0(rounds off
to the second/minute/hour immediately lower than the timestamp supplied.
Ignored if needRounding is false.
protected static String replaceShorthand(char c, Map<String,String> headers, TimeZone timeZone, boolean needRounding, int unit, int roundDown, boolean useLocalTimestamp, long ts)
public static String escapeString(String in, Map<String,String> headers)
public static String escapeString(String in, Map<String,String> headers, boolean needRounding, int unit, int roundDown)
escapeString(String, Map, TimeZone, boolean, int, int,
boolean)
with the timezone set to the default.
public static String escapeString(String in, Map<String,String> headers, TimeZone timeZone, boolean needRounding, int unit, int roundDown, boolean useLocalTimeStamp)
needRounding
- - Should the timestamp be rounded down?unit
- - if needRounding is true, what unit to round down to. This
must be one of the units specified by Calendar
-
HOUR, MINUTE or SECOND. Defaults to second, if none of these are present.
Ignored if needRounding is false.roundDown
- - if needRounding is true,
The time should be rounded to the largest multiple of this
value, smaller than the time supplied, defaults to 1, if <= 0(rounds off
to the second/minute/hour immediately lower than the timestamp supplied.
Ignored if needRounding is false.
@Deprecated public static Map<String,String> getEscapeMapping(String in, Map<String,String> headers)
@Deprecated public static Map<String,String> getEscapeMapping(String in, Map<String,String> headers, boolean needRounding, int unit, int roundDown)
public static void setClock(Clock clk)
public static Clock getClock()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |