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 main | |
| import ( | |
| "flag" | |
| "fmt" | |
| "log" | |
| "net/http" | |
| "sync" | |
| "time" |
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 main | |
| import ( | |
| "flag" | |
| "fmt" | |
| "io" | |
| "io/ioutil" | |
| "log" | |
| "net/http" | |
| "sync" |
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
| module Player exposing (takeTurn) | |
| import Warrior exposing (..) | |
| import Warrior.Direction exposing (..) | |
| import Warrior.History exposing (..) | |
| import Warrior.Map exposing (..) | |
| import Warrior.Map.Tile exposing (..) | |
| takeTurn : Warrior -> Map -> History -> Warrior.Action |
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
| func main() { | |
| m := NewLRUHashMap(3) | |
| m.Put("1", "a") | |
| m.Put("2", "b") | |
| m.Put("3", "c") | |
| m.Put("4", "d") | |
| fmt.Println(m.Get("1")) | |
| fmt.Println(m.Get("4")) | |
| fmt.Println(m.cache) |
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
| private int someFunc() { | |
| try { | |
| throw new NullPointerException(); | |
| } catch (NullPointerException e) { | |
| throw new IllegalArgumentException(); | |
| } finally { | |
| return 1; | |
| } | |
| } |
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
| String networkSSID = "test"; | |
| WifiConfiguration conf = new WifiConfiguration(); | |
| conf.SSID = "\"" + networkSSID + "\""; | |
| conf.allowedKeyManagement.set(WifiConfiguration.KeyMgmt.NONE); | |
| WifiManager wifiManager = (WifiManager)context.getSystemService(Context.WIFI_SERVICE); | |
| wifiManager.addNetwork(conf); |
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
| log4j:ERROR Error initializing log4j: null | |
| java.lang.reflect.MalformedParameterizedTypeException | |
| at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.validateConstructorArguments(ParameterizedTypeImpl.java:60) | |
| at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.<init>(ParameterizedTypeImpl.java:53) | |
| at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.make(ParameterizedTypeImpl.java:95) | |
| at sun.reflect.generics.factory.CoreReflectionFactory.makeParameterizedType(CoreReflectionFactory.java:104) | |
| at sun.reflect.generics.visitor.Reifier.visitClassTypeSignature(Reifier.java:140) |
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
| compile("org.codehaus.groovy.modules.http-builder:http-builder:0.5.0-RC2"){ | |
| excludes "groovy" | |
| } |
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
| dataSource { | |
| pooled = true | |
| driverClassName = "org.postgresql.Driver" | |
| dialect = "com.binarybuffer.postgres.NoWaitPgDialect" | |
| username = "kenota" | |
| 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
| package com.binarybuffer.postgres; | |
| import org.hibernate.LockMode; | |
| import org.hibernate.dialect.PostgreSQLDialect; | |
| /** | |
| * Simple extension to standard {@link PostgreSQLDialect} adding support for | |
| * {@link LockMode#UPGRADE_NOWAIT} lock mode which is achieved using | |
| * "FOR UPDATE NOWAIT" syntax in PostgreSQL | |
| * |
NewerOlder