Returns the character at the current position, or at a given offset away from the current position. If the position is beyond the limits of the document size, then an empty string '' is returned.
( self, offset=0 )
| 1654 | return helpers.char_is_json_eol(c) |
| 1655 | |
| 1656 | def peek( self, offset=0 ): |
| 1657 | """Returns the character at the current position, or at a |
| 1658 | given offset away from the current position. If the position |
| 1659 | is beyond the limits of the document size, then an empty |
| 1660 | string '' is returned. |
| 1661 | |
| 1662 | """ |
| 1663 | i = self.cpos + offset |
| 1664 | if i < 0 or i >= self.__cmax: |
| 1665 | return '' |
| 1666 | return self.__rawbuf[i] |
| 1667 | |
| 1668 | def peekstr( self, span=1, offset=0 ): |
| 1669 | """Returns one or more characters starting at the current |
no outgoing calls
no test coverage detected