类javax.mail.search.ReceivedDateTerm源码实例Demo

下面列出了怎么用javax.mail.search.ReceivedDateTerm的API类实例代码及写法,或者点击链接到github查看源代码。

源代码1 项目: hop   文件: MailConnection.java

/**
 * Set filter on message received date.
 *
 * @param receiveddate messages will be filtered on receiveddate
 */
public void setReceivedDateTermEQ( Date receiveddate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new ReceivedDateTerm( ComparisonTerm.EQ, receiveddate ) );
  }
}
 
源代码2 项目: hop   文件: MailConnection.java

/**
 * Set filter on message received date.
 *
 * @param futureDate messages will be filtered on futureDate
 */
public void setReceivedDateTermLT( Date futureDate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new ReceivedDateTerm( ComparisonTerm.LT, futureDate ) );
  }
}
 
源代码3 项目: hop   文件: MailConnection.java

/**
 * Set filter on message received date.
 *
 * @param pastDate messages will be filtered on pastDate
 */
public void setReceivedDateTermGT( Date pastDate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new ReceivedDateTerm( ComparisonTerm.GT, pastDate ) );
  }
}
 
源代码4 项目: hop   文件: MailConnection.java

public void setReceivedDateTermBetween( Date beginDate, Date endDate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new AndTerm( new ReceivedDateTerm( ComparisonTerm.LT, endDate ), new ReceivedDateTerm(
      ComparisonTerm.GT, beginDate ) ) );
  }
}
 
源代码5 项目: greenmail   文件: SearchTermBuilder.java

private static SearchTermBuilder createReceivedDateTermBuilder(final int searchTerm) {
    return new SearchTermBuilder() {
        @Override
        public SearchTerm build() {
            return new ReceivedDateTerm(searchTerm, parseDate(getParameters()));
        }
    };
}
 
源代码6 项目: pentaho-kettle   文件: MailConnection.java

/**
 * Set filter on message received date.
 *
 * @param receiveddate
 *          messages will be filtered on receiveddate
 */
public void setReceivedDateTermEQ( Date receiveddate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new ReceivedDateTerm( ComparisonTerm.EQ, receiveddate ) );
  }
}
 
源代码7 项目: pentaho-kettle   文件: MailConnection.java

/**
 * Set filter on message received date.
 *
 * @param futureDate
 *          messages will be filtered on futureDate
 */
public void setReceivedDateTermLT( Date futureDate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new ReceivedDateTerm( ComparisonTerm.LT, futureDate ) );
  }
}
 
源代码8 项目: pentaho-kettle   文件: MailConnection.java

/**
 * Set filter on message received date.
 *
 * @param pastDate
 *          messages will be filtered on pastDate
 */
public void setReceivedDateTermGT( Date pastDate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new ReceivedDateTerm( ComparisonTerm.GT, pastDate ) );
  }
}
 
源代码9 项目: pentaho-kettle   文件: MailConnection.java

public void setReceivedDateTermBetween( Date beginDate, Date endDate ) {
  if ( this.protocol == MailConnectionMeta.PROTOCOL_POP3 ) {
    log.logError( BaseMessages.getString( PKG, "MailConnection.Error.ReceivedDatePOP3Unsupported" ) );
  } else {
    addSearchTerm( new AndTerm( new ReceivedDateTerm( ComparisonTerm.LT, endDate ), new ReceivedDateTerm(
      ComparisonTerm.GT, beginDate ) ) );
  }
}
 
 类所在包
 同包方法