public class

Cart

extends Object
implements Parcelable JSONSerializable Cloneable
java.lang.Object
   ↳ com.ad4screen.sdk.analytics.Cart

Class Overview

Cart Object to use for analytics event

Summary

Constants
String KEY_ID
String KEY_UNIT_PRICE
[Expand]
Inherited Constants
From interface android.os.Parcelable
Fields
public static final Creator<Cart> CREATOR
Public Constructors
Cart(String id, Item item)
Constructor of Cart
Public Methods
Object clone()
int describeContents()
String getId()
Item getItem()
void setId(String mId)
void setItem(Item item)
JSONObject toJSON()
Serialize an object into a JSONObject
void writeToParcel(Parcel dest, int flags)
[Expand]
Inherited Methods
From class java.lang.Object
From interface android.os.Parcelable
From interface com.ad4screen.sdk.common.persistence.JSONSerializable

Constants

public static final String KEY_ID

Constant Value: "cartId"

public static final String KEY_UNIT_PRICE

Constant Value: "unitPrice"

Fields

public static final Creator<Cart> CREATOR

Public Constructors

public Cart (String id, Item item)

Constructor of Cart

Parameters
id id of this cart
item Item object to add or modify

Public Methods

public Object clone ()

Throws
CloneNotSupportedException

public int describeContents ()

public String getId ()

public Item getItem ()

public void setId (String mId)

public void setItem (Item item)

public JSONObject toJSON ()

Serialize an object into a JSONObject

Returns
  • JSONObject of the serialized class
Throws
JSONException

public void writeToParcel (Parcel dest, int flags)