liblog: logcat: Add year and zone to date on each line
- '-v year' modifier adds the four digit year prefix
- '-v <timezone>' modifier sets and prints the timezone suffix
- Only promise in logcat to support UTC as a timezone since
all others are based on the configured environment
- '-v zone' modifier toggles the timezone suffix on or off
- '-T YYYY-MM-DD HH:MM:SS.mmm...' format is added
Bug: 23668700
Change-Id: I7521c1efb7455dc9a25434fce72a69a65dcf72ea
diff --git a/include/log/logprint.h b/include/log/logprint.h
index 4b812cc..26b1ee5 100644
--- a/include/log/logprint.h
+++ b/include/log/logprint.h
@@ -36,10 +36,12 @@
FORMAT_TIME,
FORMAT_THREADTIME,
FORMAT_LONG,
- /* The following three are modifiers to above formats */
+ /* The following are modifiers to above formats */
FORMAT_MODIFIER_COLOR, /* converts priority to color */
FORMAT_MODIFIER_TIME_USEC, /* switches from msec to usec time precision */
FORMAT_MODIFIER_PRINTABLE, /* converts non-printable to printable escapes */
+ FORMAT_MODIFIER_YEAR, /* Adds year to date */
+ FORMAT_MODIFIER_ZONE, /* Adds zone to date */
} AndroidLogPrintFormat;
typedef struct AndroidLogFormat_t AndroidLogFormat;