Skip to content

Instantly share code, notes, and snippets.

View MattesGroeger's full-sized avatar

Mattes Groeger MattesGroeger

View GitHub Profile
@MattesGroeger
MattesGroeger / Example.swift
Created June 21, 2017 12:24
Generic in-memory cache implementation for Swift 3.0
// create a chache with 60 seconds expiration time
var cache: InMemoryCache = InMemoryCache<LocalUrl>(expirationInSeconds: 60)
// data will either be returned from cache or created via callback and then returned
let data = cache.cachedData {
// do the heavy object creation here
return MyHeavyObject()
}
// invalidate the cache, next call will have to re-create the heavy object
@MattesGroeger
MattesGroeger / applause-template
Last active October 11, 2018 08:13
Use this template for communicating changes to Applause
*Version : x.x.x (Build xxxx)*
*_TITLE OF THIS RELEASE_*
*Description:*
• *Section:* change
• ...
*Bug fixes:*
• Fixed ...
program subcriterion_2_2_2 Count methodology hostCountry projectType
0 ACR_ERTs 1.0 118 {ACR_AfforestationReforestation_Methodology_V1.2} {RWA, SLV, ETH, GIN, PER, TZA, BEN, IDN, MMR, THA, BGD, AGO, LBR, SOM, COM, PNG, MDG, MEX, SDN, VUT, NPL, NAM, TGO, BDI, BRA, SEN, KEN, MWI, COD, NIC, BOL, TCD, NGA, LSO, ZAF, ERI, SLE, ZWB, CMR, ... {CAF, ENF}
1 ACR_ERTs 5.0 462 {ACR_AfforestationReforestation_Methodology_V1.2, ACR_Landfill_Project_Methodology_V2, ACR_IFM_non-Federal_US_Forestlands_V2} {EGY, MMR, SYC, MHL, URY, COM, MEX, YEM, SWZ, USA, SEN, NRU, GBR, CHL, NGA, CAF, ROU, MNG, FSM, LCA, CYP, SYR, ZWE, LUX, ATG, ISR, BIH, FJI, GNB, IRQ, HTI, UGA, LIE, HRV, AUS, ALB, SGP, GIN, ETH, ... {CAF, IFM, ENF, LFGU}
2 CAR_CRTs 5.0 7 {CAR_Landfill_Project_Protocol_V5, CAR_Forest_Project_Protocol_V4, CAR_Mexico_Livestock_Protocol_V2, CAR_US_Livestock_Protocol_V4, CAR_Forest_