gapt.formats.json.JsonImporter.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gapt_3 Show documentation
Show all versions of gapt_3 Show documentation
General Architecture for Proof Theory
The newest version!
package gapt.formats.json
import gapt.formats.InputFile
import io.circe.Decoder
import io.circe.parser._
object JsonImporter {
/**
* Imports a value for which a Decoder exists from JSON.
*/
def load[A: Decoder](file: InputFile): A =
decode[A](file.read).toTry.get
}