title: Java inputStreamReader Charset
body: <p>I want to ping a target IP address and receive a response. To achieve this, I'm using windows command line in Java with runtime.exec method and process class. I'm getting the response using inputStreamReader.</p>
  
  <p>My default charset is windows-1254, it's Turkish. When I receive it, the response contains Turkish characters but Turkish characters are not displayed correctly in the console.</p>
  
  <p>I want to get a numeric value from the response I get but the value that I am searching for contains some Turkish characters, so when I look it up, I can't find it.</p>
  
  <p>The codes are below, what I need to know is how to get the Turkish characters visible here:</p>
  
  <pre><code>runtime = Runtime.getRuntime();
  process = runtime.exec(pingCommand);
  
  BufferedReader bReader = new BufferedReader(
          new InputStreamReader(process.getInputStream(), "UTF8"));
  
  String inputLine;
  while ((inputLine = bReader.readLine()) != null) {
      pingResult += inputLine;
  }
  
  bReader.close();
  process.destroy();
  
  System.out.println(pingResult);
  </code></pre>