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 ys | |
import groovy.util.logging.Slf4j | |
import org.springframework.beans.factory.annotation.Autowired | |
import org.springframework.context.annotation.Bean | |
import org.springframework.context.annotation.Configuration | |
import org.springframework.context.annotation.PropertySource | |
import org.springframework.test.context.ContextConfiguration | |
import org.springframework.transaction.UnexpectedRollbackException | |
import org.springframework.transaction.annotation.Propagation |
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
import java.util.zip.* | |
/** | |
* Makes it easier to unzip files by adding extraction methods to the entries themselves and providing Closure-based methods for finding specific entries. | |
* | |
* For example, to extract all XML files to a certain directory: | |
* <code> | |
* new Unzipper(zip).findAllEntries { it.name.endsWith(".xml") }.each { it.extractTo(someDir) } | |
* </code> | |
*/ |
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
// Simple groovy script to compress / decompress Strings | |
import java.util.zip.GZIPInputStream | |
import java.util.zip.GZIPOutputStream | |
def zip(String s){ | |
def targetStream = new ByteArrayOutputStream() | |
def zipStream = new GZIPOutputStream(targetStream) | |
zipStream.write(s.getBytes('UTF-8')) | |
zipStream.close() | |
def zippedBytes = targetStream.toByteArray() |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<beans xmlns="http://www.springframework.org/schema/beans" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:util="http://www.springframework.org/schema/util" | |
xmlns:p="http://www.springframework.org/schema/p" | |
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd | |
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-3.0.xsd"> | |
<bean | |
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> | |
<property name="location"> |
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
/* | |
* See LICENSE for licensing and NOTICE for copyright. | |
*/ | |
package edu.vt.middleware.app; | |
import java.io.File; | |
import java.security.*; | |
import java.util.ArrayList; | |
import java.util.List; | |
import java.util.function.Predicate; |
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
A tout moment, pour savoir où on en est en local | |
git status | |
Récupérer un projet dans un nouveau dossier local et se positionner dans la branche develop | |
git clone ssh://[adresse_ip]:[port]/[path] | |
git checkout develop | |
git pull origin develop | |
En récurrent, pousser une modification locale vers le repository distant | |
git add ./chemin_vers_mon_fichier {ligne à passer pour chaque fichier à commiter} |
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
[user] | |
name = Rabhi Houcem | |
email = rabhi.houcem@gmail.com | |
[core] | |
autocrlf = input | |
excludesfile = ~/.gitignore-global | |
editor = vim | |
[color] | |
ui = true | |
[alias] |
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
"frxab";"50.102";"1.82425";"Abbeville" | |
"frmlw";"49.0037";"2.57089";"Aéroport CDG 2 TGV" | |
"frxag";"43.3174";"3.46613";"Agde" | |
"fragf";"44.2084";"0.620312";"Agen" | |
"frais";"49.9284";"2.20058";"Ailly Sur Somme" | |
"frqai";"45.5543";"6.6489";"Aime la Plagne" | |
"frqxb";"43.5232";"5.44412";"Aix en Provence" | |
"fraie";"43.4553";"5.31723";"Aix en Provence TGV" | |
"frxai";"45.6879";"5.90924";"Aix les Bains le Revard" | |
"frale";"45.7861";"5.98222";"Albens" |
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
open class Parent { | |
private val a = println("Parent.a") | |
constructor(arg: Unit=println("Parent primary constructor default argument")) { | |
println("Parent primary constructor") | |
} | |
init { | |
println("Parent.init") | |
} |
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
import com.fasterxml.jackson.databind.JsonNode; | |
import com.fasterxml.jackson.databind.ObjectMapper; | |
import org.springframework.core.io.buffer.DataBuffer; | |
import org.springframework.core.io.buffer.DataBufferUtils; | |
import org.springframework.core.io.buffer.DefaultDataBufferFactory; | |
import reactor.core.publisher.Flux; | |
import reactor.core.publisher.Mono; | |
import java.io.BufferedWriter; | |
import java.io.FileWriter; |
OlderNewer