Class WindowsDate

java.lang.Object
java.util.Date
jp.gr.java_conf.dangan.util.WindowsDate
All Implemented Interfaces:
Serializable, Cloneable, Comparable<Date>

public class WindowsDate extends Date implements Cloneable
Windows??FILETIME?`??????????????Date???h?χ?N???X?B
FILETIME ?? 1601?N 1?? 1?? 0??0??0?b???????o???????? 100?i?m?b?P????????64?r?b?g?l?B
?}???N???X???? FILETIME ?? long(64?r?b?g?l)???????????????? ???{?I???????????????????B
1601?N 1?? 1?? 0??0??0?b???O???????????‘???‘?????? WindowsDate( Date date ) ???AWindowsDate.setTime( long time )???g?p?????B
 -- revision history --
 $Log: WindowsDate.java,v $
 Revision 1.1  2002/12/05 00:00:00  dangan
 [maintenance]
     javadoc ?R?????g???X?y???~?X???C???B
     ?\?[?X????

 Revision 1.0  2002/08/05 00:00:00  dangan
 add to version control
 [bug fix] 
     set?n???\?b?h?? ?????O?????????Z?b?g????????????
     ???O?????‹???P?[?X?????????????????????????s???????‘?????????B
     checkRange ???????????????????????‘???B
 [maintenance]
     ?^?u???p?~
     ???C?Z???X?χ???C??

 
Version:
$Revision: 1.1 $
Author:
$Author: dangan $
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final long
    FILETIME?`?????f?[?^???Ajava.util.Date.getTime() ?? ?????????????`?????????????? 100?i?m?Z?J???h?P?????????????l?B ???N?A?[?b?????l?χ?????????‘???‘?B
  • Constructor Summary

    Constructors
    Constructor
    Description
    ?f?t?H???g?R???X?g???N?^?B ???????????????????? WindowsDate???\?z?????B ?i?m?b?P?????????????????????‘?????A0?????????????B
    WindowsDate(long time)
    ????????64?r?b?g??FILETIME?`???????????????? ?V???‘WindowsDate???\?z?????B
    date?????????????????\?? WindowsDate???\?z?????B
    date?? WindowsDate ???C???X?^???X?????? ?i?m?b?P???????????R?s?[?????????A???????O???????? ?i?m?b?P???????????? 0 ?????????????B
  • Method Summary

    Modifier and Type
    Method
    Description
    ?}???I?u?W?F?N?g???R?s?[???????B
    long
    ?}?? WindowsDate???????????????? FILETIME ?`?????????B
    void
    setDate(int date)
    Deprecated. 
    void
    setHours(int hours)
    Deprecated. 
    void
    setMinutes(int minutes)
    Deprecated. 
    void
    setMonth(int month)
    Deprecated. 
    void
    setSeconds(int seconds)
    Deprecated. 
    void
    setTime(long time)
    ?}?? WindowsDate ???????????? 1970?N1??1?? 00:00:00 GMT???? time ?~???b?o?????????????????????B
    ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
    void
    setWindowsTime(long time)
    ?}?? WindowsDate ?? FILETIME?`???????????????????????B
    void
    setYear(int year)
    Deprecated. 

    Methods inherited from class java.lang.Object

    finalize, getClass, notify, notifyAll, wait, wait, wait
  • Field Details

    • TIME_DIFFERENCE

      public static final long TIME_DIFFERENCE
      FILETIME?`?????f?[?^???Ajava.util.Date.getTime() ?? ?????????????`?????????????? 100?i?m?Z?J???h?P?????????????l?B ???N?A?[?b?????l?χ?????????‘???‘?B
      See Also:
  • Constructor Details

    • WindowsDate

      public WindowsDate()
      ?f?t?H???g?R???X?g???N?^?B ???????????????????? WindowsDate???\?z?????B ?i?m?b?P?????????????????????‘?????A0?????????????B
      Throws:
      IllegalArgumentException - ???????????? FILETIME ?`?????\???????? ?????O???????????B
    • WindowsDate

      public WindowsDate(Date date)
      date?????????????????\?? WindowsDate???\?z?????B
      date?? WindowsDate ???C???X?^???X?????? ?i?m?b?P???????????R?s?[?????????A???????O???????? ?i?m?b?P???????????? 0 ?????????????B
      Parameters:
      date - ?V?????\?z?????? WindowsDate ???????????????????????? Date ???I?u?W?F?N?g
      Throws:
      IllegalArgumentException - ???????????? FILETIME ?`?????\???????? ?????O???????????B
    • WindowsDate

      public WindowsDate(long time)
      ????????64?r?b?g??FILETIME?`???????????????? ?V???‘WindowsDate???\?z?????B
      Parameters:
      time - FILETIME?`????????????
  • Method Details

    • clone

      public Object clone()
      ?}???I?u?W?F?N?g???R?s?[???????B
      Overrides:
      clone in class Date
      Returns:
      ?}??WindowsDate?I?u?W?F?N?g??????
    • setYear

      public void setYear(int year)
      Deprecated.
      ?}?? WindowsDate ???????N?? year ?? ?w?????????l??1900???????????????????????B
      ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
      Overrides:
      setYear in class Date
      Parameters:
      year - 1900???????}???????????\???????? ?N???l
      Throws:
      IllegalArgumentException - year ?????X???????}?? FILETIME?`???????????‘ ??????????????????????
    • setMonth

      public void setMonth(int month)
      Deprecated.
      ?}?? WindowsDate ?????????? month ???w?????????l???????????B
      ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
      Overrides:
      setMonth in class Date
      Parameters:
      month - 0??1???A1??2???????????????????l
      Throws:
      IllegalArgumentException - month ?????X???????}?? FILETIME?`???????????‘ ??????????????????????
    • setDate

      public void setDate(int date)
      Deprecated.
      ?}?? WindowsDate ?????? ???????? ???????????????? date ???w?????????l???????????B
      ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
      Overrides:
      setDate in class Date
      Parameters:
      date - 1??1???A2??2???????????????????l
      Throws:
      IllegalArgumentException - date ?????X???????}?? FILETIME?`???????????‘ ??????????????????????
    • setHours

      public void setHours(int hours)
      Deprecated.
      ?}?? WindowsDate ???????????????????????? hours ???w?????????l???????????B
      ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
      Overrides:
      setHours in class Date
      Parameters:
      hours - ???????l
      Throws:
      IllegalArgumentException - hours ?????X???????}?? FILETIME?`???????????‘ ??????????????????????
    • setMinutes

      public void setMinutes(int minutes)
      Deprecated.
      ?}?? WindowsDate ???????????????????????? minutes ???w?????????l???????????B
      ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
      Overrides:
      setMinutes in class Date
      Parameters:
      minutes - ?????l
      Throws:
      IllegalArgumentException - minutes ?????X???????}?? FILETIME?`???????????‘ ??????????????????????
    • setSeconds

      public void setSeconds(int seconds)
      Deprecated.
      ?}?? WindowsDate ???????????????????b???? secounds ???w?????????l???????????B
      ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
      Overrides:
      setSeconds in class Date
      Parameters:
      secounds - ?b??
      Throws:
      IllegalArgumentException - secounds ?????X???????}?? FILETIME?`???????????‘ ??????????????????????
    • setTime

      public void setTime(long time)
      ?}?? WindowsDate ???????????? 1970?N1??1?? 00:00:00 GMT???? time ?~???b?o?????????????????????B
      ?}?????\?b?h???????`?F?b?N???s???????????????χ???????B
      Overrides:
      setTime in class Date
      Parameters:
      time - 1970?N1??1?? 00:00:00GMT ???????o???~???b
      Throws:
      IllegalArgumentException - time ??FILETIME?`???????????‘ ???????????????????‘??????
    • setWindowsTime

      public void setWindowsTime(long time)
      ?}?? WindowsDate ?? FILETIME?`???????????????????????B
      Parameters:
      time - FILETIME?`????????????
    • getWindowsTime

      public long getWindowsTime()
      ?}?? WindowsDate???????????????? FILETIME ?`?????????B
      Returns:
      FILETIME?`?????l