PocketMine
SimpleTransactionGroup Class Reference
Inheritance diagram for SimpleTransactionGroup:
TransactionGroup

Public Member Functions

 __construct (Player $source=null)
 
 getSource ()
 
 getCreationTime ()
 
 getInventories ()
 
 getTransactions ()
 
 addTransaction (Transaction $transaction)
 
 canExecute ()
 
 execute ()
 
 hasExecuted ()
 

Protected Member Functions

 matchItems (array &$needItems, array &$haveItems)
 

Protected Attributes

 $hasExecuted = false
 
 $source = null
 
 $inventories = []
 
 $transactions = []
 

Detailed Description

This TransactionGroup only allows doing Transaction between one / two inventories

Constructor & Destructor Documentation

__construct ( Player  $source = null)
Parameters
Player$source

Member Function Documentation

addTransaction ( Transaction  $transaction)
Parameters
Transaction$transaction

Implements TransactionGroup.

canExecute ( )
Returns
bool

Implements TransactionGroup.

execute ( )
Returns
bool

Implements TransactionGroup.

getCreationTime ( )
Returns
float

Implements TransactionGroup.

getInventories ( )
Returns
Inventory[]

Implements TransactionGroup.

getSource ( )
Returns
Player
getTransactions ( )
Returns
Transaction[]

Implements TransactionGroup.

hasExecuted ( )
Returns
bool

Implements TransactionGroup.

matchItems ( array &  $needItems,
array &  $haveItems 
)
protected
Parameters
Item[]$needItems
Item[]$haveItems
Returns
bool

The documentation for this class was generated from the following file: