All Downloads are FREE. Search and download functionalities are using the official Maven repository.

eu.timepit.refined.jsonpath.string.scala Maven / Gradle / Ivy

There is a newer version: 0.11.2
Show newest version
package eu.timepit.refined.jsonpath

import com.jayway.jsonpath.internal.path.PathCompiler
import eu.timepit.refined.api.Validate

object string {

  /** Predicate that checks if a `String` is a valid JSON path. */
  final case class JSONPath()

  object JSONPath {
    implicit def jsonPathValidate: Validate.Plain[String, JSONPath] =
      Validate.fromPartial(PathCompiler.compile(_), "JSONPath", JSONPath())
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy