Skip to content

Commit e7a0a4d

Browse files
committed
documenting the different query cases
1 parent dbb4a87 commit e7a0a4d

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

matrix-sdk-android/src/main/java/org/matrix/android/sdk/api/query/QueryStringValue.kt

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,23 @@ sealed interface QueryStringValue {
3535
data class Contains(override val string: String, override val case: Case = Case.SENSITIVE) : ContentQueryStringValue
3636

3737
enum class Case {
38+
/**
39+
* Match query sensitive to case
40+
*/
3841
SENSITIVE,
42+
43+
/**
44+
* Match query insensitive to case, this only works for Latin-1 character sets
45+
*/
3946
INSENSITIVE,
47+
48+
/**
49+
* Match query with input normalized (case insensitive)
50+
* Works around Realms inability to sort or filter by case for non Latin-1 character sets
51+
* Expects the target field to contain normalized data
52+
*
53+
* @see org.matrix.android.sdk.internal.util.Normalizer.normalize
54+
*/
4055
NORMALIZED
4156
}
4257
}

0 commit comments

Comments
 (0)