Documentations › mmo.math › php › operations ConstraintOperation MMO\math\operations · 1 symbol · generated 30 Sep 2026
class MMO\math\operations\ConstraintOperation extends MMO\math\operations\Operation Namespace MMO\math\operationsExtends Operation Methods4 function intervals(): array function numberValue(): int|float|null function toPolynome(MMO\math\helpers\Number $number): MMO\math\helpers\Polynome function __construct(
MMO\math\enums\cConstraintOperator|string $operator,
MMO\math\interfaces\iNumber|int|float $a,
MMO\math\interfaces\iNumber|int|float $b
) Inherited members (31) Methods Declared by Description addListener($callable, $target)Operation canCommute()Operation canInverseEquality()Operation clear()Operation Empty the underlying content, keeping the object itself. commute()Operation compareTo($value)Operation contains($num)Operation Test if operation contains the number or an instance of it count()Operation \Countable::count debugName()Operation execute()Operation extract($num, $result)Operation getIterator()Operation \IteratorAggregate::getIterator getOperator()Operation hasUnits()Operation inverseEquality($value)Operation isEmpty()Operation jsonSerialize()Operation \JsonSerializable::jsonSerialize -- the raw content is returned as-is (not recursively converted), so json_encode() relies on any nested iArray values being JsonSerializable themselves. keys()Operation loadArray($data)Operation Load every entry of a plain array into the content, through offsetSet (so any offsetSet() override defined by the class using this trait, e.g. loopNumber()Operation offsetExists($key)Operation \ArrayAccess::offsetExists offsetGet($key)Operation \ArrayAccess::offsetGet offsetSet($key, $value)Operation \ArrayAccess::offsetSet -- a null $key appends ($bag[] = $value), like a plain PHP array. offsetUnset($key)Operation \ArrayAccess::offsetUnset -- on a list (sequential integer keys, as produced by $bag[] = ...), the element is spliced out (closing the gap and reindexing), matching \unset() semantics on a plain … removeListener($callable)Operation simplify()Operation toArray()Operation Convert the content to a plain array, recursively converting any nested iArray value (e.g. units()Operation Get the units of this operation. __toString()Operation