Changes for page WebObjects and Squeryl
Last modified by Ravi Mendis on 2011/04/01 11:14
From version 68.1
edited by Ravi Mendis
on 2011/03/31 23:35
on 2011/03/31 23:35
Change comment:
There is no comment for this version
To version 66.1
edited by Ravi Mendis
on 2011/03/25 05:00
on 2011/03/25 05:00
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -11,7 +11,7 @@ 11 11 * Type Safety 12 12 ** Better suited for database/business "logic". 13 13 E.g: Exploits the compiler and IDE to catch exceptions at compile time rather than at run-time. 14 -* Uses Scala Collections14 +* Uses Scala collection classes 15 15 16 16 = Migrating EOF -> Squeryl = 17 17 ... ... @@ -54,26 +54,6 @@ 54 54 55 55 {{code}} 56 56 57 -def activeFiles = files.filter(_.active == true)57 +def activeFiles = files.filter(_.active == 1) 58 58 59 59 {{/code}} 60 - 61 -===== 2. Iteration ===== 62 - 63 -Functional language iteration that's become increasingly popular can be used: 64 - 65 -{{code}} 66 - 67 -activeFiles.foreach(f => { 68 - ... 69 -}) 70 - 71 -{{/code}} 72 - 73 -===== 3. For-Comprehensions ===== 74 - 75 -{{code}} 76 - 77 -def activeFiles = for (file <- files if file.active == true) yield f 78 - 79 -{{/code}}