Android Open Source - bitpay-android-sdk Token






From Project

Back to project page bitpay-android-sdk.

License

The source code is released under:

MIT License

If you think the Android project bitpay-android-sdk listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.bitpay.androidsdk.model;
//from w w w .  j av a  2s  . c  o m
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.List;

/**
 * A token is used to access the BitPay API and authorize access to a facade to a private key.
 */
public class Token {
  
  private String _guid;
  private long _nonce = 0;
  private String _id = "";
  private String _pairingCode = "";
  private String _facade = "";
  private String _label = "";
  private String _count = "";
  private List<Policy> _policies;
  private String _resource;
  private String _value;
  private String _dateCreated;
    private String pairingExpiration;

    public Token() {}

    // API fields
    //

    @JsonProperty("guid")
  public String getGuid() {
    return _guid;
  }
    
    @JsonProperty("guid")
  public void setGuid(String _guid) {
    this._guid = _guid;
  }
    
    @JsonProperty("nonce")
    @JsonInclude(JsonInclude.Include.NON_DEFAULT)
    public long getNonce() {
    return _nonce;
  }
    
    @JsonProperty("nonce")
  public void setNonce(long _nonce) {
    this._nonce = _nonce;
  }

    // Required fields
    //

    @JsonProperty("id")
    @JsonInclude(JsonInclude.Include.NON_DEFAULT)
  public String getId() {
    return _id;
  }
    
    @JsonProperty("id")
  public void setId(String _id) {
    this._id = _id;
  }
    
    @JsonProperty("pairingCode")
    @JsonInclude(JsonInclude.Include.NON_DEFAULT)
  public String getPairingCode() {
    return _pairingCode;
  }
    
    @JsonProperty("pairingCode")
  public void setPairingCode(String _pairingCode) {
    this._pairingCode = _pairingCode;
  }

    @JsonProperty("facade")
    @JsonInclude(JsonInclude.Include.NON_DEFAULT)
    public String getFacade() {
    return _facade;
  }

    @JsonProperty("facade")
    public void setFacade(String _facade) {
    this._facade = _facade;
  }
  
    @JsonProperty("label")
    @JsonInclude(JsonInclude.Include.NON_DEFAULT)
    public String getLabel() {
    return _label;
  }

    @JsonProperty("label")
    public void setLabel(String _label) {
    this._label = _label;
  }
  
    @JsonProperty("count")
    @JsonInclude(JsonInclude.Include.NON_DEFAULT)
    public String getCount() {
    return _count;
  }

    @JsonProperty("count")
    public void setCount(String _count) {
    this._count = _count;
  }

    // Response fields
    //

    @JsonIgnore
  public List<Policy> getPolicies() {
    return _policies;
  }
        
    @JsonProperty("policies")
  public void setPolicies(List<Policy> _policies) {
    this._policies = _policies;
  }

    @JsonIgnore
    public String getResource() {
    return _resource;
  }
    
    @JsonProperty("resource")
  public void setResource(String _resource) {
    this._resource = _resource;
  }
  
    @JsonIgnore
  public String getValue() {
    return _value;
  }
    
    @JsonProperty("token")
  public void setValue(String _value) {
    this._value = _value;
  }

    @JsonIgnore
    public String getDateCreated() {
    return _dateCreated;
  }
    
    @JsonProperty("dateCreated")
  public void setDateCreated(String _dateCreated) {
    this._dateCreated = _dateCreated;
  }

    @JsonProperty("pairingExpiration")
    public void setPairingExpiration(String expiration) {
        this.pairingExpiration = expiration;
    }

    @JsonIgnore
    public String getPairingExpiration() {
        return pairingExpiration;
    }

}




Java Source Code List

com.bitpay.androidsdk.android.BitPayAndroid.java
com.bitpay.androidsdk.android.InvoiceActivity.java
com.bitpay.androidsdk.android.interfaces.BitpayPromiseCallback.java
com.bitpay.androidsdk.android.interfaces.InvoiceCreationCallback.java
com.bitpay.androidsdk.android.interfaces.InvoicePromiseCallback.java
com.bitpay.androidsdk.android.interfaces.PromiseCallback.java
com.bitpay.androidsdk.android.interfaces.RatesPromiseCallback.java
com.bitpay.androidsdk.android.promises.BitpayPromise.java
com.bitpay.androidsdk.controller.BitPayException.java
com.bitpay.androidsdk.controller.BitPay.java
com.bitpay.androidsdk.controller.KeyUtils.java
com.bitpay.androidsdk.model.InvoicePaymentUrls.java
com.bitpay.androidsdk.model.InvoiceTransaction.java
com.bitpay.androidsdk.model.Invoice.java
com.bitpay.androidsdk.model.Policy.java
com.bitpay.androidsdk.model.Rate.java
com.bitpay.androidsdk.model.Rates.java
com.bitpay.androidsdk.model.Token.java
com.bitpay.sdk.android.ApplicationTest.java