public class PropertiesBasedGreenMailConfigurationBuilder extends Object
Example usage: GreenMailConfiguration config = new PropertyBasedGreenMailConfigurationBuilder().build(System.getProperties());
Example: user1:pwd1@localhost,user2:pwd2@0.0.0.0
Note: domain part must be DNS resolvable!
By default use the local-part of an email. Can be changed to full email.
| Modifier and Type | Field and Description |
|---|---|
static String |
GREENMAIL_AUTH_DISABLED
Disables authentication check.
|
static String |
GREENMAIL_USERS
Property for list of users.
|
static String |
GREENMAIL_USERS_LOGIN
Overrides the login for authentication for configured users (@see
GREENMAIL_USERS). |
| Constructor and Description |
|---|
PropertiesBasedGreenMailConfigurationBuilder() |
| Modifier and Type | Method and Description |
|---|---|
GreenMailConfiguration |
build(Properties properties)
Builds a configuration object based on given properties.
|
protected String |
buildEmailLogin(String localPart,
String domain) |
protected String |
buildLocalPartLogin(String localPart,
String domain) |
protected void |
extractAndAddUser(GreenMailConfiguration configuration,
BinaryOperator<String> buildLogin,
String user) |
public static final String GREENMAIL_USERS
public static final String GREENMAIL_USERS_LOGIN
GREENMAIL_USERS).
By default, use the local-part of an email and can be changed to full email (@see UsersLoginConfigurationType.EMAIL).
public static final String GREENMAIL_AUTH_DISABLED
public PropertiesBasedGreenMailConfigurationBuilder()
public GreenMailConfiguration build(Properties properties)
properties - the properties.protected void extractAndAddUser(GreenMailConfiguration configuration, BinaryOperator<String> buildLogin, String user)
Copyright © 2006–2022 Icegreen Technologies. All rights reserved.