Ignore:
Timestamp:
Mar 13, 2007, 11:55:49 AM (18 years ago)
Author:
イグトランス (egtra)
Message:

GetHashCodeを実装

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Include/Classes/System/DateTime.ab

    r163 r166  
    8282
    8383    'Copy Constructor
    84     Sub DateTime( ByRef datetime As DateTime )
     84    Sub DateTime(ByRef datetime As DateTime)
    8585        This.m_Date = datetime.m_Date
    8686    End Sub
     
    8989    End Sub
    9090
    91     Function Operator+ (ByRef value As TimeSpan) As DateTime
     91    Function Operator + (ByRef value As TimeSpan) As DateTime
    9292        Dim date As DateTime(Ticks + value.Ticks)
    9393        Return date
    9494    End Function
    9595
    96     Function Operator- (ByRef value As DateTime) As TimeSpan
     96    Function Operator - (ByRef value As DateTime) As TimeSpan
    9797        Return TimeSpan.FromTicks(Ticks - value.Ticks)
    9898    End Function
    9999
    100     Function Operator- (ByRef value As TimeSpan) As DateTime
     100    Function Operator - (ByRef value As TimeSpan) As DateTime
    101101        Dim date As DateTime(Ticks - value.Ticks)
    102102        Return date
     
    254254            Return False
    255255        End If
     256    End Function
     257
     258    Override Function GetHashCode() As Long
     259        Return HIDWORD(m_Date) Xor LODWORD(m_Date)
    256260    End Function
    257261
Note: See TracChangeset for help on using the changeset viewer.