當前位置: 首頁>>代碼示例>>Java>>正文


Java EmailAddressCriteria類代碼示例

本文整理匯總了Java中org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria的典型用法代碼示例。如果您正苦於以下問題:Java EmailAddressCriteria類的具體用法?Java EmailAddressCriteria怎麽用?Java EmailAddressCriteria使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


EmailAddressCriteria類屬於org.hazlewood.connor.bottema.emailaddress包,在下文中一共展示了EmailAddressCriteria類的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: MailerGenericBuilder

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
/**
 * Sets defaults configured for proxy host, proxy port, proxy username, proxy password and proxy bridge port (used in authenticated proxy).
 * <p>
 * <strong>Note:</strong> Any builder methods invoked after this will override the default value.
 */
MailerGenericBuilder() {
	if (hasProperty(PROXY_HOST)) {
		withProxyHost((String) getProperty(PROXY_HOST));
	}
	if (hasProperty(PROXY_PORT)) {
		withProxyPort((Integer) getProperty(PROXY_PORT));
	}
	if (hasProperty(PROXY_USERNAME)) {
		withProxyUsername((String) getProperty(PROXY_USERNAME));
	}
	if (hasProperty(PROXY_PASSWORD)) {
		withProxyPassword((String) getProperty(PROXY_PASSWORD));
	}
	
	withProxyBridgePort(ConfigLoader.valueOrProperty(null, Property.PROXY_SOCKS5BRIDGE_PORT, DEFAULT_PROXY_BRIDGE_PORT));
	withDebugLogging(ConfigLoader.valueOrProperty(null, Property.JAVAXMAIL_DEBUG, false));
	withSessionTimeout(ConfigLoader.valueOrProperty(null, Property.DEFAULT_SESSION_TIMEOUT_MILLIS, DEFAULT_SESSION_TIMEOUT_MILLIS));
	withThreadPoolSize(ConfigLoader.valueOrProperty(null, Property.DEFAULT_POOL_SIZE, DEFAULT_POOL_SIZE));
	withTransportModeLoggingOnly(ConfigLoader.valueOrProperty(null, Property.TRANSPORT_MODE_LOGGING_ONLY, DEFAULT_TRANSPORT_MODE_LOGGING_ONLY));
	
	withEmailAddressCriteria(EmailAddressCriteria.RFC_COMPLIANT);
	trustingAllHosts(true);
}
 
開發者ID:bbottema,項目名稱:simple-java-mail,代碼行數:29,代碼來源:MailerGenericBuilder.java

示例2: assertEmail

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
private static void assertEmail(String emailaddress, boolean expected) {
	final boolean isValid = EmailAddressValidator.isValid(emailaddress, EmailAddressCriteria.RFC_COMPLIANT);
	if (isValid != expected) {
		throw new IllegalArgumentException(String.format("%s (expected: %s, but was: %s)", emailaddress, expected, isValid));
	}
}
 
開發者ID:bbottema,項目名稱:email-rfc2822-validator,代碼行數:7,代碼來源:TestClass.java

示例3: getEmailAddressCriteria

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
/**
 * @see #withEmailAddressCriteria(EnumSet)
 */
public EnumSet<EmailAddressCriteria> getEmailAddressCriteria() {
	return emailAddressCriteria;
}
 
開發者ID:bbottema,項目名稱:simple-java-mail,代碼行數:7,代碼來源:MailerGenericBuilder.java

示例4: getEmailAddressCriteria

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
/**
 * @return The effective validation criteria used for email validation. Returns an empty set if no validation should be done.
 */
@Nonnull
public EnumSet<EmailAddressCriteria> getEmailAddressCriteria() {
	return emailAddressCriteria;
}
 
開發者ID:bbottema,項目名稱:simple-java-mail,代碼行數:8,代碼來源:Mailer.java

示例5: setEmailAddressCriteria

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
/**
 * Overrides the default email address validation restrictions {@link #emailAddressCriteria} when validating and sending emails using the current
 * <code>Mailer</code> instance.
 */
public void setEmailAddressCriteria(final EnumSet<EmailAddressCriteria> emailAddressCriteria) {
	this.emailAddressCriteria = emailAddressCriteria;
}
 
開發者ID:QianWorks,項目名稱:qianworks-meican,代碼行數:8,代碼來源:Mailer.java

示例6: withEmailAddressCriteria

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
/**
 * Sets the email address validation restrictions when validating and sending emails using the current <code>Mailer</code> instance.
 * <p>
 * Defaults to {@link EmailAddressCriteria#RFC_COMPLIANT} if not overridden with a ({@code null}) value.
 *
 * @see EmailAddressCriteria
 * @see #clearEmailAddressCriteria()
 * @see #resetEmailAddressCriteria()
 */
public T withEmailAddressCriteria(@Nonnull final EnumSet<EmailAddressCriteria> emailAddressCriteria) {
	this.emailAddressCriteria = emailAddressCriteria.clone();
	return (T) this;
}
 
開發者ID:bbottema,項目名稱:simple-java-mail,代碼行數:14,代碼來源:MailerGenericBuilder.java

示例7: resetEmailAddressCriteria

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
/**
 * Resets emailAddressCriteria to {@link EmailAddressCriteria#RFC_COMPLIANT}.
 *
 * @see #withEmailAddressCriteria(EnumSet)
 * @see #clearEmailAddressCriteria()
 */
public T resetEmailAddressCriteria() {
	return withEmailAddressCriteria(EmailAddressCriteria.RFC_COMPLIANT);
}
 
開發者ID:bbottema,項目名稱:simple-java-mail,代碼行數:10,代碼來源:MailerGenericBuilder.java

示例8: clearEmailAddressCriteria

import org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria; //導入依賴的package包/類
/**
 * Removes all email address criteria, meaning validation won't take place.
 *
 * @see #withEmailAddressCriteria(EnumSet)
 * @see #resetEmailAddressCriteria()
 */
public T clearEmailAddressCriteria() {
	return withEmailAddressCriteria(EnumSet.noneOf(EmailAddressCriteria.class));
}
 
開發者ID:bbottema,項目名稱:simple-java-mail,代碼行數:10,代碼來源:MailerGenericBuilder.java


注:本文中的org.hazlewood.connor.bottema.emailaddress.EmailAddressCriteria類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。