Sorry, Salat does not support a collection wrapped in an Option.
On Apr 16, 7:22 am, Daniel Eggert <
daniel.egg...@umzugsagenten.de>
wrote:
> I'm (still) new to Salat and Scala and I'm having trouble understanding the
> collection support. I have
>
> case class Move(@Key("_id") id: ObjectId = new ObjectId, fromAddress:
> String, toAddress: String, owner: ObjectId, log:
> Option[scala.collection.immutable.Seq[LogEntry]])
>
> object MoveDAO extends SalatDAO[Move, ObjectId](collection =
> Database.collection("moves"))
>
> but when I try to use
>
> val move1 = Move(fromAddress = u fromAddress, toAddress = u toAddress,
> owner = userID.get, log = None)
>
> I get this error:
>
> play.core.ActionInvoker$$anonfun$receive$1$$anon$1: Execution exception
> [[NoSuchMethodError:
> api.model.Move.<init>(Lorg/bson/types/ObjectId;Ljava/lang/String;Ljava/lang /String;Lorg/bson/types/ObjectId;Lscala/Option;)V]]