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
Lock lock = ...; | |
if (lock.tryLock()) { | |
try { | |
// manipulate protected state | |
} finally { | |
lock.unlock(); | |
} | |
} else { | |
// perform alternative actions | |
} |
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
@startuml | |
node { | |
interface "OSGI" as OSGI1 | |
interface "OSGI" as OSGI2 | |
interface "OSGI" as OSGI3 | |
[Service 4 (service composé)] -down-> OSGI1 | |
[Service 3\nGUI] -up- OSGI3 | |
[Service 2\nSGR] -up- OSGI2 | |
[Service 1\nSGS] -up- OSGI1 |
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
@startuml | |
package "couche 1" <<Rect>> { | |
Observable <|-- A | |
} | |
package "couche 2" <<Rect>> { | |
Interface Observable | |
B -> A | |
} | |
@enduml |
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
rgb = imread(fileName); | |
[h, w, ~] = size(rgb); | |
cx = round(w / 2); | |
cy = round(h / 2); | |
imshow(rgb); | |
e = imellipse(gca, [cx - (cy), 0, h h]); | |
wait(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
Testing comment |
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
byte[] octets = "ETS".getBytes("UTF-8"); | |
String base64 = Base64.encodeToString(octets, Base64.URL_SAFE); | |
byte[] octets = Base64.decode(base64, Base64.URL_SAFE); | |
String text = new String(octets, "UTF-8"); |
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
AsyncTask<URL, String, String> httpTask = new AsyncTask<URL, String, String>() { | |
@Override | |
protected String doInBackground(URL... urls) { | |
HttpURLConnection urlConnection = null; | |
StringBuilder sb = new StringBuilder(); | |
try { | |
urlConnection = (HttpURLConnection) urls[0].openConnection(); | |
try (BufferedReader in = new BufferedReader(new InputStreamReader(urlConnection.getInputStream()))) { | |
for (String line = in.readLine(); line != null; line = in.readLine()) { | |
sb.append(line); |
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
@startuml | |
hide footbox | |
Client -> Server: HTTP Get << Long Lived>> | |
activate Client | |
activate Server | |
Server -> Server: serve() | |
activate Server |
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
\documentclass{standalone} | |
\usepackage{pgfplots} | |
\usepackage{tikz} | |
\usepackage{graphicx} | |
\usepackage[caption=false]{subfig} | |
\usepackage[noabbrev]{cleveref} | |
\usepackage{schemabloc} | |
\usepackage{amsmath} | |
\usepackage{amssymb} |
OlderNewer