PlayerIO

The fastest way to build online games without breaking a sweat.

Android Client Reference

Android  class documentationClass VaultItem

Namespace: com.playerio
Language: Java

Represents information about an item in a user's Vault.

The methods and properties in a VaultItem are very simliar to those of a DatabaseObject, except that it's read-only, and that there are some extra properties regarding the purchase.

Methods

 
public boolean
contains (String propertyExpression)

Returns true if the given property exists on this object

public DatabaseArray
getArray (String propertyExpression)

Get the given DatabaseArray property

public boolean
getBool (String propertyExpression)

Get the given boolean property

public boolean
getBool (String propertyExpression, boolean defaultValue)

Get the given boolean property, or the default if it doesn't exist.

public byte[]
getBytes (String propertyExpression, byte[] defaultValue)

Get the given byte array property, or the default if it doesn't exist.

public byte[]
getBytes (String propertyExpression)

Get the given byte array property

public Date
getDateTime (String propertyExpression)

Get the given Date property

public Date
getDateTime (String propertyExpression, Date defaultValue)

Get the given Date property, or the default if it doesn't exist.

public double
getDouble (String propertyExpression, double defaultValue)

Get the given double property, or the default if it doesn't exist.

public double
getDouble (String propertyExpression)

Get the given double property

public float
getFloat (String propertyExpression, float defaultValue)

Get the given float property, or the default if it doesn't exist.

public float
getFloat (String propertyExpression)

Get the given float property

public String
getId ()

The unique id of this particular vault item in the users vault.

public int
getInt (String propertyExpression)

Get the given int property

public int
getInt (String propertyExpression, int defaultValue)

Get the given int property, or the default if it doesn't exist.

public String
getItemKey ()

The key of the underlying item in the PayVaultItems BigDB table.

public long
getLong (String propertyExpression)

Get the given long property

public long
getLong (String propertyExpression, long defaultValue)

Get the given long property, or the default if it doesn't exist.

public DatabaseObject
getObject (String propertyExpression)

Get the given DatabaseObject property

public Date
getPurchaseDate ()

The time when the vault item was originally purchased.

public String
getString (String propertyExpression, String defaultValue)

Get the given String property, or the default if it doesn't exist.

public String
getString (String propertyExpression)

Get the given String property

public int
getUInt (String propertyExpression)

Get the given uint property

public int
getUInt (String propertyExpression, int defaultValue)

Get the given uint property, or the default if it doesn't exist.

public Object
getValue (String propertyExpression)

Get the given property as an object

public ArrayList<String>
properties ()

Get the names of all properties on this object

public int
size ()

Returns the number of properties on this object

VaultItem.contains

public boolean
contains (String propertyExpression)

Returns true if the given property exists on this object

Arguments

String propertyExpression

VaultItem.getArray

public DatabaseArray
getArray (String propertyExpression)

Get the given DatabaseArray property

Arguments

String propertyExpression

VaultItem.getBool

public boolean
getBool (String propertyExpression)

Get the given boolean property

Arguments

String propertyExpression

VaultItem.getBool

public boolean
getBool (String propertyExpression, boolean defaultValue)

Get the given boolean property, or the default if it doesn't exist.

Arguments

String propertyExpression
boolean defaultValue

VaultItem.getBytes

public byte[]
getBytes (String propertyExpression, byte[] defaultValue)

Get the given byte array property, or the default if it doesn't exist.

Arguments

String propertyExpression
byte[] defaultValue

VaultItem.getBytes

public byte[]
getBytes (String propertyExpression)

Get the given byte array property

Arguments

String propertyExpression

VaultItem.getDateTime

public Date
getDateTime (String propertyExpression)

Get the given Date property

Arguments

String propertyExpression

VaultItem.getDateTime

public Date
getDateTime (String propertyExpression, Date defaultValue)

Get the given Date property, or the default if it doesn't exist.

Arguments

String propertyExpression
Date defaultValue

VaultItem.getDouble

public double
getDouble (String propertyExpression, double defaultValue)

Get the given double property, or the default if it doesn't exist.

Arguments

String propertyExpression
double defaultValue

VaultItem.getDouble

public double
getDouble (String propertyExpression)

Get the given double property

Arguments

String propertyExpression

VaultItem.getFloat

public float
getFloat (String propertyExpression, float defaultValue)

Get the given float property, or the default if it doesn't exist.

Arguments

String propertyExpression
float defaultValue

VaultItem.getFloat

public float
getFloat (String propertyExpression)

Get the given float property

Arguments

String propertyExpression

VaultItem.getId

public String
getId ()

The unique id of this particular vault item in the users vault.

VaultItem.getInt

public int
getInt (String propertyExpression)

Get the given int property

Arguments

String propertyExpression

VaultItem.getInt

public int
getInt (String propertyExpression, int defaultValue)

Get the given int property, or the default if it doesn't exist.

Arguments

String propertyExpression
int defaultValue

VaultItem.getItemKey

public String
getItemKey ()

The key of the underlying item in the PayVaultItems BigDB table.

VaultItem.getLong

public long
getLong (String propertyExpression)

Get the given long property

Arguments

String propertyExpression

VaultItem.getLong

public long
getLong (String propertyExpression, long defaultValue)

Get the given long property, or the default if it doesn't exist.

Arguments

String propertyExpression
long defaultValue

VaultItem.getObject

public DatabaseObject
getObject (String propertyExpression)

Get the given DatabaseObject property

Arguments

String propertyExpression

VaultItem.getPurchaseDate

public Date
getPurchaseDate ()

The time when the vault item was originally purchased.

VaultItem.getString

public String
getString (String propertyExpression, String defaultValue)

Get the given String property, or the default if it doesn't exist.

Arguments

String propertyExpression
String defaultValue

VaultItem.getString

public String
getString (String propertyExpression)

Get the given String property

Arguments

String propertyExpression

VaultItem.getUInt

public int
getUInt (String propertyExpression)

Get the given uint property

Arguments

String propertyExpression

VaultItem.getUInt

public int
getUInt (String propertyExpression, int defaultValue)

Get the given uint property, or the default if it doesn't exist.

Arguments

String propertyExpression
int defaultValue

VaultItem.getValue

public Object
getValue (String propertyExpression)

Get the given property as an object

Arguments

String propertyExpression

VaultItem.properties

public ArrayList<String>
properties ()

Get the names of all properties on this object

VaultItem.size

public int
size ()

Returns the number of properties on this object