DateTerm (Java EE 5)

Java EE API


javax.mail.search Class DateTerm

java.lang.Object
  extended by javax.mail.search.SearchTerm
      extended by javax.mail.search.ComparisonTerm
          extended by javax.mail.search.DateTerm
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ReceivedDateTerm, SentDateTerm

public abstract class DateTerm
extends ComparisonTerm


此类实现 Date 的比较。
英文文档:

This class implements comparisons for Dates

Author:
Bill Shannon, John Mani
See Also:
Serialized Form

Field Summary
protected  Date
 
Fields inherited from class javax.mail.search.ComparisonTerm
 
Constructor Summary
protected
 
Method Summary
 boolean
 int
 Date
 int
protected  boolean
 
Methods inherited from class javax.mail.search.SearchTerm
 
Methods inherited from class java.lang.Object
 

Field Detail

英文文档:

date

protected Date date
The date.

Constructor Detail

protected DateTerm(int comparison, java.util.Date date)
构造方法。
comparison 比较类型
date 要进行比较的 Date
英文文档:

DateTerm

protected DateTerm(int comparison,
                   Date date)
Constructor.

Parameters:
comparison - the comparison type
date - The Date to be compared against

Method Detail

public java.util.Date getDate()
返回要与之比较的 Date。
英文文档:

getDate

public Date getDate()
Return the Date to compare with.


public int getComparison()
返回比较类型。
英文文档:

getComparison

public int getComparison()
Return the type of comparison.


protected boolean match(java.util.Date d)
日期比较方法。
d 将构造方法中的日期与此日期进行比较
return 如果日期匹配,返回 true;否则返回 false
英文文档:

match

protected boolean match(Date d)
The date comparison method.

Parameters:
d - the date in the constructor is compared with this date
Returns:
true if the dates match, otherwise false

public boolean equals(Object obj)
相等性比较。
英文文档:

equals

public boolean equals(Object obj)
Equality comparison.

Overrides:
equals in class ComparisonTerm

public int hashCode()
计算此对象的 hashCode。
英文文档:

hashCode

public int hashCode()
Compute a hashCode for this object.

Overrides:
hashCode in class ComparisonTerm


Submit a bug or feature

Copyright 2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.

一看就知道只有菜鸟才干这么无知的事啦。

PS : 未经我党受权你也可自由散发此文档。 如有任何错误请自行修正;若因此而造成任何损失请直接找人民主席,请勿与本人联系。谢谢!