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

com.stripe.model.ExpandableField Maven / Gradle / Ivy

There is a newer version: 28.2.0
Show newest version
package com.stripe.model;

//This class is meant to be used for expandable fields in the Stripe API.
//For example, ExpandableField in Charge.
//The class should always contain a String id, and may have a null or type T expandedObject.
//More info here: https://stripe.com/docs/api#expanding_objects
public class ExpandableField {
  private String id;
  private T expandedObject;

  public ExpandableField(String id, T expandedObject) {
    this.id = id;
    this.expandedObject = expandedObject;
  }

  public boolean isExpanded() {
    return expandedObject != null;
  }

  public String getId() {
    return id;
  }

  public void setId(String id) {
    this.id = id;
  }

  public T getExpanded() {
    return expandedObject;
  }

  public void setExpanded(T expandedObject) {
    this.expandedObject = expandedObject;
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy