Class Split
- java.lang.Object
-
- com.adyen.model.marketpaywebhooks.Split
-
public class Split extends Object
Split
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSplit.TypeEnumThe type of split.
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_ACCOUNTstatic StringJSON_PROPERTY_AMOUNTstatic StringJSON_PROPERTY_DESCRIPTIONstatic StringJSON_PROPERTY_REFERENCEstatic StringJSON_PROPERTY_TYPE
-
Constructor Summary
Constructors Constructor Description Split()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Splitaccount(String account)Splitamount(SplitAmount amount)Splitdescription(String description)booleanequals(Object o)Return true if this Split object is equal to o.static SplitfromJson(String jsonString)Create an instance of Split given an JSON stringStringgetAccount()Unique identifier of the account where the split amount should be sent.SplitAmountgetAmount()Get amountStringgetDescription()A description of this split.StringgetReference()Your reference for the split, which you can use to link the split to other operations such as captures and refunds.Split.TypeEnumgetType()The type of split.inthashCode()Splitreference(String reference)voidsetAccount(String account)voidsetAmount(SplitAmount amount)voidsetDescription(String description)voidsetReference(String reference)voidsetType(Split.TypeEnum type)StringtoJson()Convert an instance of Split to an JSON stringStringtoString()Splittype(Split.TypeEnum type)
-
-
-
Field Detail
-
JSON_PROPERTY_ACCOUNT
public static final String JSON_PROPERTY_ACCOUNT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_AMOUNT
public static final String JSON_PROPERTY_AMOUNT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_DESCRIPTION
public static final String JSON_PROPERTY_DESCRIPTION
- See Also:
- Constant Field Values
-
JSON_PROPERTY_REFERENCE
public static final String JSON_PROPERTY_REFERENCE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_TYPE
public static final String JSON_PROPERTY_TYPE
- See Also:
- Constant Field Values
-
-
Method Detail
-
getAccount
public String getAccount()
Unique identifier of the account where the split amount should be sent. This is required if `type` is **MarketPlace** or **BalanceAccount**.- Returns:
- account
-
setAccount
public void setAccount(String account)
-
amount
public Split amount(SplitAmount amount)
-
getAmount
public SplitAmount getAmount()
Get amount- Returns:
- amount
-
setAmount
public void setAmount(SplitAmount amount)
-
getDescription
public String getDescription()
A description of this split.- Returns:
- description
-
setDescription
public void setDescription(String description)
-
getReference
public String getReference()
Your reference for the split, which you can use to link the split to other operations such as captures and refunds. This is required if `type` is **MarketPlace** or **BalanceAccount**. For the other types, we also recommend sending a reference so you can reconcile the split and the associated payment in the transaction overview and in the reports. If the reference is not provided, the split is reported as part of the aggregated [TransferBalance record type](https://docs.adyen.com/reporting/marketpay-payments-accounting-report) in Adyen for Platforms.- Returns:
- reference
-
setReference
public void setReference(String reference)
-
type
public Split type(Split.TypeEnum type)
-
getType
public Split.TypeEnum getType()
The type of split. Possible values: **Default**, **PaymentFee**, **VAT**, **Commission**, **MarketPlace**, **BalanceAccount**, **Remainder**, **Surcharge**, **Tip**.- Returns:
- type
-
setType
public void setType(Split.TypeEnum type)
-
equals
public boolean equals(Object o)
Return true if this Split object is equal to o.
-
fromJson
public static Split fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of Split given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of Split
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to Split
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of Split to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-