original_string: public function slice($offset, $length = null) {
  		$offset = $this->prepareOffset($offset);
  		$length = $this->prepareLength($offset, $length);
  
  		if ($length === 0) {
  			return new Text('', $this->encoding);
  		}
  
  		return new Text(mb_substr($this->string, $offset, $length, $this->encoding), $this->encoding);
  	}
code: public function slice($offset, $length = null) {
  		$offset = $this->prepareOffset($offset);
  		$length = $this->prepareLength($offset, $length);
  
  		if ($length === 0) {
  			return new Text('', $this->encoding);
  		}
  
  		return new Text(mb_substr($this->string, $offset, $length, $this->encoding), $this->encoding);
  	}
code_tokens: public function slice ( $ offset , $ length = null ) { $ offset = $ this -> prepareOffset ( $ offset ) ; $ length = $ this -> prepareLength ( $ offset , $ length ) ; if ( $ length === 0 ) { return new Text ( '' , $ this -> encoding ) ; } return new Text ( mb_substr ( $ this -> string , $ offset , $ length , $ this -> encoding ) , $ this -> encoding ) ; }
docstring: Slices a piece of the string from a given offset with a specified length.
  If no length is given, the String is sliced to its maximum length.
  
  @see #substring
  @param int $offset
  @param int $length
  @return Text
docstring_tokens: Slices a piece of the string from a given offset with a specified length . If no length is given the String is sliced to its maximum length .