Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

encode file to utf-8 in java

  String charset = "ISO-8859-1"; // or what corresponds
  BufferedReader in = new BufferedReader( 
      new InputStreamReader (new FileInputStream(file), charset));
  String line;
  while( (line = in.readLine()) != null) { 
    ....
  }
Comment

PREVIOUS NEXT
Code Example
Java :: java 14 switch 
Java :: remove duplicates from arraylist in android 
Java :: declaration in java 
Java :: limit decimals java 
Java :: Java Remove HashMap Elements 
Java :: get value from Spring application.properties 
Java :: java casting to int 
Java :: lambda expression java 
Java :: java code for logarithm 
Java :: get string size 
Java :: interface vs abstract class java 
Java :: switch in java 
Java :: static block in java 
Java :: java design patterns 
Java :: CORS with Spring Boot 
Java :: java hashmap 
Java :: how to remove an element from an arraylist java 
Java :: interface declaration in java 
Java :: set array length java 
Java :: kafkalistener annotation pass topic from properties file 
Java :: java evaluate two expressions in if statemenmt 
Java :: Multi basic auth with spring security 
Java :: foreach() java 
Java :: how to set credentials for speechClient Java google api 
Java :: print zpl from java 
Java :: what is java.io example 
Java :: javacal 
Java :: 2d matrix multiplication 
Java :: size of a tree node java linked;ist 
Java :: unparseable date android 
ADD CONTENT
Topic
Content
Source link
Name
1+7 =