Packagejp.nium.utils
Classpublic final class DateUtil

DateUtil クラスは、日付データ操作のためのユーティリティクラスです。 The DateUtil class is an utility class for date data operation.



Public Methods
 MethodDefined by
  
format(date:Date, str:String):String
[static]
DateUtil
  
getMaxDateLength(date:Date):int
[static] 対象の月の最大日数を返します。 Returns the maximum day of the month.
DateUtil
  
w3cdtfToDate(time:String):Date
[static] W3CDTF 形式のストリングから Date インスタンスを生成して返します。
DateUtil
Public Constants
 ConstantDefined by
  MAX_HOUR : int = 24
[static] 時間の最大値を表す定数を取得します。 Returns the maximum value of the hour.
DateUtil
  MAX_MILLISECOND : int = 1000
[static] ミリ秒の最大値を表す定数を取得します。 Returns the maximum value of the millisecond.
DateUtil
  MAX_MINUTE : int = 60
[static] 分の最大値を表す定数を取得します。 Returns the maximum value of the minuite.
DateUtil
  MAX_SECOND : int = 60
[static] 秒の最大値を表す定数を取得します。 Returns the maximum value of the second.
DateUtil
  ONE_DAY : int = 86400000
[static] 1 日をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1day by millisecond unit.
DateUtil
  ONE_HOUR : int = 3600000
[static] 1 時間をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1hour by millisecond unit.
DateUtil
  ONE_MILLISECOND : int = 1
[static] 1 ミリ秒をミリ秒単位で表した定数を取得します。 Returns the fixed value which express the 1 millisecond by millisecond unit.
DateUtil
  ONE_MINUTE : int = 60000
[static] 1 分をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1minuite by millisecond unit.
DateUtil
  ONE_SECOND : int = 1000
[static] 1 秒をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1second by millisecond unit.
DateUtil
Method detail
format()method
public static function format(date:Date, str:String):String

Parameters
date:Date
 
str:String

Returns
String

Example
   

getMaxDateLength()method 
public static function getMaxDateLength(date:Date):int

対象の月の最大日数を返します。 Returns the maximum day of the month.

Parameters
date:Date最大日数を取得したい Date インスタンスです。 The date istance to get the maximum day.

Returns
int最大日数です。 The maximum day.

Example
   

w3cdtfToDate()method 
public static function w3cdtfToDate(time:String):Date

W3CDTF 形式のストリングから Date インスタンスを生成して返します。

Parameters
time:StringW3CDTF 形式のストリングです。

Returns
Date生成された Date インスタンスです。

Example
   

Constant detail
MAX_HOURconstant
public static const MAX_HOUR:int = 24

時間の最大値を表す定数を取得します。 Returns the maximum value of the hour.

MAX_MILLISECONDconstant 
public static const MAX_MILLISECOND:int = 1000

ミリ秒の最大値を表す定数を取得します。 Returns the maximum value of the millisecond.

MAX_MINUTEconstant 
public static const MAX_MINUTE:int = 60

分の最大値を表す定数を取得します。 Returns the maximum value of the minuite.

MAX_SECONDconstant 
public static const MAX_SECOND:int = 60

秒の最大値を表す定数を取得します。 Returns the maximum value of the second.

ONE_DAYconstant 
public static const ONE_DAY:int = 86400000

1 日をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1day by millisecond unit.

ONE_HOURconstant 
public static const ONE_HOUR:int = 3600000

1 時間をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1hour by millisecond unit.

ONE_MILLISECONDconstant 
public static const ONE_MILLISECOND:int = 1

1 ミリ秒をミリ秒単位で表した定数を取得します。 Returns the fixed value which express the 1 millisecond by millisecond unit.

ONE_MINUTEconstant 
public static const ONE_MINUTE:int = 60000

1 分をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1minuite by millisecond unit.

ONE_SECONDconstant 
public static const ONE_SECOND:int = 1000

1 秒をミリ秒単位で表した定数を取得します。 Returns the fixed value of 1second by millisecond unit.