@@ -21,6 +21,7 @@ discard block |
||
| 21 | 21 | |
| 22 | 22 | /** |
| 23 | 23 | * This is a constructor; a default method that will be called automatically during class instantiation |
| 24 | + * @param string|false $modelClassName |
|
| 24 | 25 | */ |
| 25 | 26 | public function __construct($modelClassName, $dbConn = Null) |
| 26 | 27 | { |
@@ -35,6 +36,7 @@ discard block |
||
| 35 | 36 | /** |
| 36 | 37 | * This method create a record and store it in a table row |
| 37 | 38 | * @params associative array, string tablename |
| 39 | + * @param string|false $tableName |
|
| 38 | 40 | * @return boolean true or false |
| 39 | 41 | */ |
| 40 | 42 | public function create($associative1DArray, $tableName, $dbConn = Null) |
@@ -69,6 +71,7 @@ discard block |
||
| 69 | 71 | /** |
| 70 | 72 | * This method updates any table by supplying 3 parameter |
| 71 | 73 | * @params: $updateParams, $tableName, $associative1DArray |
| 74 | + * @param string|false $tableName |
|
| 72 | 75 | * @return boolean true or false |
| 73 | 76 | */ |
| 74 | 77 | public function update(array $updateParams, $tableName, $associative1DArray, $dbConn = Null) |
@@ -101,6 +104,7 @@ discard block |
||
| 101 | 104 | /** |
| 102 | 105 | * This method retrieves record from a table |
| 103 | 106 | * @params int id, string tableName |
| 107 | + * @param string|false $tableName |
|
| 104 | 108 | * @return array |
| 105 | 109 | */ |
| 106 | 110 | public static function read($id, $tableName, $dbConn = Null) |
@@ -131,6 +135,7 @@ discard block |
||
| 131 | 135 | /** |
| 132 | 136 | * This method deletes a record from a table row |
| 133 | 137 | * @params int id, string tableName |
| 138 | + * @param string|false $tableName |
|
| 134 | 139 | * @return boolean true or false |
| 135 | 140 | */ |
| 136 | 141 | public static function delete($id, $tableName, $dbConn = Null) |
@@ -163,7 +168,7 @@ discard block |
||
| 163 | 168 | |
| 164 | 169 | /** |
| 165 | 170 | * This method returns sql query |
| 166 | - * @param $sql |
|
| 171 | + * @param string $sql |
|
| 167 | 172 | * @return string |
| 168 | 173 | */ |
| 169 | 174 | public function prepareUpdateQuery($sql) |
@@ -204,6 +209,7 @@ discard block |
||
| 204 | 209 | * This method returns column fields of a particular table |
| 205 | 210 | * @param $table |
| 206 | 211 | * @param $conn |
| 212 | + * @param DatabaseConnection $dbConn |
|
| 207 | 213 | * @return array |
| 208 | 214 | */ |
| 209 | 215 | public function getColumnNames($table, $dbConn = Null) { |
@@ -117,7 +117,7 @@ discard block |
||
| 117 | 117 | /** |
| 118 | 118 | * This method find a record by id |
| 119 | 119 | * @params int id |
| 120 | - * @return Object |
|
| 120 | + * @return BaseModel |
|
| 121 | 121 | * @throws NoArgumentPassedToFunctionException |
| 122 | 122 | */ |
| 123 | 123 | public static function find($id) |
@@ -168,7 +168,7 @@ discard block |
||
| 168 | 168 | /** |
| 169 | 169 | * This method return the current class name |
| 170 | 170 | * $params void |
| 171 | - * @return classname |
|
| 171 | + * @return string|false |
|
| 172 | 172 | */ |
| 173 | 173 | public static function getClassName() |
| 174 | 174 | { |