Skip to content

Instantly share code, notes, and snippets.

@TurpIF
Created March 23, 2017 11:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TurpIF/24d6b279c17e9d35db1bcf2cfcbfa69f to your computer and use it in GitHub Desktop.
Save TurpIF/24d6b279c17e9d35db1bcf2cfcbfa69f to your computer and use it in GitHub Desktop.
Fx sample
allInstruments.stream()
.filter(missingCross)
.flatMap(instrument -> Stream.of(instrument.getCurrency(), instrument.getBaseCurrency()))
.filter(cur -> cur != refCurrency)
.map(cur -> Forex.create(refCurrency, cur))
.filter(not(allInstruments::contains))
.iterator();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment