Skip to content

Commit

Permalink
WIP: Introduce Attributes::setCallback()
Browse files Browse the repository at this point in the history
  • Loading branch information
lippserd authored and nilmerg committed Apr 28, 2021
1 parent 3444302 commit 35b852d
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/Attributes.php
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,13 @@ public function setPrefix($prefix)
return $this;
}

public function setCallback($name, $getter, $setter = null)
{
$this->registerAttributeCallback($name, $getter, $setter);

return $this;
}

/**
* Register callback for an attribute
*
Expand Down

0 comments on commit 35b852d

Please sign in to comment.