public function _mergeWithPrevious($previous)
    {
        if (!$previous)
        {
            return $this;
        }
        if ($previous instanceof DeleteOperation)
        {
            return new SetOperation($this->value);
        }
        if ($previous instanceof SetOperation)
        {
            return new SetOperation($previous->getValue() + $this->value);
        }
        if ($previous instanceof IncrementOperation)
        {
            return new IncrementOperation($previous->getValue() + $this->value);
        }
        throw new AVException('Operation is invalid after previous operation.');
    }