Tournaments class.
More...
|
| Tournament (string jsonString) |
| Initializes a new instance of the Combu.Tournament class. More...
|
|
| Tournament (Hashtable data) |
| Initializes a new instance of the Combu.Tournament class. More...
|
|
virtual void | FromJson (string jsonString) |
| Initialize the object from a JSON formatted string. More...
|
|
virtual void | FromHashtable (Hashtable hash) |
| Initialize the object from a hashtable. More...
|
|
virtual void | Save (Action< bool, string > callback) |
| Save this instance in the database. More...
|
|
virtual void | Delete (Action< bool, string > callback) |
| Delete this instance from the database. More...
|
|
void | Leave (Action< bool, string > callback) |
|
|
static void | Delete (long idTournament, Action< bool, string > callback) |
| Delete the specified Tournament. More...
|
|
static void | Load (bool finished, SearchCustomData[] customData, System.Action< Tournament[]> callback) |
| Load the list of tournaments with the specified filters. More...
|
|
static void | Load (long id, System.Action< Tournament > callback) |
| Load the tournament with the specified id. More...
|
|
static void | Leave (long idTournament, long idUser, Action< bool, string > callback) |
|
static Tournament | QuickTournament (Profile[] users) |
| Creates a quick tournament. If the number of other users is 1 then it creates 3 rounds, else 2 rounds for each enemy. More...
|
|
|
long | id = 0 |
|
long | idOwner = 0 |
|
string | title = "" |
|
DateTime | dateCreation = DateTime.Now |
|
DateTime? | dateFinished = null |
|
Hashtable | customData = new Hashtable() |
|
|
Profile | owner [get] |
|
List< Match > | matches [get] |
|
bool | finished [get] |
|
◆ Tournament() [1/2]
Combu.Tournament.Tournament |
( |
string |
jsonString | ) |
|
Initializes a new instance of the Combu.Tournament class.
- Parameters
-
jsonString | JSON string to initialize the instance. |
◆ Tournament() [2/2]
Combu.Tournament.Tournament |
( |
Hashtable |
data | ) |
|
Initializes a new instance of the Combu.Tournament class.
- Parameters
-
data | Data to initialize the instance. |
◆ Delete() [1/2]
virtual void Combu.Tournament.Delete |
( |
Action< bool, string > |
callback | ) |
|
|
virtual |
Delete this instance from the database.
◆ Delete() [2/2]
static void Combu.Tournament.Delete |
( |
long |
idTournament, |
|
|
Action< bool, string > |
callback |
|
) |
| |
|
static |
Delete the specified Tournament.
- Parameters
-
idTournament | Identifier tournament. |
callback | Callback. |
◆ FromHashtable()
virtual void Combu.Tournament.FromHashtable |
( |
Hashtable |
hash | ) |
|
|
virtual |
Initialize the object from a hashtable.
- Parameters
-
◆ FromJson()
virtual void Combu.Tournament.FromJson |
( |
string |
jsonString | ) |
|
|
virtual |
Initialize the object from a JSON formatted string.
- Parameters
-
◆ Load() [1/2]
Load the list of tournaments with the specified filters.
- Parameters
-
finished | If set to true then it returns also the finished tournaments. |
customData | Custom data. |
callback | Callback. |
◆ Load() [2/2]
static void Combu.Tournament.Load |
( |
long |
id, |
|
|
System.Action< Tournament > |
callback |
|
) |
| |
|
static |
Load the tournament with the specified id.
- Parameters
-
id | Identifier. |
callback | Callback. |
◆ QuickTournament()
Creates a quick tournament. If the number of other users is 1 then it creates 3 rounds, else 2 rounds for each enemy.
- Returns
- The tournament.
- Parameters
-
users | The list of other users (excluding localUser). |
◆ Save()
virtual void Combu.Tournament.Save |
( |
Action< bool, string > |
callback | ) |
|
|
virtual |
Save this instance in the database.
- Parameters
-