Package org.omegat.core.statistics
Class Statistics
- java.lang.Object
-
- org.omegat.core.statistics.Statistics
-
public final class Statistics extends java.lang.Object
Save project statistic into text file.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
numberOfCharactersWithoutSpaces(java.lang.String str)
Computes the number of characters excluding spaces in a string.static int
numberOfCharactersWithSpaces(java.lang.String str)
Computes the number of characters with spaces in a string.static int
numberOfWords(java.lang.String str)
Computes the number of words in a string.static void
writeStat(java.lang.String filename, java.lang.String text)
Write text to file.
-
-
-
Method Detail
-
numberOfCharactersWithoutSpaces
public static int numberOfCharactersWithoutSpaces(java.lang.String str)
Computes the number of characters excluding spaces in a string. Special char for tag replacement not calculated.
-
numberOfCharactersWithSpaces
public static int numberOfCharactersWithSpaces(java.lang.String str)
Computes the number of characters with spaces in a string. Special char for tag replacement not calculated.
-
numberOfWords
public static int numberOfWords(java.lang.String str)
Computes the number of words in a string.
-
writeStat
public static void writeStat(java.lang.String filename, java.lang.String text)
Write text to file.- Parameters:
filename
-data
-
-
-