This file contains hidden or 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
| package scala | |
| /** | |
| * @author Yaroslav Klymko | |
| */ | |
| object StringOption { | |
| def apply(s: String): Option[String] = s match { | |
| case null | "" => None | |
| case _ => Some(s) | |
| } |
This file contains hidden or 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
| trait BasicAuthentication extends Loggable{ | |
| self: Actor => | |
| protected def authorize(rec: Receive): Receive = if (Props.testMode) rec | |
| else new Receive { | |
| def apply(v: Any) { | |
| v match { | |
| case method: RequestMethod => method.request.getHeader("Authorization") match { | |
| case BasicAuth(login, password) if (authorized_?(login, password)) => |
This file contains hidden or 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
| <build> | |
| <plugins> | |
| <plugin> | |
| <groupId>org.apache.maven.plugins</groupId> | |
| <artifactId>maven-surefire-plugin</artifactId> | |
| <version>2.8</version> | |
| <configuration> | |
| <systemProperties> | |
| <property> | |
| <name>run.mode</name> |
This file contains hidden or 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
| package org.squeryl | |
| import annotations.Transient | |
| import java.lang.reflect.Field | |
| /** | |
| * @author Yaroslav Klymko | |
| */ | |
| trait HasValues { | |
| protected def values: List[Any] |
NewerOlder