Skip to content

Instantly share code, notes, and snippets.

View rodgarcialima's full-sized avatar

Rodrigo G Lima rodgarcialima

View GitHub Profile
package rodgarcialima.task;
public class AsyncTaskActivity {
private void download() {
new Task1<Integer, List<Product>>(
top -> { // receive 10 here
Response<List<Product>> response = apiService.getProducts(top).execute();
if (response.isSuccessful()) {
return response.body();
}
@rodgarcialima
rodgarcialima / Makefile
Created February 12, 2019 18:57 — forked from wader/Makefile
libchromaprint.js
# make sure chromaprint source is in $PWD/chromaprint
# after run use $PWD/chromaprint/libchromaprint.min.js
# does not use --bind and set NO_DYNAMIC_EXECUTION to generate code
# that don't use eval
CC = emcc
CXX = em++
CFLAGS = -O2 -DUSE_KISSFFT=1 -Isrc -Ivendor/kissfft
CXXFLAGS = -O2 -std=c++11 -DUSE_KISSFFT=1 -Isrc -Ivendor/kissfft
type CountryCode = keyof typeof Countries;
const countries: Country[] = (Object.keys(Countries) as Array<CountryCode>).map(
(c) => {
const country = Countries[c];
return {
code: c,
name: country.name,
nativeName: country.native,
flag: country.emojiU,