Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix java package names #306

Merged
merged 3 commits into from
Oct 23, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 2 additions & 7 deletions src/main/java/com/sendgrid/helpers/mail/Mail.java
Original file line number Diff line number Diff line change
@@ -1,16 +1,11 @@
package com.sendgrid;
package com.sendgrid.helpers.mail;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.ObjectWriter;
import com.fasterxml.jackson.databind.SerializationFeature;
import com.sendgrid.helpers.mail.objects.*;

import java.io.IOException;
import java.util.ArrayList;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/sendgrid/helpers/mail/objects/ASM.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonIgnoreType;
import com.fasterxml.jackson.annotation.JsonInclude;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/sendgrid/helpers/mail/objects/Email.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
69 changes: 60 additions & 9 deletions src/main/java/com/sendgrid/helpers/mail/objects/MailSettings.java
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
import com.fasterxml.jackson.annotation.JsonProperty;

/**
* An object representing a collection of different mail
* settings that you can use to specify how you would
* like this email to be handled.
*/

@JsonInclude(Include.NON_DEFAULT)
public class MailSettings {
@JsonProperty("bcc") private BccSettings bccSettings;
Expand All @@ -16,11 +22,24 @@ public class MailSettings {
public BccSettings getBccSettings() {
return bccSettings;
}


/**
* Set the BCC settings.
* @param bccSettings the BCC settings.
*/
public void setBccSettings(BccSettings bccSettings) {
this.bccSettings = bccSettings;
}


/**
* A setting that allows you to bypass all unsubscribe
* groups and suppressions to ensure that the email is
* delivered to every single recipient. This should only
* be used in emergencies when it is absolutely necessary
* that every recipient receives your email.
* @return the bypass list setting.
*/

@JsonProperty("bypass_list_management")
public Setting getBypassListManagement() {
return bypassListManagement;
Expand All @@ -29,30 +48,62 @@ public Setting getBypassListManagement() {
public void setBypassListManagement(Setting bypassListManagement) {
this.bypassListManagement = bypassListManagement;
}


/**
* Get the the footer settings that you would like included on every email.
* @return the setting.
*/

@JsonProperty("footer")
public FooterSetting getFooterSetting() {
return footerSetting;
}


/**
* Set the the footer settings that you would like included on every email.
* @param footerSetting the setting.
*/
public void setFooterSetting(FooterSetting footerSetting) {
this.footerSetting = footerSetting;
}


/**
* Get sandbox mode. This allows you to send a test email to
* ensure that your request body is valid and formatted correctly.
* @return the sandbox mode setting.
*/

@JsonProperty("sandbox_mode")
public Setting getSandBoxMode() {
return sandBoxMode;
}


/**
* Set sandbox mode.
* @param sandBoxMode the sandbox mode setting.
*/
@JsonProperty("sandbox_mode")
public void setSandboxMode(Setting sandBoxMode) {
this.sandBoxMode = sandBoxMode;
}


/**
* Get the spam check setting. This allows you to test the
* content of your email for spam.
* @return the spam check setting.
*/

@JsonProperty("spam_check")
public SpamCheckSetting getSpamCheck() {
return spamCheckSetting;
}


/**
* Set the spam check setting. This allows you to test the
* content of your email for spam.
* @param spamCheckSetting the spam check setting.
*/

public void setSpamCheckSetting(SpamCheckSetting spamCheckSetting) {
this.spamCheckSetting = spamCheckSetting;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.sendgrid;
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
Expand Down
2 changes: 2 additions & 0 deletions src/test/java/com/sendgrid/TestRequiredFilesExist.java
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
package com.sendgrid;

import org.junit.Test;

import java.io.File;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.sendgrid.helpers;

import com.sendgrid.Attachments;
import com.sendgrid.helpers.mail.objects.Attachments;
import org.apache.commons.codec.binary.Base64;
import org.junit.Assert;
import org.junit.Test;
Expand Down
3 changes: 2 additions & 1 deletion src/test/java/com/sendgrid/helpers/ContentTest.java
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package com.sendgrid;
package com.sendgrid.helpers;

import org.junit.Assert;
import org.junit.Before;
import org.junit.Rule;
import org.junit.Test;
import com.sendgrid.helpers.mail.objects.Content;
import org.junit.rules.ExpectedException;

import java.util.ArrayList;
Expand Down
5 changes: 3 additions & 2 deletions src/test/java/com/sendgrid/helpers/MailTest.java
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package com.sendgrid;
package com.sendgrid.helpers;

import com.sendgrid.helpers.mail.Mail;
import com.sendgrid.helpers.mail.objects.*;
import com.fasterxml.jackson.databind.ObjectMapper;

import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;

import java.io.IOException;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.sendgrid.helpers.mail.objects;

import com.fasterxml.jackson.databind.ObjectMapper;
import com.sendgrid.BccSettings;
import com.sendgrid.ClickTrackingSetting;
import com.sendgrid.FooterSetting;
import com.sendgrid.GoogleAnalyticsSetting;
import com.sendgrid.OpenTrackingSetting;
import com.sendgrid.SpamCheckSetting;
import com.sendgrid.SubscriptionTrackingSetting;
import com.sendgrid.helpers.mail.objects.BccSettings;
import com.sendgrid.helpers.mail.objects.ClickTrackingSetting;
import com.sendgrid.helpers.mail.objects.FooterSetting;
import com.sendgrid.helpers.mail.objects.GoogleAnalyticsSetting;
import com.sendgrid.helpers.mail.objects.OpenTrackingSetting;
import com.sendgrid.helpers.mail.objects.SpamCheckSetting;
import com.sendgrid.helpers.mail.objects.SubscriptionTrackingSetting;
import org.junit.Assert;
import org.junit.Test;

Expand Down