case class JsSuccess[T](value: T, path: JsPath = JsPath()) extends JsResult[T] with Product with Serializable
- Alphabetic
- By Inheritance
- JsSuccess
- Serializable
- Serializable
- Product
- Equals
- JsResult
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
final
class
WithFilter extends AnyRef
- Definition Classes
- JsResult
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
asEither: Either[Seq[(JsPath, Seq[JsonValidationError])], T]
Returns either the result errors (at
Left
), or the successful value (atRight
). -
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
asOpt: Option[T]
Transforms this result either
Some
option with the successful value, or asNone
in case of JSON error. -
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
collect[B](otherwise: JsonValidationError)(p: PartialFunction[T, B]): JsResult[B]
- Definition Classes
- JsResult
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
filter(otherwise: JsError)(p: (T) ⇒ Boolean): JsResult[T]
- Definition Classes
- JsResult
-
def
filter(p: (T) ⇒ Boolean): JsResult[T]
- Definition Classes
- JsResult
-
def
filterNot(p: (T) ⇒ Boolean): JsResult[T]
- Definition Classes
- JsResult
-
def
filterNot(error: JsError)(p: (T) ⇒ Boolean): JsResult[T]
- Definition Classes
- JsResult
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
flatMap[U](f: (T) ⇒ JsResult[U]): JsResult[U]
If this result is successful, applies the function
f
on the parsed value. -
def
fold[U](invalid: (Seq[(JsPath, Seq[JsonValidationError])]) ⇒ U, valid: (T) ⇒ U): U
Either applies the
invalid
function if this result is an error, or applies thevalid
function on the successful value. -
def
foreach(f: (T) ⇒ Unit): Unit
If this result is successful, applies the function
f
on the parsed value. -
def
get: T
Not recommended
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
getOrElse[U >: T](t: ⇒ U): U
Either returns the successful value, or the value from
t
. - val isError: Boolean
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val isSuccess: Boolean
-
def
map[U](f: (T) ⇒ U): JsResult[U]
If this result is successful, applies the function
f
on the parsed value. -
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
orElse[U >: T](t: ⇒ JsResult[U]): JsResult[U]
Either returns this result if successful, or the result from
t
. - val path: JsPath
-
def
recover[U >: T](errManager: PartialFunction[JsError, U]): JsResult[U]
If this result is not successful, recovers the errors with the given function.
-
def
recoverTotal[U >: T](errManager: (JsError) ⇒ U): U
If this result is not successful, recovers the errors with the given function.
-
def
repath(path: JsPath): JsResult[T]
Updates the JSON path
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- val value: T
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
withFilter(p: (T) ⇒ Boolean): WithFilter
- Definition Classes
- JsResult