src/main/php/ConsoleOutputStream.php
private static function create(string $target): OutputStream
    {
        $out      = new self(fopen($target, 'w'));
        $encoding = self::detectOutputEncoding();
        if ('UTF-8' !== $encoding) {
            $out = new EncodingOutputStream($out, $encoding . '//IGNORE');
        }

        return $out;
    }
private static function create(string $target): OutputStream
    {
        $out      = new self(fopen($target, 'w'));
        $encoding = self::detectOutputEncoding();
        if ('UTF-8' !== $encoding) {
            $out = new EncodingOutputStream($out, $encoding . '//IGNORE');
        }

        return $out;
    }
private static function create ( string $ target ) : OutputStream { $ out = new self ( fopen ( $ target , 'w' ) ) ; $ encoding = self :: detectOutputEncoding ( ) ; if ( 'UTF-8' !== $ encoding ) { $ out = new EncodingOutputStream ( $ out , $ encoding . '//IGNORE' ) ; } return $ out ; }
creates output stream with respect to output encoding

@param   string  $target
@return  \stubbles\streams\OutputStream
creates output stream with respect to output encoding