mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
Merge pull request #621 from ebraminio/master
Format test and remove volatile, probably not needed for here
This commit is contained in:
@@ -10,9 +10,9 @@ import java.util.regex.Pattern;
|
||||
class EstimateDirection {
|
||||
private static final float RTL_DETECTION_THRESHOLD = 0.40f;
|
||||
|
||||
private static volatile String LTR_CHARS = "A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02B8\u0300-\u0590\u0800-\u1FFF"
|
||||
private static final String LTR_CHARS = "A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02B8\u0300-\u0590\u0800-\u1FFF"
|
||||
+ "\u2C00-\uFB1C\uFDFE-\uFE6F\uFEFD-\uFFFF";
|
||||
private static volatile String RTL_CHARS = "\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC";
|
||||
private static final String RTL_CHARS = "\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC";
|
||||
|
||||
private static final Pattern WORD_SEPARATOR_RE = Pattern.compile("\\s+");
|
||||
private static final Pattern FIRST_STRONG_IS_RTL_RE = Pattern.compile("^[^" + LTR_CHARS + "]*[" + RTL_CHARS + ']');
|
||||
|
||||
@@ -7,8 +7,8 @@ import static com.commafeed.backend.feed.EstimateDirection.isRTL;
|
||||
|
||||
/**
|
||||
* These tests are copied and simplified from GWT
|
||||
* https://github.com/google-web-toolkit/gwt/blob/master/user/test/com/google/gwt/i18n/shared/BidiUtilsTest.java
|
||||
* Released under Apache 2.0 license, credit of it goes to Google and please use GWT wherever possible instead of this
|
||||
* https://github.com/google-web-toolkit/gwt/blob/master/user/test/com/google/gwt/i18n/shared/BidiUtilsTest.java Released under Apache 2.0
|
||||
* license, credit of it goes to Google and please use GWT wherever possible instead of this
|
||||
*/
|
||||
public class EstimateDirectionTest {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user