You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Before I get into the actual FR, some definitions:
Getter: A getX() method on a class that extends yii\base\BaseObject, without any required arguments, which yii\base\BaseObject::__get() will call when $obj->x is accessed.
// valid:publicfunction getAuthor()
public function getAuthor($arg = 'default')
// invalid:
public function getauthor() // lowercase 'a'
public function getAuthor($arg) // $arg is required
Setter: A setX() method on a class that extends yii\base\BaseObject, with one required argument (the first one), which yii\base\BaseObject::__set() will call when $obj->x is set to something.
// valid:publicfunction setAuthor($arg)
public function setAuthor($arg1, $arg2 = 'default')
// invalid:
public function setauthor() // lowercase 'a'
public function setAuthor() // no required argument
public function setAuthor($arg1, $arg2) // $arg2 is required
If a getter exists but no corresponding setter, the "Missing @Property annotations" inspection should create a @property-read tag instead of @property.
If a setter exists but no corresponding getter, then a @property-write tag should be created instead of @property.
If both exist, then continue to create a @property tag.
The text was updated successfully, but these errors were encountered:
Before I get into the actual FR, some definitions:
Getter: A
getX()
method on a class that extendsyii\base\BaseObject
, without any required arguments, whichyii\base\BaseObject::__get()
will call when$obj->x
is accessed.Setter: A
setX()
method on a class that extendsyii\base\BaseObject
, with one required argument (the first one), whichyii\base\BaseObject::__set()
will call when$obj->x
is set to something.If a getter exists but no corresponding setter, the "Missing @Property annotations" inspection should create a
@property-read
tag instead of@property
.If a setter exists but no corresponding getter, then a
@property-write
tag should be created instead of@property
.If both exist, then continue to create a
@property
tag.The text was updated successfully, but these errors were encountered: