Skip to content

Commit

Permalink
#43: Add 'Properties' ctors for Inbox/Outbox
Browse files Browse the repository at this point in the history
  • Loading branch information
dgroup committed Apr 14, 2019
1 parent 972a8b6 commit ad392eb
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
*.iws
*.class
/.idea/
/.tmp/
/.tmp/
*.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,14 @@ public final class JavaxMailInbox implements Inbox {
*/
private final Modes modes;

/**
* Ctor.
* @param props The mail server connection properties.
*/
public JavaxMailInbox(final Properties props) {
this(() -> props);
}

/**
* Ctor.
* @param props The mail server connection properties.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@
* objects in accordance with RFC822 syntax.
*
* @since 0.1.0
* @todo #/DEV Change the email to LowLevel case in order to prevent duplication of emails
* due to different case.
*/
public final class Addresses implements Scalar<InternetAddress[]> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,14 @@ public class JavaxMailOutbox implements Outbox {
*/
private final Scalar<Session> session;

/**
* Ctor.
* @param props The postman configuration properties.
*/
public JavaxMailOutbox(final Properties props) {
this(() -> props);
}

/**
* Ctor.
* @param props The postman configuration properties.
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/io/github/dgroup/mbox4j/package-info.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,7 @@
* The postman(s) for email sending.
*
* @since 0.1.0
* @todo #/DEV Add instructions to readme.md regarding <em>javax.mail</em>
* dependency (or other libs) in order to avoid java.lang.NoClassDefFoundError.
*/
package io.github.dgroup.mbox4j;
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@
* Gmail incoming/outgoing SMTP server properties.
*
* @since 0.1.0
* @todo #/DEV Move the smtp properties to the src/main/java module
* as it can be used for other repositories.
* The new package is <em>io.github.dgroup.mbox4j.properties</em>.
*/
public final class GmailSmtpProperties implements Scalar<Properties> {

Expand Down

3 comments on commit ad392eb

@0pdd
Copy link
Collaborator

@0pdd 0pdd commented on ad392eb Apr 14, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Puzzle DEV-ca1acbfb discovered in src/main/java/io/github/dgroup/mbox4j/outbox/javax/Addresses.java and submitted as #45. Please, remember that the puzzle was not necessarily added in this particular commit. Maybe it was added earlier, but we discovered it only now.

@0pdd
Copy link
Collaborator

@0pdd 0pdd commented on ad392eb Apr 14, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Puzzle DEV-93efb375 discovered in src/main/java/io/github/dgroup/mbox4j/package-info.java and submitted as #46. Please, remember that the puzzle was not necessarily added in this particular commit. Maybe it was added earlier, but we discovered it only now.

@0pdd
Copy link
Collaborator

@0pdd 0pdd commented on ad392eb Apr 14, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Puzzle DEV-0f19decd discovered in src/test/java/io/github/dgroup/mbox4j/GmailSmtpProperties.java and submitted as #47. Please, remember that the puzzle was not necessarily added in this particular commit. Maybe it was added earlier, but we discovered it only now.

Please sign in to comment.