Class: webdev.core.CanFail
-
-
Field Summary
Fields
Modifier and Type |
Field and Description |
private java.util.ArrayList<java.lang.String> |
_errors
The list of errors
|
-
Constructor Summary
Constructors
Constructor and Description |
CanFail() |
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type |
Method and Description |
java.lang.String |
Errors()
Get the errors sent by Paynow
|
java.lang.String |
Errors(char separator)
Get the errors sent by payment
|
void |
Fail(java.lang.String error)
Throws an exception for critical errors and stores other non-critical errors
|
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Class: webdev.core.Constants
-
-
Constructor Summary
Constructors
Constructor and Description |
Constants() |
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
Constants
public Constants()
Class: webdev.core.IResponse
-
-
Method Detail
-
Success
boolean Success()
Class: webdev.core.InitResponse
-
-
Field Summary
Fields
Modifier and Type |
Field and Description |
private java.util.Map<java.lang.String,java.lang.String> |
Data |
private boolean |
HasRedirect |
private boolean |
WasSuccessful |
-
Constructor Summary
Constructors
Constructor and Description |
InitResponse(java.util.Map<java.lang.String,java.lang.String> response)
InitResponse constructor.
|
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type |
Method and Description |
protected java.util.Map<java.lang.String,java.lang.String> |
getData() |
java.util.Map<java.lang.String,java.lang.String> |
GetData()
Get the original data sent from Paynow
|
protected boolean |
getHasRedirect() |
protected boolean |
getWasSuccessful() |
private void |
Load()
Reads through the response data sent from Paynow
|
java.lang.String |
PollUrl()
Returns the poll URL sent from Paynow
|
java.lang.String |
RedirectLink()
Returns the url the user should be taken to so they can make a payment
|
protected void |
setHasRedirect(boolean value) |
protected void |
setWasSuccessful(boolean value) |
boolean |
Success()
Gets a boolean indicating whether a request succeeded or failed
|
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
InitResponse
public InitResponse(java.util.Map<java.lang.String,java.lang.String> response)
InitResponse constructor.
- Parameters:
response
- Response data sent from Paynow
- Throws:
InvalidIntegrationException
-
If the error returned from paynow is
-
Method Detail
-
GetData
public final java.util.Map<java.lang.String,java.lang.String> GetData()
Get the original data sent from Paynow
- Returns:
Class: webdev.core.StatusResponse
-
-
Field Summary
Fields
Modifier and Type |
Field and Description |
private java.math.BigDecimal |
Amount
The total amount of the transaction
|
private java.util.Map<java.lang.String,java.lang.String> |
Data
The data returned from Paynow
|
private java.lang.String |
Reference
The unique reference of the transaction
|
private boolean |
WasPaid
Boolean value indicatiing whether a transaction was paid or not
|
private boolean |
WasSuccessful
Boolean indicating whether a transaction was successful or not
|
-
Constructor Summary
Constructors
Constructor and Description |
StatusResponse(java.util.Map<java.lang.String,java.lang.String> response)
InitResponse constructor.
|
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
StatusResponse
public StatusResponse(java.util.Map<java.lang.String,java.lang.String> response)
InitResponse constructor.
- Parameters:
response
- Response data sent from Paynow
- Throws:
InvalidIntegrationException
-
If the error returned from paynow is
-
Method Detail
-
GetData
public final java.util.Map<java.lang.String,java.lang.String> GetData()
Get the original data sent from Paynow
- Returns:
- The original data sent from Paynow
Class: webdev.exceptions.EmptyCartException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- webdev.exceptions.EmptyCartException
-
-
Method Summary
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Class: webdev.exceptions.HashMismatchException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- webdev.exceptions.HashMismatchException
-
-
Method Summary
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Class: webdev.exceptions.InvalidIntegrationException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- webdev.exceptions.InvalidIntegrationException
-
-
Method Summary
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Class: webdev.exceptions.InvalidReferenceException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- webdev.exceptions.InvalidReferenceException
-
-
Method Summary
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Class: webdev.helpers.Extensions
- java.lang.Object
-
- webdev.helpers.Extensions
-
-
Constructor Summary
Constructors
Constructor and Description |
Extensions() |
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
Extensions
public Extensions()
Class: webdev.helpers.Hash
-
-
Constructor Summary
Constructors
Constructor and Description |
Hash() |
-
Method Summary
All Methods Static Methods Concrete Methods
Modifier and Type |
Method and Description |
static java.lang.String |
GenerateHash(java.lang.String text) |
private static byte[] |
GenerateSalt() |
private static java.lang.String |
GetStringFromHash(byte[] hash) |
static java.lang.String |
Make(java.util.Map<java.lang.String,java.lang.String> values,
java.lang.String integrationKey)
Hash the values in the given map
|
static boolean |
Verify(java.util.Map<java.lang.String,java.lang.String> data,
java.lang.String integrationKey)
Verifies the given hash
|
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
Make
public static java.lang.String Make(java.util.Map<java.lang.String,java.lang.String> values,
java.lang.String integrationKey)
Hash the values in the given map
- Parameters:
values
- Values to value
integrationKey
- Paynow integration key
- Returns:
Class: webdev.http.Client
-
-
Constructor Summary
Constructors
Constructor and Description |
Client() |
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Class: webdev.payments.MobileMoneyMethod
-
-
Enum Constant Summary
Enum Constants
Enum Constant and Description |
Ecocash |
-
Field Summary
Fields
Modifier and Type |
Field and Description |
static int |
SIZE |
-
Method Summary
-
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
-
-
Method Detail
-
valueOf
public static MobileMoneyMethod valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match
exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters
are not permitted.)
- Parameters:
name
- the name of the enum constant to be returned.
- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified
name
java.lang.NullPointerException
- if the argument is null
-
getValue
public int getValue()
Last updated on 9/18/2018