| @@ -10,6 +10,9 @@ | ||
| 10 | 10 | */ | 
| 11 | 11 |  class Jam_Exception_Upload extends Kohana_Jam_Exception_Upload { | 
| 12 | 12 | |
| 13 | + /** | |
| 14 | + * @param string $message | |
| 15 | + */ | |
| 13 | 16 | function __construct($message, $fields = NULL) | 
| 14 | 17 |  	{ | 
| 15 | 18 | parent::__construct($message, $fields); | 
| @@ -26,6 +26,9 @@ | ||
| 26 | 26 | } | 
| 27 | 27 | |
| 28 | 28 | |
| 29 | + /** | |
| 30 | + * @param string $unit | |
| 31 | + */ | |
| 29 | 32 | public static function to_css_style($param, $unit = NULL) | 
| 30 | 33 |  	{ | 
| 31 | 34 | if ($unit === NULL) | 
| @@ -416,6 +416,10 @@ discard block | ||
| 416 | 416 | return new $class($model); | 
| 417 | 417 | } | 
| 418 | 418 | |
| 419 | + /** | |
| 420 | + * @param string $method | |
| 421 | + * @param string $model | |
| 422 | + */ | |
| 419 | 423 | protected static function find_or($method, $model, array $values) | 
| 420 | 424 |  	{ | 
| 421 | 425 | $collection = Jam::all($model); | 
| @@ -517,6 +521,9 @@ discard block | ||
| 517 | 521 | return Jam_Validator_Attributes::factory($permit)->data($data)->clean(); | 
| 518 | 522 | } | 
| 519 | 523 | |
| 524 | + /** | |
| 525 | + * @param string $class | |
| 526 | + */ | |
| 520 | 527 | public static function form($model, $class = NULL) | 
| 521 | 528 |  	{ | 
| 522 | 529 | if ($class === NULL) | 
| @@ -151,6 +151,7 @@ discard block | ||
| 151 | 151 | |
| 152 | 152 | /** | 
| 153 | 153 | * Implement ArrayAccess. Lazy load with _load_content | 
| 154 | + * @param integer|null $offset | |
| 154 | 155 | */ | 
| 155 | 156 | public function offsetSet($offset, $value) | 
| 156 | 157 |  	{ | 
| @@ -170,6 +171,7 @@ discard block | ||
| 170 | 171 | |
| 171 | 172 | /** | 
| 172 | 173 | * Implement ArrayAccess. Lazy load with _load_content | 
| 174 | + * @param integer $offset | |
| 173 | 175 | */ | 
| 174 | 176 | public function offsetUnset($offset) | 
| 175 | 177 |  	{ | 
| @@ -17,6 +17,9 @@ discard block | ||
| 17 | 17 | protected $_association; | 
| 18 | 18 | protected $_parent; | 
| 19 | 19 | |
| 20 | + /** | |
| 21 | + * @param Jam_Validated $parent | |
| 22 | + */ | |
| 20 | 23 | public function parent($parent = NULL) | 
| 21 | 24 |  	{ | 
| 22 | 25 | if ($parent !== NULL) | 
| @@ -27,6 +30,9 @@ discard block | ||
| 27 | 30 | return $this->_parent; | 
| 28 | 31 | } | 
| 29 | 32 | |
| 33 | + /** | |
| 34 | + * @param Kohana_Jam_Association_Collection $association | |
| 35 | + */ | |
| 30 | 36 | public function association($association = NULL) | 
| 31 | 37 |  	{ | 
| 32 | 38 | if ($association !== NULL) | 
| @@ -80,7 +86,7 @@ discard block | ||
| 80 | 86 | /** | 
| 81 | 87 | * Use the association to get the item from the collection | 
| 82 | 88 | * @param integer $offset | 
| 83 | - * @return mixed | |
| 89 | + * @return Jam_Model | |
| 84 | 90 | */ | 
| 85 | 91 | public function offsetGet($offset) | 
| 86 | 92 |  	{ | 
| @@ -79,7 +79,7 @@ discard block | ||
| 79 | 79 | |
| 80 | 80 | /** | 
| 81 | 81 | * Getter of the meta object for this iterator (based on $_model) | 
| 82 | - * @return Jam_Model | |
| 82 | + * @return Jam_Meta | |
| 83 | 83 | * @throws Kohana_Exception If $_model not present | 
| 84 | 84 | */ | 
| 85 | 85 | public function meta() | 
| @@ -248,6 +248,10 @@ discard block | ||
| 248 | 248 | return NULL; | 
| 249 | 249 | } | 
| 250 | 250 | |
| 251 | + /** | |
| 252 | + * @param string $key | |
| 253 | + * @param string $value | |
| 254 | + */ | |
| 251 | 255 | public function as_array($key = NULL, $value = NULL) | 
| 252 | 256 |  	{ | 
| 253 | 257 | $results = array(); | 
| @@ -72,6 +72,9 @@ | ||
| 72 | 72 | return FALSE; | 
| 73 | 73 | } | 
| 74 | 74 | |
| 75 | + /** | |
| 76 | + * @param string $type | |
| 77 | + */ | |
| 75 | 78 | abstract public function join($table, $type = NULL); | 
| 76 | 79 | |
| 77 | 80 | public function set(Jam_Validated $model, $value, $is_changed) | 
| @@ -48,7 +48,6 @@ discard block | ||
| 48 | 48 | /** | 
| 49 | 49 | * Initialize foreign_key, as, and polymorphic_key with default values | 
| 50 | 50 | * | 
| 51 | - * @param string $model | |
| 52 | 51 | * @param string $name | 
| 53 | 52 | */ | 
| 54 | 53 | public function initialize(Jam_Meta $meta, $name) | 
| @@ -268,6 +267,10 @@ discard block | ||
| 268 | 267 | } | 
| 269 | 268 | |
| 270 | 269 | |
| 270 | + /** | |
| 271 | + * @param string|null $polymorphic_key | |
| 272 | + * @param Jam_Validated|null $inverse_of | |
| 273 | + */ | |
| 271 | 274 | protected function assign_item(Jam_Model $item, $foreign_key, $polymorphic_key, $inverse_of) | 
| 272 | 275 |  	{ | 
| 273 | 276 |  		$item->{$this->foreign_key} = $foreign_key; | 
| @@ -31,7 +31,6 @@ discard block | ||
| 31 | 31 | /** | 
| 32 | 32 | * Automatically sets foreign to sensible defaults. | 
| 33 | 33 | * | 
| 34 | - * @param string $model | |
| 35 | 34 | * @param string $name | 
| 36 | 35 | * @return void | 
| 37 | 36 | */ | 
| @@ -147,6 +146,9 @@ discard block | ||
| 147 | 146 | return $this->set($model, $item, $is_changed); | 
| 148 | 147 | } | 
| 149 | 148 | |
| 149 | + /** | |
| 150 | + * @param boolean $is_changed | |
| 151 | + */ | |
| 150 | 152 | public function set(Jam_Validated $model, $value, $is_changed) | 
| 151 | 153 |  	{ | 
| 152 | 154 | if ($value instanceof Jam_Model) | 
| @@ -285,6 +287,9 @@ discard block | ||
| 285 | 287 | return (bool) $this->as; | 
| 286 | 288 | } | 
| 287 | 289 | |
| 290 | + /** | |
| 291 | + * @param string $foreign_model | |
| 292 | + */ | |
| 288 | 293 | protected function _find_item($foreign_model, $key) | 
| 289 | 294 |  	{ | 
| 290 | 295 | if ( ! $key) | 
| @@ -308,6 +313,9 @@ discard block | ||
| 308 | 313 | return $query->current(); | 
| 309 | 314 | } | 
| 310 | 315 | |
| 316 | + /** | |
| 317 | + * @param string $type | |
| 318 | + */ | |
| 311 | 319 | public function query_builder($type, Jam_Model $model) | 
| 312 | 320 |  	{ | 
| 313 | 321 |  		$query = call_user_func("Jam::{$type}", $this->foreign_model) |