|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
java.lang.Objectorg.eclipse.jetty.util.DateCache
public class DateCache
Date Format Cache. Computes String representations of Dates and caches the results so that subsequent requests within the same minute will be fast. Only format strings that contain either "ss" or "ss.SSS" are handled. The timezone of the date may be included as an ID with the "zzz" format string or as an offset with the "ZZZ" format string. If consecutive calls are frequently very different, then this may be a little slower than a normal DateFormat.
| 字段摘要 | |
|---|---|
static String |
DEFAULT_FORMAT
|
| 构造方法摘要 | |
|---|---|
DateCache()
Constructor. |
|
DateCache(String format)
Constructor. |
|
DateCache(String format,
DateFormatSymbols s)
|
|
DateCache(String format,
Locale l)
|
|
| 方法摘要 | |
|---|---|
String |
format(Date inDate)
Format a date according to our stored formatter. |
String |
format(long inDate)
Format a date according to our stored formatter. |
void |
format(long inDate,
StringBuilder buffer)
Format to string buffer. |
SimpleDateFormat |
getFormat()
Get the format. |
String |
getFormatString()
|
TimeZone |
getTimeZone()
|
int |
lastMs()
|
String |
now()
|
void |
setTimeZone(TimeZone tz)
Set the timezone. |
void |
setTimeZoneID(String timeZoneId)
Set the timezone. |
| 从类 java.lang.Object 继承的方法 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| 字段详细信息 |
|---|
public static String DEFAULT_FORMAT
| 构造方法详细信息 |
|---|
public DateCache()
public DateCache(String format)
public DateCache(String format,
Locale l)
public DateCache(String format,
DateFormatSymbols s)
| 方法详细信息 |
|---|
public void setTimeZone(TimeZone tz)
tz - TimeZonepublic TimeZone getTimeZone()
public void setTimeZoneID(String timeZoneId)
timeZoneId - TimeZoneId the ID of the zone as used by
TimeZone.getTimeZone(id)public String format(Date inDate)
inDate -
public String format(long inDate)
inDate -
public void format(long inDate,
StringBuilder buffer)
inDate - Date the formatbuffer - StringBuilderpublic SimpleDateFormat getFormat()
public String getFormatString()
public String now()
public int lastMs()
|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||