public CharSequence getCoveredText ( CharSequence text ) { if ( getEnd ( ) > text . length ( ) ) { throw new IllegalArgumentException ( "The span " + toString ( ) + " is outside the given text!" ) ; } return text . subSequence ( getStart ( ) , getEnd ( ) ) ; }
Retrieves the string covered by the current span of the specified text .