-
- All Implemented Interfaces:
-
android.os.Parcelable,org.readium.r2.shared.JSONable
public final class Locator.Text implements JSONable, Parcelable
Textual context of the locator.
A Locator Text Object contains multiple text fragments, useful to give a context to the Locator or for highlights. https://github.com/readium/architecture/tree/master/models/locators#the-text-object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classLocator.Text.Companion
-
Constructor Summary
Constructors Constructor Description Locator.Text(String before, String highlight, String after)
-
Method Summary
Modifier and Type Method Description final StringgetBefore()final StringgetHighlight()final StringgetAfter()JSONObjecttoJSON()Serializes the object to its JSON representation. final Locator.Textsubstring(IntRange range)-
-
Method Detail
-
getHighlight
final String getHighlight()
-
toJSON
JSONObject toJSON()
Serializes the object to its JSON representation.
-
substring
final Locator.Text substring(IntRange range)
-
-
-
-