MCPcopy Create free account
hub / github.com/PHPantom-dev/phpantom_lsp / attributes

Method attributes

benches/fixtures/yii/Model.php:267–278  ·  view source on GitHub ↗

* Returns the list of attribute names. * By default, this method returns all public non-static properties of the class. * You may override this method to change the default behavior. * @return array list of attribute names. */

()

Source from the content-addressed store, hash-verified

265 * @return array list of attribute names.
266 */
267 public function attributes()
268 {
269 $class = new ReflectionClass($this);
270 $names = [];
271 foreach ($class->getProperties(\ReflectionProperty::IS_PUBLIC) as $property) {
272 if (!$property->isStatic()) {
273 $names[] = $property->getName();
274 }
275 }
276
277 return $names;
278 }
279
280 /**
281 * Returns the attribute labels.

Callers 7

getAttributesMethod · 0.95
setAttributesMethod · 0.95
fieldsMethod · 0.95
hasAttributeMethod · 0.45
getDirtyAttributesMethod · 0.45
refreshInternalMethod · 0.45
populateRecordMethod · 0.45

Calls 1

getNameMethod · 0.45

Tested by

no test coverage detected