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
trait ResetDbSpec extends PlaySpec with BeforeAndAfterAll { | |
private def withTestDatabase[T](block: Database => T) = { | |
Databases.withDatabase( | |
driver = "com.mysql.jdbc.Driver", | |
url = "jdbc:mysql://localhost/test", | |
name = "mydatabase", | |
config = Map( | |
"user" -> "test", | |
"password" -> "secret" | |
) |
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
package utils.validation; | |
import java.lang.annotation.Target; | |
import java.lang.annotation.Retention; | |
import java.lang.annotation.ElementType; | |
import java.lang.annotation.RetentionPolicy; | |
import net.sf.oval.configuration.annotation.Constraint; | |
@Retention(RetentionPolicy.RUNTIME) |
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
2017-02-09 13:30:19 | |
Full thread dump Java HotSpot(TM) 64-Bit Server VM (25.121-b13 mixed mode): | |
"AsyncAppender-Worker-ASYNCSTDOUT" #619 daemon prio=5 os_prio=31 tid=0x00007fa1d1d36800 nid=0x19b0b waiting on condition [0x000070001af19000] | |
java.lang.Thread.State: WAITING (parking) | |
at sun.misc.Unsafe.park(Native Method) | |
- parking to wait for <0x00000007749ceab0> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) | |
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) | |
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) |
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
[warn] an unexpected type representation reached the compiler backend while compiling HttpRequestHandler.scala: <error>. If possible, please file a bug on issues.scala-lang.org. | |
scala.MatchError: <error> (of class scala.reflect.internal.Types$ErrorType$) | |
at scala.tools.nsc.backend.jvm.BTypesFromSymbols.typeToBType(BTypesFromSymbols.scala:212) | |
at scala.tools.nsc.backend.jvm.BTypesFromSymbols.$anonfun$methodBTypeFromMethodType$1(BTypesFromSymbols.scala:147) | |
at scala.tools.nsc.backend.jvm.BTypesFromSymbols.methodBTypeFromMethodType(BTypesFromSymbols.scala:147) | |
at scala.tools.nsc.backend.jvm.BTypesFromSymbols.methodBTypeFromSymbol(BTypesFromSymbols.scala:137) | |
at scala.tools.nsc.backend.jvm.BTypesFromSymbols.$anonfun$buildInlineInfoFromClassSymbol$5(BTypesFromSymbols.scala:583) | |
at scala.collection.Iterator$$anon$11.nextCur(Iterator.scala:473) | |
at scala.collection.Iterator$$anon$11.hasNext(Iterator.scala:479) | |
at scala.collection.Iterator.foreach(Iterator.scala:929) |
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
package controllers | |
import play.api.Logger | |
import play.api.mvc._ | |
class Application extends Controller { | |
lazy val logger = Logger(classOf[Application]) | |
def index = Action { implicit request => |
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
// anemica | |
public class Conta { | |
private BigDecimal saldo; | |
private String numero; | |
private String agencia; | |
public Conta(BigDecimal saldo, String numero, String agencia) { | |
this.saldo = saldo; | |
this.numero = numero; |
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
public class Article extends Model { | |
public static List<Article> recents(int limit) { | |
return Article.find("order by publishedAt desc").fetch(limit); | |
} | |
public static Article mostPopular() { | |
return Article.find("order by views desc").first(); | |
} |
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
package utils.jobs; | |
import java.util.List; | |
import play.Play; | |
import play.Logger; | |
import play.jobs.Job; | |
import play.test.Fixtures; | |
import play.jobs.OnApplicationStart; |
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
hein = ["pra que", "por que", "pra quem", "pra quando", "pra onde"] | |
hein.each do |olha_so| | |
hein.shuffle.each do |shhhh| | |
puts "#{olha_so} que tu #{shhhh}?" | |
end | |
end |
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
32768=mp_read(0xc59720, 0xc5eae8, 32768), pos: 4303338950, eof:0 | |
[matroska @ 0x7f74b27d8da0]Unknown entry 0xD0 | |
[matroska @ 0x7f74b27d8da0]Unknown entry 0xBA | |
[matroska @ 0x7f74b27d8da0]Unknown entry 0x6E48 | |
[matroska @ 0x7f74b27d8da0]Unknown entry 0xEF | |
[matroska @ 0x7f74b27d8da0]Unknown entry 0xC2 | |
[matroska @ 0x7f74b27d8da0]Unknown entry 0xE2 | |
mp_seek(0xc59720, 4304149526, 0) | |
seek to 0x1008C1C16 | |
s->pos=1007FC000 newpos=1008C1800 new_bufpos=1008C1C16 buflen=0 |