Class/Object

io.circe

HCursor

Related Docs: object HCursor | package circe

Permalink

sealed abstract class HCursor extends GenericCursor[HCursor]

A cursor that tracks the history of operations performed with it.

Self Type
HCursor
See also

GenericCursor

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. HCursor
  2. GenericCursor
  3. Serializable
  4. Serializable
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. type Focus[x] = x

    Permalink

    The context that the cursor is available in.

    The context that the cursor is available in.

    Definition Classes
    HCursorGenericCursor
  2. type M[x[_]] = Functor[x]

    Permalink

    The type class including the operations needed for withFocusM.

    The type class including the operations needed for withFocusM.

    Definition Classes
    HCursorGenericCursor
  3. type Result = ACursor

    Permalink

    The type returned by navigation and modifications operations.

    The type returned by navigation and modifications operations.

    Definition Classes
    HCursorGenericCursor

Abstract Value Members

  1. abstract def history: List[HistoryOp]

    Permalink

Concrete Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def acursor: ACursor

    Permalink

    Create an ACursor for this cursor.

  5. final def as[A](implicit d: Decoder[A]): Decoder.Result[A]

    Permalink

    Attempt to decode the focus as an A.

    Attempt to decode the focus as an A.

    Definition Classes
    HCursorGenericCursor
  6. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  7. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. final val cursor: Cursor

    Permalink
  9. final def delete: ACursor

    Permalink

    Delete the focus and move to its parent.

    Delete the focus and move to its parent.

    Definition Classes
    HCursorGenericCursor
  10. final def deleteGoField(k: String): ACursor

    Permalink

    Delete the focus and move to the sibling with the given key in a JSON object.

    Delete the focus and move to the sibling with the given key in a JSON object.

    Definition Classes
    HCursorGenericCursor
  11. final def deleteGoFirst: ACursor

    Permalink

    Delete the focus and move to the first element in a JSON array.

    Delete the focus and move to the first element in a JSON array.

    Definition Classes
    HCursorGenericCursor
  12. final def deleteGoLast: ACursor

    Permalink

    Delete the focus and move to the last element in a JSON array.

    Delete the focus and move to the last element in a JSON array.

    Definition Classes
    HCursorGenericCursor
  13. final def deleteGoLeft: ACursor

    Permalink

    Delete the focus and move to the left in a JSON array.

    Delete the focus and move to the left in a JSON array.

    Definition Classes
    HCursorGenericCursor
  14. final def deleteGoRight: ACursor

    Permalink

    Delete the focus and move to the right in a JSON array.

    Delete the focus and move to the right in a JSON array.

    Definition Classes
    HCursorGenericCursor
  15. final def deleteLefts: ACursor

    Permalink

    Delete all values to the left of the focus in a JSON array.

    Delete all values to the left of the focus in a JSON array.

    Definition Classes
    HCursorGenericCursor
  16. final def deleteRights: ACursor

    Permalink

    Delete all values to the right of the focus in a JSON array.

    Delete all values to the right of the focus in a JSON array.

    Definition Classes
    HCursorGenericCursor
  17. final def downArray: ACursor

    Permalink

    If the focus is a JSON array, move to its first element.

    If the focus is a JSON array, move to its first element.

    Definition Classes
    HCursorGenericCursor
  18. final def downAt(p: (Json) ⇒ Boolean): ACursor

    Permalink

    If the focus is a JSON array, move to the first element that satisfies the given predicate.

    If the focus is a JSON array, move to the first element that satisfies the given predicate.

    Definition Classes
    HCursorGenericCursor
  19. final def downField(k: String): ACursor

    Permalink

    If the focus is a JSON object, move to the value of the given key.

    If the focus is a JSON object, move to the value of the given key.

    Definition Classes
    HCursorGenericCursor
  20. final def downN(n: Int): ACursor

    Permalink

    If the focus is a JSON array, move to the element at the given index.

    If the focus is a JSON array, move to the element at the given index.

    Definition Classes
    HCursorGenericCursor
  21. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  22. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  23. final def failedACursor: ACursor

    Permalink

    Create a failed ACursor for this cursor.

  24. final def field(k: String): ACursor

    Permalink

    If the focus is a value in a JSON object, move to a sibling with the given key.

    If the focus is a value in a JSON object, move to a sibling with the given key.

    Definition Classes
    HCursorGenericCursor
  25. final def fieldSet: Option[Set[String]]

    Permalink

    If the focus is a JSON object, return its field names in a set.

    If the focus is a JSON object, return its field names in a set.

    Definition Classes
    HCursorGenericCursor
  26. final def fields: Option[List[String]]

    Permalink

    If the focus is a JSON object, return its field names in their original order.

    If the focus is a JSON object, return its field names in their original order.

    Definition Classes
    HCursorGenericCursor
  27. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  28. final def find(p: (Json) ⇒ Boolean): ACursor

    Permalink

    If the focus is an element in a JSON array, find the first element at or to its right that matches the given predicate.

    If the focus is an element in a JSON array, find the first element at or to its right that matches the given predicate.

    Definition Classes
    HCursorGenericCursor
  29. final def first: ACursor

    Permalink

    If the focus is an element in a JSON array, move to the first element.

    If the focus is an element in a JSON array, move to the first element.

    Definition Classes
    HCursorGenericCursor
  30. final def focus: Json

    Permalink

    The current location in the document.

    The current location in the document.

    Definition Classes
    HCursorGenericCursor
  31. final def get[A](k: String)(implicit d: Decoder[A]): Decoder.Result[A]

    Permalink

    Attempt to decode the value at the given key in a JSON object as an A.

    Attempt to decode the value at the given key in a JSON object as an A.

    Definition Classes
    HCursorGenericCursor
  32. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  33. def getOrElse[A](k: String)(fallback: ⇒ A)(implicit d: Decoder[A]): Decoder.Result[A]

    Permalink

    Attempt to decode the value at the given key in a JSON object as an A.

    Attempt to decode the value at the given key in a JSON object as an A. If the field k is missing, then use the fallback instead.

    Definition Classes
    GenericCursor
  34. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  35. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  36. final def last: ACursor

    Permalink

    If the focus is an element in a JSON array, move to the last element.

    If the focus is an element in a JSON array, move to the last element.

    Definition Classes
    HCursorGenericCursor
  37. final def left: ACursor

    Permalink

    If the focus is an element in a JSON array, move to the left.

    If the focus is an element in a JSON array, move to the left.

    Definition Classes
    HCursorGenericCursor
  38. final def leftAt(p: (Json) ⇒ Boolean): ACursor

    Permalink

    If the focus is an element in a JSON array, move to the left until the given predicate matches the new focus.

    If the focus is an element in a JSON array, move to the left until the given predicate matches the new focus.

    Definition Classes
    HCursorGenericCursor
  39. final def leftN(n: Int): ACursor

    Permalink

    If the focus is an element in JSON array, move to the left the given number of times.

    If the focus is an element in JSON array, move to the left the given number of times.

    A negative value will move the cursor right.

    Definition Classes
    HCursorGenericCursor
  40. final def lefts: Option[List[Json]]

    Permalink

    If the focus is a JSON array, return the elements to the left.

    If the focus is a JSON array, return the elements to the left.

    Definition Classes
    HCursorGenericCursor
  41. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  42. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  43. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  44. final def reattempted: HCursor

    Permalink

    If the last operation was not successful, reattempt it.

  45. final def replay(history: List[HistoryOp]): ACursor

    Permalink

    Replay history (a list of operations in reverse "chronological" order) against this cursor.

    Replay history (a list of operations in reverse "chronological" order) against this cursor.

    Definition Classes
    HCursorGenericCursor
  46. final def right: ACursor

    Permalink

    If the focus is an element in a JSON array, move to the right.

    If the focus is an element in a JSON array, move to the right.

    Definition Classes
    HCursorGenericCursor
  47. final def rightAt(p: (Json) ⇒ Boolean): ACursor

    Permalink

    If the focus is an element in a JSON array, move to the right until the given predicate matches the new focus.

    If the focus is an element in a JSON array, move to the right until the given predicate matches the new focus.

    Definition Classes
    HCursorGenericCursor
  48. final def rightN(n: Int): ACursor

    Permalink

    If the focus is an element in JSON array, move to the right the given number of times.

    If the focus is an element in JSON array, move to the right the given number of times.

    A negative value will move the cursor left.

    Definition Classes
    HCursorGenericCursor
  49. final def rights: Option[List[Json]]

    Permalink

    If the focus is a JSON array, return the elements to the right.

    If the focus is a JSON array, return the elements to the right.

    Definition Classes
    HCursorGenericCursor
  50. final def set(j: Json): HCursor

    Permalink

    Replace the focus.

    Replace the focus.

    Definition Classes
    GenericCursor
  51. final def setLefts(js: List[Json]): ACursor

    Permalink

    Replace all values to the left of the focus in a JSON array.

    Replace all values to the left of the focus in a JSON array.

    Definition Classes
    HCursorGenericCursor
  52. final def setRights(js: List[Json]): ACursor

    Permalink

    Replace all values to the right of the focus in a JSON array.

    Replace all values to the right of the focus in a JSON array.

    Definition Classes
    HCursorGenericCursor
  53. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  54. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  55. final def top: Json

    Permalink

    Return to the root of the document.

    Return to the root of the document.

    Definition Classes
    HCursorGenericCursor
  56. final def up: ACursor

    Permalink

    Move the focus to the parent.

    Move the focus to the parent.

    Definition Classes
    HCursorGenericCursor
  57. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  58. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  59. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  60. final def withFocus(f: (Json) ⇒ Json): HCursor

    Permalink

    Modify the focus using the given function.

    Modify the focus using the given function.

    Definition Classes
    HCursorGenericCursor
  61. final def withFocusM[F[_]](f: (Json) ⇒ F[Json])(implicit arg0: Functor[F]): F[HCursor]

    Permalink

    Modify the focus in a context using the given function.

    Modify the focus in a context using the given function.

    Definition Classes
    HCursorGenericCursor

