String representation of a pointer.
()
| 107 | |
| 108 | // String representation of a pointer. |
| 109 | func (p *Pointer) String() string { |
| 110 | if len(p.referenceTokens) == 0 { |
| 111 | return emptyPointer |
| 112 | } |
| 113 | |
| 114 | return pointerSeparator + strings.Join(p.referenceTokens, pointerSeparator) |
| 115 | } |
| 116 | |
| 117 | // Offset returns the byte offset, in the raw JSON text of document, of the location referenced by |
| 118 | // this pointer's terminal token. |
no outgoing calls