Returns number of player within.
Returns number of player within.
API Tags:
| Return: | Count of players. |
| Access: | public |
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
| Since: | 0.0.5 |
| Throws: | PDOException On PDO operation error. |
Implementation of:
- Countable::count
Deletes group.
Deletes group.
API Tags:
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
| Since: | 0.0.5 |
| Throws: | PDOException On PDO operation error. |
void find(
string
$name
)
|
|
Loads group by it's name.
Loads group by it's name.
Parameters:
|
string |
$name: |
Group name. |
API Tags:
Information Tags:
| Version: | 0.1.1 |
| Version: | 0.0.1 |
| Throws: | PDOException On PDO operation error. |
| Since: | 0.1.1 |
Redefinition of:
- OTS_Row_DAO::find()
- Loads row by it's name.
Access level.
Access level.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Access level. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
string getCustomField(
string
$field
)
|
|
Reads custom field.
Reads custom field.
Reads field by it's name. Can read any field of given record that exists in database.
Note: You should use this method only for fields that are not provided in standard setters/getters (SVN fields). This method runs SQL query each time you call it so it highly overloads used resources.
Parameters:
|
string |
$field: |
Field name. |
API Tags:
| Return: | Field value. |
| Access: | public |
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
| Since: | 0.0.3 |
| Throws: | PDOException On PDO operation error. |
Rights flags.
Rights flags.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Flags. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
Group ID.
Group ID.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Group ID. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
Returns players iterator.
Returns players iterator.
There is no need to implement entire Iterator interface since we have players list class for it.
API Tags:
| Return: | List of players. |
| Access: | public |
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
| Since: | 0.0.5 |
| Throws: | PDOException On PDO operation error. |
Implementation of:
- IteratorAggregate::getIterator
Maximum count of items in depot.
Maximum count of items in depot.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Maximum value. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
Maximum count of players in VIP list.
Maximum count of players in VIP list.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Maximum value. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
Group name.
Group name.
Note: Since 0.0.3 version this method throws E_OTS_NotLoaded exception instead of triggering E_USER_WARNING.
API Tags:
| Return: | Name. |
| Access: | public |
Information Tags:
| Version: | 0.0.3 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
API Tags:
| Return: | Array of OTS_Player objects from given group. |
| Deprecated: | 0.0.5 Use getPlayersList(). |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
List of characters in group.
List of characters in group.
In difference to getPlayers() method this method returns filtered OTS_Players_List object instead of array of OTS_Player objects. It is more effective since OTS_Player_List doesn't perform all rows loading at once.
Note: Returned object is only prepared, but not initialised. When using as parameter in foreach loop it doesn't matter since it will return it's iterator, but if you will wan't to execute direct operation on that object you will need to call rewind() method first.
API Tags:
| Return: | List of players from current group. |
| Access: | public |
Information Tags:
| Version: | 0.1.4 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
| Since: | 0.0.5 |
Checks if object is loaded.
Checks if object is loaded.
API Tags:
| Return: | Load state. |
| Access: | public |
Information Tags:
Loads group with given id.
Loads group with given id.
Parameters:
API Tags:
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | PDOException On PDO operation error. |
Redefinition of:
- OTS_Row_DAO::load()
- Loads row by it's ID.
Saves group in database.
Saves group in database.
If group is not loaded to represent any existing group it will create new row for it.
API Tags:
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | PDOException On PDO operation error. |
void setAccess(
int
$access
)
|
|
Sets access level.
Sets access level.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$access: |
Access level. |
API Tags:
Information Tags:
void setCustomField(
string
$field, mixed
$value
)
|
|
Writes custom field.
Writes custom field.
Write field by it's name. Can write any field of given record that exists in database.
Note: You should use this method only for fields that are not provided in standard setters/getters (SVN fields). This method runs SQL query each time you call it so it highly overloads used resources.
Note: Make sure that you pass $value argument of correct type. This method determinates whether to quote field name. It is safe - it makes you sure that no unproper queries that could lead to SQL injection will be executed, but it can make your code working wrong way. For example: $object->setCustomField('foo', '1'); will quote 1 as as string ('1') instead of passing it as a integer.
Parameters:
|
string |
$field: |
Field name. |
|
mixed |
$value: |
Field value. |
API Tags:
Information Tags:
| Version: | 0.0.5 |
| Version: | 0.0.1 |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
| Since: | 0.0.3 |
| Throws: | PDOException On PDO operation error. |
void setFlags(
int
$flags
)
|
|
Sets rights flags.
Sets rights flags.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
void setMaxDepotItems(
int
$maxdepotitems
)
|
|
Sets maximum count of items in depot.
Sets maximum count of items in depot.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$maxdepotitems: |
Maximum value. |
API Tags:
Information Tags:
void setMaxVIPList(
int
$maxviplist
)
|
|
Sets maximum count of players in VIP list.
Sets maximum count of players in VIP list.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
|
int |
$maxviplist: |
Maximum value. |
API Tags:
Information Tags:
void setName(
string
$name
)
|
|
Sets group's name.
Sets group's name.
This method only updates object state. To save changes in database you need to use save() method to flush changed to database.
Parameters:
API Tags:
Information Tags:
mixed __get(
string
$name
)
|
|
Magic PHP5 method.
Magic PHP5 method.
Parameters:
|
string |
$name: |
Property name. |
API Tags:
| Return: | Property value. |
| Access: | public |
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | OutOfBoundsException For non-supported properties. |
| Throws: | E_OTS_NotLoaded If group is not loaded. |
| Throws: | PDOException On PDO operation error. |
| Since: | 0.1.0 |
void __set(
string
$name, mixed
$value
)
|
|
Magic PHP5 method.
Magic PHP5 method.
Parameters:
|
string |
$name: |
Property name. |
|
mixed |
$value: |
Property value. |
API Tags:
Information Tags:
| Version: | 0.1.0 |
| Version: | 0.0.1 |
| Throws: | OutOfBoundsException For non-supported properties. |
| Since: | 0.1.0 |
| Throws: | PDOException On PDO operation error. |
Returns string representation of object.
Returns string representation of object.
If any display driver is currently loaded then it uses it's method. Else it returns group name.
API Tags:
| Return: | String representation of object. |
| Access: | public |
Information Tags:
| Version: | 0.1.3 |
| Version: | 0.0.1 |
| Since: | 0.1.0 |