Deprecated Value Members

  1. final def traverseDecode[A](init: A)(op: (HCursor) ⇒ ACursor, f: (A, HCursor) ⇒ Decoder.Result[A]): Decoder.Result[A]

    Permalink

    Traverse taking op at each step, performing f on the current cursor and accumulating A.

    Traverse taking op at each step, performing f on the current cursor and accumulating A.

    This operation does not consume stack at each step, so is safe to work with large structures (in contrast with recursively binding).

    Annotations
    @deprecated
    Deprecated

    (Since version 0.5.0) No direct replacement

  2. final def traverseDecodeAccumulating[A](init: AccumulatingDecoder.Result[A])(op: (HCursor) ⇒ ACursor, f: (AccumulatingDecoder.Result[A], HCursor) ⇒ AccumulatingDecoder.Result[A]): AccumulatingDecoder.Result[A]

    Permalink

    Traverse taking op at each step, performing f on the current cursor and accumulating A.

    Traverse taking op at each step, performing f on the current cursor and accumulating A.

    This operation does not consume stack at each step, so is safe to work with large structures (in contrast with recursively binding).

    Annotations
    @deprecated @tailrec()
    Deprecated

    (Since version 0.5.0) No direct replacement

Inherited from GenericCursor[HCursor]

Inherited from Serializable

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Miscellaneous utilities

Type members

HCursor fields and operations

Access and navigation

Modification

Array access

Object access

Array navigation

Object navigation

Array modification

Object modification

Decoding