Skip to content

Commit

Permalink
Annotation improvements.
Browse files Browse the repository at this point in the history
  • Loading branch information
lucaboesch committed Sep 25, 2023
1 parent ab07b4c commit 1ae083d
Show file tree
Hide file tree
Showing 18 changed files with 36 additions and 94 deletions.
4 changes: 1 addition & 3 deletions classes/model/instance.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ class instance {
* @var int The id.
*/
public $id;
/**
* @var int The template id.
*/
/** @var int The template id */
public $templateid;
/**
* @var int The course id.
Expand Down
2 changes: 1 addition & 1 deletion classes/model/instance_category.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class instance_category {
*
* @param int $id The instance category id
* @param int|null $paramtemplatecategoryid The parametrized template category id
* @param int $position The category position
* @param int $position The template category position
* @param float $weight The category weight
*/
public function __construct(int $id = 0, ?int $paramtemplatecategoryid = null, int $position = 0, float $weight = 0.0) {
Expand Down
2 changes: 1 addition & 1 deletion classes/model/instance_criterion.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class instance_criterion {
*
* @param int $id The id
* @param int|null $parametrizedtemplatecriterionid The parametrized template criterion id
* @param int $position The criterion position
* @param int $position The instance criterion position
* @param float $weight The criterion weight
* @param array $descriptions The criterion descriptions
* @param array $subratings The criterion subratings
Expand Down
2 changes: 1 addition & 1 deletion classes/model/template/parametrized_template_category.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class parametrized_template_category {
* The parametrized template category model constructor
* @param int $id The id
* @param int $categoryid The category id
* @param int $position The position
* @param int $position The parametrized template category position
* @param float $weight The weight
*/
public function __construct(int $id = 0, int $categoryid = 0, int $position = 0, float $weight = 0.0) {
Expand Down
3 changes: 1 addition & 2 deletions classes/model/template/parametrized_template_criterion.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
/**
* The parametrized template criterion class
*/
#[AllowDynamicProperties]
class parametrized_template_criterion {
/** @var int The id */
public $id;
Expand All @@ -45,7 +44,7 @@ class parametrized_template_criterion {
*
* @param int $id The id
* @param int $criterionid The parametrized template criterion id
* @param int $position The position
* @param int $position The parametrized template criterion position
* @param float $weight The weight
*/
public function __construct(int $id = 0, int $criterionid = 0, int $position = 0, float $weight = 0.0) {
Expand Down
12 changes: 3 additions & 9 deletions classes/repository/model/db_instance.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,17 +29,11 @@
* The database instance class
*/
class db_instance {
/**
* @var int
*/
/** @var int The id */
public $id = 0;
/**
* @var
*/
/** @var int The template id */
public $templateid;
/**
* @var
*/
/** @var string The name */
public $name;
/**
* @var
Expand Down
12 changes: 3 additions & 9 deletions classes/repository/model/db_instance_category.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database instance category class
*/
class db_instance_category {
/**
* @var
*/
/** @var int The id */
public $id;
/**
* @var
Expand All @@ -41,13 +39,9 @@ class db_instance_category {
* @var
*/
public $paramtemplatecategoryid;
/**
* @var
*/
/** @var int The position */
public $position;
/**
* @var
*/
/** @var float The weight */
public $weight;

/**
Expand Down
16 changes: 4 additions & 12 deletions classes/repository/model/db_instance_criterion.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,25 +29,17 @@
* The database instance criterion class
*/
class db_instance_criterion {
/**
* @var
*/
/** @var int The id */
public $id;
/**
* @var
*/
public $paramtemplatecriterionid;
/**
* @var
*/
/** @var int The category id */
public $categoryid;
/**
* @var
*/
/** @var int The position */
public $position;
/**
* @var
*/
/** @var float The weight */
public $weight;

/**
Expand Down
4 changes: 1 addition & 3 deletions classes/repository/model/db_language.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database language class
*/
class db_language {
/**
* @var int
*/
/** @var int The id */
public $id = 0;
/**
* @var
Expand Down
4 changes: 1 addition & 3 deletions classes/repository/model/db_localized_string.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database localized string class
*/
class db_localized_string {
/**
* @var int The id
*/
/** @var int The id */
public $id;
/**
* @var string The type
Expand Down
22 changes: 6 additions & 16 deletions classes/repository/model/db_parametrized_category.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,32 +29,22 @@
* The database parametrized category class
*/
class db_parametrized_category {
/**
* @var
*/
/** @var int The id */
public $id;
/**
* @var
*/
/** @var int The template id */
public $templateid;
/**
* @var
*/
/** @var int The parametrized template category id */
public $categoryid;
/**
* @var
*/
/** @var int The position */
public $position;
/**
* @var
*/
/** @var float The weight */
public $weight;

/**
* Return a parametrized template category database object
*
* @param parametrized_template_category $category
* @param int $templateid
* @param int $templateid The parametrized template category id
* @return db_parametrized_category
*/
public static function from_parametrized_category(parametrized_template_category $category, int $templateid) {
Expand Down
15 changes: 5 additions & 10 deletions classes/repository/model/db_parametrized_criterion.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,21 +28,16 @@
/**
* The database parametrized criterion class
*/
#[AllowDynamicProperties]
class db_parametrized_criterion {
/**
* @var
*/
/** @var int The id */
public $id;
/** @var int The category id */
public $categoryid;
/** @var int The criterion id */
public $criterionid;
/**
* @var
*/
/** @var int The position */
public $position;
/**
* @var
*/
/** @var float The weight */
public $weight;

/**
Expand Down
4 changes: 1 addition & 3 deletions classes/repository/model/db_response.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database response class
*/
class db_response {
/**
* @var int
*/
/** @var int The id */
public $id = 0;
/**
* @var
Expand Down
4 changes: 1 addition & 3 deletions classes/repository/model/db_submission.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database submission class
*/
class db_submission {
/**
* @var int
*/
/** @var int The id */
public $id = 0;
/**
* @var
Expand Down
4 changes: 1 addition & 3 deletions classes/repository/model/db_subrating.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database subrating class
*/
class db_subrating {
/**
* @var int The id
*/
/** @var int The id */
public $id = 0;
/** @var int The criterion id */
public $criterionid;
Expand Down
12 changes: 3 additions & 9 deletions classes/repository/model/db_template.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,17 +29,11 @@
* The database template class
*/
class db_template {
/**
* @var int The id
*/
/** @var int The id */
public $id = 0;
/**
* @var string The name
*/
/** @var string The name */
public $name;
/**
* @var string The description
*/
/** @var string The description */
public $description;

/**
Expand Down
4 changes: 1 addition & 3 deletions classes/repository/model/db_template_category.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database template category class
*/
class db_template_category {
/**
* @var int
*/
/** @var int The id */
public $id = 0;
/**
* @var
Expand Down
4 changes: 1 addition & 3 deletions classes/repository/model/db_template_criterion.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
* The database template criterion class
*/
class db_template_criterion {
/**
* @var int
*/
/** @var int The id */
public $id = 0;
/**
* @var string
Expand Down

0 comments on commit 1ae083d

Please sign in to comment.