Question

How can i read a srt file , do some operations in it and finally export it in srt format in JAVA?

i wanna do it to create a program that change the time of a subtitle.

att,

Diego Sabino

Était-ce utile?

La solution

Note that these programs already exists.

Search for: BufferedReader, InputStreamReader, FileInputStream. Use them like this:

BufferedReader reader = new BufferedReader(new InputStreamReader(new FileInputStream(file), "UTF-8"));
String line;
while ((line = reader.readLine()) != null)
{
    System.out.println(line);
}
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top