-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Split exceptions, refactored request url
- Loading branch information
1 parent
e410922
commit bc08795
Showing
11 changed files
with
158 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
src/main/java/com/cnp/sdk/ChargebackDocumentException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package com.cnp.sdk; | ||
|
||
public class ChargebackDocumentException extends RuntimeException { | ||
|
||
private static final long serialVersionUID = 1L; | ||
private String code; | ||
|
||
public ChargebackDocumentException(String message, String code) { | ||
super(message); | ||
this.code = code; | ||
} | ||
|
||
public ChargebackDocumentException(String message, Exception ume) { | ||
super(message, ume); | ||
this.code = "0"; | ||
} | ||
|
||
public ChargebackDocumentException(String message) { | ||
super(message); | ||
this.code = "0"; | ||
} | ||
|
||
public String getCode() { | ||
return code; | ||
} | ||
|
||
public void setCode(String code) { | ||
this.code = code; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
package com.cnp.sdk; | ||
|
||
import java.util.List; | ||
|
||
public class ChargebackWebException extends RuntimeException { | ||
|
||
private static final long serialVersionUID = 1L; | ||
private String code; | ||
private List<String> errorList; | ||
|
||
public ChargebackWebException(String message, String code, List<String> errorList) { | ||
super(message); | ||
this.code = code; | ||
this.errorList = errorList; | ||
} | ||
|
||
public ChargebackWebException(String message, String code) { | ||
super(message); | ||
this.code = code; | ||
} | ||
|
||
public ChargebackWebException(String message, Exception ume) { | ||
super(message, ume); | ||
this.code = "0"; | ||
} | ||
|
||
public ChargebackWebException(String message) { | ||
super(message); | ||
this.code = "0"; | ||
} | ||
|
||
public String getCode() { | ||
return code; | ||
} | ||
|
||
public void setCode(String code) { | ||
this.code = code; | ||
} | ||
|
||
public List<String> getErrorList() { | ||
return errorList; | ||
} | ||
|
||
public void setErrorList(List<String> errorList) { | ||
this.errorList = errorList; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters