Add unit tests and usage example to README

This commit is contained in:
victor
2015-08-19 15:52:10 +03:00
parent 013c358a1b
commit a4defb2112
8 changed files with 365 additions and 6 deletions

View File

@@ -26,6 +26,16 @@ class Value implements ValueInterface
$this->attribute = $attribute;
}
/**
* @param Attribute $attribute
*/
public function setAttribute(Attribute $attribute)
{
$this->attribute->removeValue($this); // Remove value from current attribute
$attribute->addValue($this); // Add value to new attribute
$this->attribute = $attribute;
}
/**
* @return Attribute
*/