Skip to content

Commit 64f11f8

Browse files
committed
Update README.md
1 parent aa53f78 commit 64f11f8

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
[![Build Status](https://travis-ci.org/farbodsafaei/alphanumeric-comparator.svg?branch=master)](https://travis-ci.org/farbodsafaei/alphanumeric-comparator)
22
# alphanumeric-comparator
33

4-
An alphanumeric comparator in Java, for comparing strings in a human readable format. It uses a combination numeric and alphabetic comparisons to compare two strings. This class uses standard Java classes and is independent of any 3rd party libraries.
4+
An alphanumeric comparator in Java, for comparing strings in a human readable format. It uses a combination of numeric and alphabetic comparisons to compare two strings. This class uses standard Java classes and is independent of any 3rd party libraries.
55

6-
Additionally this comparator uses ```java.text.Collator``` class to correctly sort strings containing special Unicode characters like Umlauts or other similar letters of alphabet in different languages, such as: **å**, **è**, **ü**, **ö**, **ø**, or **ý**.
6+
Additionally this comparator uses ```java.text.Collator``` class to correctly sort strings containing special characters like Umlauts or similar alphabet letters in different languages, such as: **å**, **è**, **ü**, **ö**, **ø**, or **ý**.
77

88
#### Example #1
99
For given list of strings:
1010
- file-01.doc
1111
- file-2.doc
1212
- file-03.doc
1313

14-
The regular lexicographical sorts, e.g. ```java.util.Collections.sort()```, sorts the above list in following order:
14+
A regular lexicographical sort, e.g. ```java.util.Collections.sort()```, sorts the above list in the following order:
1515

1616
***[file-01.doc, file-03.doc, file-2.doc]***
1717

18-
However using ```AlphaNumericComparator```, the list will be sorter in more meaningful and readable way:
18+
However using ```AlphaNumericComparator```, the list will be sorted in a more meaningful and readable way:
1919

2020
***[file-01.doc, file-2.doc, file-03.doc]***
2121

@@ -29,7 +29,7 @@ For the following list of characters/strings:
2929
* è
3030
* g
3131

32-
The regular lexicographical sorts, e.g. ```java.util.Collections.sort()```, sorts the above list in following order:
32+
A regular lexicographical sort, e.g. ```java.util.Collections.sort()```, sorts the above list in the following order:
3333

3434
**[b, e, f, g, k, è, ě]**
3535

@@ -39,7 +39,7 @@ Using ```AlphaNumericComparator```, the list is correctly sorted as below:
3939

4040
#### How To
4141

42-
Just pass the comparator as a parameter when sorting a list:
42+
Simply pass the comparator as a parameter when sorting a list:
4343
```java
4444
List<String> list = new ArrayList<String>();
4545
list.add("some string");

0 commit comments

Comments
 (0)