its possible to have static variables for traits:
Trait Example
{
public static $var;
}
class X
{
use Example;
}
class Y
{
use Example;
}
however, the problem is when more class would want to use this trait, I get a fatal error:
Example and X define the same property ($var) in the composition of Y. This might be incompatible, to improve maintainability consider using accessor methods in traits instead. Class was composed
how to define this static variable just for the trait itself?