public function setEncoding($encoding)
	{
		if ( ! is_string($encoding) || ! in_array($encoding, mb_list_encodings())) {
			throw new \InvalidArgumentException(
				__METHOD__."() expects parameter one, encoding, to be a valid "
				 . "character encoding name"
			);
		}
		
		$this->encoding = $encoding;
		
		return $this;
	}
public function setEncoding($encoding)
	{
		if ( ! is_string($encoding) || ! in_array($encoding, mb_list_encodings())) {
			throw new \InvalidArgumentException(
				__METHOD__."() expects parameter one, encoding, to be a valid "
				 . "character encoding name"
			);
		}
		
		$this->encoding = $encoding;
		
		return $this;
	}
public function setEncoding ( $ encoding ) { if ( ! is_string ( $ encoding ) || ! in_array ( $ encoding , mb_list_encodings ( ) ) ) { throw new \ InvalidArgumentException ( __METHOD__ . "() expects parameter one, encoding, to be a valid " . "character encoding name" ) ; } $ this -> encoding = $ encoding ; return $ this ; }
Sets the chunker's character encoding

@param  string|null  $encoding  the chunker's character encoding
@throws  InvalidArgumentException  if $encoding is not an supported charset;
the special string 'auto'; or, null
@since  0.1.0
Sets the chunker s character encoding