Skip to content

Commit

Permalink
Merge pull request #5 from realexpayments-developers/master
Browse files Browse the repository at this point in the history
Realex Payments Remote Java SDK - v1.0.1
  • Loading branch information
RealexITSO committed Aug 12, 2015
2 parents afda01d + b4f90c0 commit e75ec89
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 17 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ Add this dependency to your project's POM:
<dependency>
<groupId>com.realexpayments.remote.sdk</groupId>
<artifactId>rxp-remote-java</artifactId>
<version>1.0</version>
<version>1.0.1</version>
</dependency>
```

### Gradle users
Add this dependency to your project's build file:
```
compile "com.realexpayments.remote.sdk:rxp-remote-java:1.0"
compile "com.realexpayments.remote.sdk:rxp-remote-java:1.0.1"
```
##Usage
```
Card card = new Card()
.addExpiryDate("0119")
.addNumber("420000000000000000")
.addNumber("4242424242424242")
.addType(CardType.VISA)
.addCardHolderName("Joe Smith")
.addCvn(123)
.addCvn("123")
.addCvnPresenceIndicator(PresenceIndicator.CVN_PRESENT);
PaymentRequest request = new PaymentRequest()
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.realexpayments.remote.sdk</groupId>
<artifactId>rxp-remote-java</artifactId>
<version>1.0</version>
<version>1.0.1</version>
<name>Realex Payments Remote Java SDK</name>
<description>The official Realex Payments Remote Java SDK</description>
<url>http://www.realexpayments.com</url>
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/realexpayments/remote/sdk/domain/Card.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
* .addNumber("420000000000000000")
* .addType(CardType.VISA)
* .addCardHolderName("Joe Smith")
* .addCvn(123)
* .addCvn("123")
* .addCvnPresenceIndicator(PresenceIndicator.CVN_PRESENT);
* </pre></code></p>
*
Expand Down Expand Up @@ -235,7 +235,7 @@ public Card addNumber(String number) {
* @param cvn
* @return Card
*/
public Card addCvn(Integer cvn) {
public Card addCvn(String cvn) {
if (null == this.cvn) {
this.cvn = new Cvn().addNumber(cvn);
} else {
Expand Down
10 changes: 5 additions & 5 deletions src/main/java/com/realexpayments/remote/sdk/domain/Cvn.java
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public String getIndicator() {
* For an AMEX card, it is a four digit number.
*/
@XmlElement(name = "number")
private Integer number;
private String number;

/**
* <p>
Expand All @@ -93,9 +93,9 @@ public Cvn() {
/**
* Getter for verification number.
*
* @return Integer
* @return String
*/
public Integer getNumber() {
public String getNumber() {
return number;
}

Expand All @@ -104,7 +104,7 @@ public Integer getNumber() {
*
* @param number
*/
public void setNumber(Integer number) {
public void setNumber(String number) {
this.number = number;
}

Expand Down Expand Up @@ -132,7 +132,7 @@ public void setPresenceIndicator(String presenceIndicator) {
* @param number
* @return Cvn
*/
public Cvn addNumber(Integer number) {
public Cvn addNumber(String number) {
this.number = number;
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
* .addNumber("420000000000000000")
* .addType(CardType.VISA)
* .addCardHolderName("Joe Smith")
* .addCvn(123)
* .addCvn("123")
* .addCvnPresenceIndicator(PresenceIndicator.CVN_PRESENT);
*
* PaymentRequest request = new PaymentRequest()
Expand All @@ -60,7 +60,7 @@
* .addNumber("420000000000000000")
* .addType(CardType.VISA)
* .addCardHolderName("Joe Smith")
* .addCvn(123)
* .addCvn("123")
* .addCvnPresenceIndicator(PresenceIndicator.CVN_PRESENT);
*
* PaymentRequest request = new PaymentRequest()
Expand Down Expand Up @@ -213,7 +213,7 @@ public String getType() {
private String refundHash;

/**
* TODO - info on this
* Fraud filter flag
*/
@XmlElement(name = "fraudfilter")
private String fraudFilter;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
* .addNumber("420000000000000000")
* .addType(CardType.VISA)
* .addCardHolderName("Joe Smith")
* .addCvn(123)
* .addCvn("123")
* .addCvnPresenceIndicator(PresenceIndicator.CVN_PRESENT);
*
* ThreeDSecureRequest request = new ThreeDSecureRequest()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public class SampleXmlValidationUtils {
public static final String CARD_NUMBER = "420000000000000000";
public static final CardType CARD_TYPE = CardType.VISA;
public static final String CARD_HOLDER_NAME = "Joe Smith";
public static final Integer CARD_CVN_NUMBER = 123;
public static final String CARD_CVN_NUMBER = "123";
public static final PresenceIndicator CARD_CVN_PRESENCE = PresenceIndicator.CVN_PRESENT;
public static final String CARD_EXPIRY_DATE = "0119";
public static final Integer CARD_ISSUE_NUMBER = 1;
Expand Down

0 comments on commit e75ec89

Please sign in to comment.