Last active
August 29, 2015 14:03
-
-
Save seratch/99471d225c35437aa5f8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ sbt console | |
<console>:35: error: erroneous or inaccessible type | |
def apply(g: ResultName[Group])(rs: WrappedResultSet): Group = Group(rs.long(g.id), rs.get(g.name)) | |
^ | |
[success] Total time: 108 s, completed 2014/07/02 12:51:30 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/sandbox/build.sbt b/sandbox/build.sbt | |
index d626a7c..876d705 100644 | |
--- a/sandbox/build.sbt | |
+++ b/sandbox/build.sbt | |
@@ -38,12 +38,13 @@ object Company extends SQLSyntaxSupport[Company] { | |
def apply(c: SyntaxProvider[Company])(rs: WrappedResultSet): Company = apply(c.resultName)(rs) | |
def apply(c: ResultName[Company])(rs: WrappedResultSet): Company = Company(rs.long(c.id), rs.stringOpt(c.name)) | |
} | |
-case class Group(id: Long, name: Option[String], members: Seq[User] = Nil) | |
+case class Name(value: String) | |
+case class Group(id: Long, name: Option[Name], members: Seq[User] = Nil) | |
object Group extends SQLSyntaxSupport[Group] { | |
override val tableName = "groups" | |
override val columns = Seq("id", "name") | |
def apply(g: SyntaxProvider[Group])(rs: WrappedResultSet): Group = apply(g.resultName)(rs) | |
- def apply(g: ResultName[Group])(rs: WrappedResultSet): Group = Group(rs.long(g.id), rs.stringOpt(g.name)) | |
+ def apply(g: ResultName[Group])(rs: WrappedResultSet): Group = Group(rs.long(g.id), rs.get(g.name)) | |
} | |
case class GroupMember(groupId: Long, userId: Long) | |
object GroupMember extends SQLSyntaxSupport[GroupMember] { |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment