public function subString($startPosition, $length)
    {
        if (!$this->isNumber($startPosition)) {
            throw new StringObjectException(StringObjectException::MSG_INVALID_ARG, [
                '$startPosition',
                'integer'
            ]);
        }

        if (!$this->isNumber($length)) {
            throw new StringObjectException(StringObjectException::MSG_INVALID_ARG, [
                '$length',
                'integer'
            ]);
        }

        if ($length == 0) {
            $length = null;
        }
        $value = mb_substr($this->val(), $startPosition, $length, self::DEF_ENCODING);
        $this->val($value);

        return $this;
    }