All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.ingenico.connect.gateway.sdk.java.merchant.products.FindProductsParams Maven / Gradle / Ivy

Go to download

SDK to communicate with the Ingenico ePayments platform using the Ingenico Connect Server API

There is a newer version: 6.47.0
Show newest version
/*
 * This class was auto-generated from the API references found at
 * https://epayments-api.developer-ingenico.com/s2sapi/v1/
 */
package com.ingenico.connect.gateway.sdk.java.merchant.products;

import java.util.LinkedList;
import java.util.List;

import com.ingenico.connect.gateway.sdk.java.ParamRequest;
import com.ingenico.connect.gateway.sdk.java.RequestParam;

/**
 * Query parameters for
 * Get payment products
 */
public class FindProductsParams implements ParamRequest {

	private String countryCode;

	private String currencyCode;

	private String locale;

	private Long amount;

	private Boolean isRecurring;

	private List hide;

	/**
	 * ISO 3166-1 alpha-2 country code
	 */
	public String getCountryCode() {
		return countryCode;
	}

	/**
	 * ISO 3166-1 alpha-2 country code
	 */
	public void setCountryCode(String value) {
		this.countryCode = value;
	}

	/**
	 * Three-letter ISO currency code representing the currency for the amount
	 */
	public String getCurrencyCode() {
		return currencyCode;
	}

	/**
	 * Three-letter ISO currency code representing the currency for the amount
	 */
	public void setCurrencyCode(String value) {
		this.currencyCode = value;
	}

	/**
	 * Locale used in the GUI towards the consumer. Please make sure that a language pack is configured for the locale you are submitting. If you submit a locale that is not setup on your account we will use the default language pack for your account. You can easily upload additional language packs and set the default language pack in the Configuration Center.
	 */
	public String getLocale() {
		return locale;
	}

	/**
	 * Locale used in the GUI towards the consumer. Please make sure that a language pack is configured for the locale you are submitting. If you submit a locale that is not setup on your account we will use the default language pack for your account. You can easily upload additional language packs and set the default language pack in the Configuration Center.
	 */
	public void setLocale(String value) {
		this.locale = value;
	}

	/**
	 * Amount in cents and always having 2 decimals
	 */
	public Long getAmount() {
		return amount;
	}

	/**
	 * Amount in cents and always having 2 decimals
	 */
	public void setAmount(Long value) {
		this.amount = value;
	}

	/**
	 * This allows you to filter payment products based on their support for recurring or not
	 * 
  • true *
  • false *
* If this is omitted all payment products are returned. */ public Boolean getIsRecurring() { return isRecurring; } /** * This allows you to filter payment products based on their support for recurring or not *
  • true *
  • false *
* If this is omitted all payment products are returned. */ public void setIsRecurring(Boolean value) { this.isRecurring = value; } /** * Allows you to hide elements from the response, reducing the amount of data that needs to be returned to your client. Possible options are: *
    *
  • fields - Don't return any data on fields of the payment product *
  • accountsOnFile - Don't return any accounts on file data *
  • translations - Don't return any label texts associated with the payment products *
  • productsWithoutFields - Don't return products that require any additional data to be captured *
  • productsWithoutInstructions - Don't return products that show instructions *
  • productsWithRedirects - Don't return products that require a redirect to a 3rd party. Note that products that involve potential redirects related to 3D Secure authentication are not hidden *
*/ public List getHide() { return hide; } /** * Allows you to hide elements from the response, reducing the amount of data that needs to be returned to your client. Possible options are: *
    *
  • fields - Don't return any data on fields of the payment product *
  • accountsOnFile - Don't return any accounts on file data *
  • translations - Don't return any label texts associated with the payment products *
  • productsWithoutFields - Don't return products that require any additional data to be captured *
  • productsWithoutInstructions - Don't return products that show instructions *
  • productsWithRedirects - Don't return products that require a redirect to a 3rd party. Note that products that involve potential redirects related to 3D Secure authentication are not hidden *
*/ public void setHide(List value) { this.hide = value; } /** * Allows you to hide elements from the response, reducing the amount of data that needs to be returned to your client. Possible options are: *
    *
  • fields - Don't return any data on fields of the payment product *
  • accountsOnFile - Don't return any accounts on file data *
  • translations - Don't return any label texts associated with the payment products *
  • productsWithoutFields - Don't return products that require any additional data to be captured *
  • productsWithoutInstructions - Don't return products that show instructions *
  • productsWithRedirects - Don't return products that require a redirect to a 3rd party. Note that products that involve potential redirects related to 3D Secure authentication are not hidden *
*/ public void addHide(String value) { if (this.hide == null) { this.hide = new LinkedList(); } this.hide.add(value); } @Override public List toRequestParameters() { List result = new LinkedList(); if (countryCode != null) { result.add(new RequestParam("countryCode", countryCode)); } if (currencyCode != null) { result.add(new RequestParam("currencyCode", currencyCode)); } if (locale != null) { result.add(new RequestParam("locale", locale)); } if (amount != null) { result.add(new RequestParam("amount", amount.toString())); } if (isRecurring != null) { result.add(new RequestParam("isRecurring", isRecurring.toString())); } if (hide != null) { for (String hideElement : hide) { if (hideElement != null) { result.add(new RequestParam("hide", hideElement)); } } } return result; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy