PlayerIO

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

Objective-C Client Reference

Multiplayer  class documentationClass PIOVaultItem

Language: Objective-C

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

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

Methods

 
- (NSArray*)
allProperties
Get the names of all properties on this object
- (NSArray*)
allValues
Get all values from the properties of this object. Primitive properties (integers, floats, etc.) are wrapped in NSNumber
- (PIODatabaseArray*)
arrayForProperty:
Get the given DatabaseArray property
- (BOOL)
boolForProperty:
Get the given boolean property
- (BOOL)
boolForProperty:defaultValue:
Get the given boolean property, or the default if it doesn't exist.
- (BOOL)
containsProperty:
Returns true if the given property exists on this object
- (NSUInteger)
count
Returns the number of properties on this object
- (NSUInteger)
countByEnumeratingWithState:objects:count:
Fast enumeration over the properties in the object
- (NSData*)
dataForProperty:
Get the given byte array property
- (NSData*)
dataForProperty:defaultValue:
Get the given byte array property, or the default if it doesn't exist.
- (NSDate*)
dateForProperty:
Get the given Date property
- (NSDate*)
dateForProperty:defaultValue:
Get the given Date property, or the default if it doesn't exist.
- (double)
doubleForProperty:
Get the given double property
- (double)
doubleForProperty:defaultValue:
Get the given double property, or the default if it doesn't exist.
- (float)
floatForProperty:
Get the given float property
- (float)
floatForProperty:defaultValue:
Get the given float property, or the default if it doesn't exist.
- (NSString*)
id
The unique id of this particular vault item in the users vault.
- (int32_t)
intForProperty:
Get the given int property
- (int32_t)
intForProperty:defaultValue:
Get the given int property, or the default if it doesn't exist.
- (NSString*)
itemKey
key of the underlying item in the PayVaultItems BigDB table
- (NSEnumerator*)
keyEnumerator
Enumerator to move over keys used for properties in the object
- (int64_t)
longForProperty:
Get the given long property
- (int64_t)
longForProperty:defaultValue:
Get the given long property, or the default if it doesn't exist.
- (NSEnumerator*)
objectEnumerator
Enumerator to move over all properties in the object
- (PIODatabaseObject*)
objectForProperty:
Get the given DatabaseObject property
- (NSDate*)
purchaseDate
The unique id of this particular vault item in the users vault.
- (NSString*)
stringForProperty:
Get the given String property
- (NSString*)
stringForProperty:defaultValue:
Get the given String property, or the default if it doesn't exist.
- (uint32_t)
uintForProperty:
Get the given uint property
- (uint32_t)
uintForProperty:defaultValue:
Get the given uint property, or the default if it doesn't exist.
- (id)
valueForProperty:
Get the given property as an object. Primitive properties (integers, floats, etc.) are wrapped in NSNumber

allProperties

Get the names of all properties on this object

Return Value

NSArray*

allValues

Get all values from the properties of this object. Primitive properties (integers, floats, etc.) are wrapped in NSNumber

Return Value

NSArray*

arrayForProperty:

Get the given DatabaseArray property

Arguments

NSString* propertyExpression

Return Value

PIODatabaseArray*

boolForProperty:

Get the given boolean property

Arguments

NSString* propertyExpression

Return Value

BOOL

boolForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
BOOL defaultValue

Return Value

BOOL

containsProperty:

Returns true if the given property exists on this object

Arguments

NSString* propertyExpression

Return Value

BOOL

count

Returns the number of properties on this object

Return Value

NSUInteger

countByEnumeratingWithState:objects:count:

Fast enumeration over the properties in the object

Arguments

NSFastEnumerationState* state
id* stackbuf
NSUInteger len

Return Value

NSUInteger

dataForProperty:

Get the given byte array property

Arguments

NSString* propertyExpression

Return Value

NSData*

dataForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
NSData* defaultValue

Return Value

NSData*

dateForProperty:

Get the given Date property

Arguments

NSString* propertyExpression

Return Value

NSDate*

dateForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
NSDate* defaultValue

Return Value

NSDate*

doubleForProperty:

Get the given double property

Arguments

NSString* propertyExpression

Return Value

double

doubleForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
double defaultValue

Return Value

double

floatForProperty:

Get the given float property

Arguments

NSString* propertyExpression

Return Value

float

floatForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
float defaultValue

Return Value

float

id

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

Return Value

NSString*

intForProperty:

Get the given int property

Arguments

NSString* propertyExpression

Return Value

int32_t

intForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
int32_t defaultValue

Return Value

int32_t

itemKey

key of the underlying item in the PayVaultItems BigDB table

Return Value

NSString*

keyEnumerator

Enumerator to move over keys used for properties in the object

Return Value

NSEnumerator*

longForProperty:

Get the given long property

Arguments

NSString* propertyExpression

Return Value

int64_t

longForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
int64_t defaultValue

Return Value

int64_t

objectEnumerator

Enumerator to move over all properties in the object

Return Value

NSEnumerator*

objectForProperty:

Get the given DatabaseObject property

Arguments

NSString* propertyExpression

Return Value

PIODatabaseObject*

purchaseDate

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

Return Value

NSDate*

stringForProperty:

Get the given String property

Arguments

NSString* propertyExpression

Return Value

NSString*

stringForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
NSString* defaultValue

Return Value

NSString*

uintForProperty:

Get the given uint property

Arguments

NSString* propertyExpression

Return Value

uint32_t

uintForProperty:defaultValue:

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

Arguments

NSString* propertyExpression
uint defaultValue

Return Value

uint32_t

valueForProperty:

Get the given property as an object. Primitive properties (integers, floats, etc.) are wrapped in NSNumber

Arguments

NSString* propertyExpression

Return Value

id