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
public static Date getDateDDMMYYYY(final String dateString) { | |
final SimpleDateFormat formatter = new SimpleDateFormat("dd/MM/yyyy"); | |
try { | |
return formatter.parse(dateString, new ParsePosition(0)); | |
} catch (NullPointerException e) { | |
return null; | |
} | |
} |
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
Convention conv = null; | |
try { | |
conv = | |
conventionService.rechercherParId(Long.valueOf((String) request.getSession().getAttribute( | |
"conventionId"))); | |
} catch (NullPointerException e) { | |
log.error("Une erreur est survenu, l'id de la convention n'est pas en session !", e); | |
} |
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
var WS = window['MozWebSocket'] ? MozWebSocket : WebSocket | |
var mapSocket = new WS("@routes.Application.mapsocket().webSocketURL(request)"); | |
mapSocket.onmessage = function(event) { | |
var data = JSON.parse(event.data); | |
marker = moveMaker(map, marker, data.longitude, data.latitude); | |
} |
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
public class MapAnime extends UntypedActor { | |
static ActorRef actor = Akka.system().actorOf(new Props(MapAnime.class)); | |
Map<String, WebSocket.Out<JsonNode>> registrered = new HashMap<String, WebSocket.Out<JsonNode>>(); | |
/** | |
* | |
* @param id | |
* @param in |
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 patch; | |
import static play.libs.F.None; | |
import static play.libs.F.Some; | |
import java.util.ArrayList; | |
import java.util.HashMap; | |
import java.util.List; | |
import java.util.Map; |
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.ekito.toulousejugcontest; | |
import java.io.BufferedReader; | |
import java.io.InputStreamReader; | |
import java.io.UnsupportedEncodingException; | |
import java.security.MessageDigest; | |
import java.security.NoSuchAlgorithmException; | |
import java.util.regex.Matcher; | |
import java.util.regex.Pattern; |
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 Result whenIGenerateABadge(final int idInscription) { | |
try { | |
start(fakeApplicationOverloaded()); | |
Map<String, String> map = new HashMap<String, String>(); | |
map.put("nameSelected_" + idInscription, "on"); | |
FakeRequest fakeRequest = fakeRequest(POST, "/admin/badge").withFormUrlEncodedBody(map); | |
return routeAndCall(fakeRequest); | |
} finally { |
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
var MARK_UNREAD = false; | |
var ADD_UNSNOOZED_LABEL = false; | |
function getLabelName(i) { | |
return "[Snooze]/Snooze " + i + " days"; | |
} | |
function setup() { | |
// Create the labels we’ll need for snoozing | |
GmailApp.createLabel("[Snooze]"); |
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
class Dashing.Teammood extends Dashing.Widget |