FAQ Database Discussion Community


Specs2 can't see a defined class in lift

scala,lift
Here is the code (from the Lift Framework Cookbook): package code.snippet import scala.xml.Text import net.liftweb.util.Helpers._ /** * Created by kaiyin on 20/06/15. */ class Animals { def list = { val animals = List( ("Dog", "(Canis lupus)"), ("Cat", "(Felis catus)"), ("Giraffe", "(Giraffa camelopardalis)"), ("Lion", "(Panthera leo)"), ("Horse", "(Equus ferus caballus)")...

Trouble adding Mapper as dependency in a Lift project

scala,orm,dependencies,lift
I am doing my first Lift project and want to add a database. Following a book, I added the following dependency to build.sbt: "net.liftweb" %% "lift-mapper" % liftVersion % "compile", And then, in Boot.scala, the import import net.liftweb.mapper._ Now the project doesn't compile, with Boot.scala giving the error object mapper...

Convert JValue to String in Lift Scala

json,scala,parsing,lift
I have json string. I converted it to JValue using net.liftweb.JsonParser val x : JValue = parse(json) Then i modified the value of a field called "name" using replace() x.replace("name" :: Nil, JString("Tim")) Question is how do i convert this JValue back to a json String...

Which LiftResponse class is appropriate for returning an XML based file format?

xml,http,lift
I have a Lift application which generates a Gephi file on the fly. The Gehpi native format is XML based. The current plan is that the file gets downloaded and opened in Gephi on the client, without being processed/displayed in the browser. I looked through the LiftResponse subclasses and it...

How do I add scalatest dependency to an existing scala/lift project?

scala,lift,scalatest
I am trying to add scalatest support to an existing scala and lift app I add a dependency to build.sbt as per the following excerpt resolvers ++= Seq( "Java.net Maven2 Repository" at "http://download.java.net/maven/2/", "Sonatype scala-tools repo" at "https://oss.sonatype.org/content/groups/scala-tools/", "Sonatype scala-tools releases" at "https://oss.sonatype.org/content/repositories/releases", "Sonatype scala-tools snapshots" at "https://oss.sonatype.org/content/repositories/snapshots" ) libraryDependencies...

What is the lifetime of an object when using Lift?

scala,lift,lifecycle
I'm completely new to Lift. My goal is to make a small application which will let me enter data about scientific articles (studies) into a database. I haven't gotten around to making a database yet, still playing with getting an entry form to work. So I decided that I will...