Skip to content

Instantly share code, notes, and snippets.

@jeffwf
Last active December 29, 2015 00:09
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 jeffwf/7584136 to your computer and use it in GitHub Desktop.
Save jeffwf/7584136 to your computer and use it in GitHub Desktop.
public final class EtfVehicle extends InvestmentVehicle
{
public static final EtfVehicle E01_EMERGING = new EtfVehicle(1, "E01_EMERGING", AssetClass.INTL_EMERGING, /*VWO*/8901L);
public static final EtfVehicle E02_DEVELOPED = new EtfVehicle(2, "E02_DEVELOPED", AssetClass.INTL_DEVELOPED, /*VEA*/5381L);
public static final EtfVehicle E03_REAL_ESTATE = new EtfVehicle(3, "E03_REAL_ESTATE", AssetClass.REAL_ESTATE, /*VNQ*/4229L);
...
private final InstrumentId instrumentId;
private EtfVehicle(int number, String identity, AssetClass assetClass, InstrumentId instrumentId) {...}
// boilerplate POJO implementation
public static List<EtfVehicle> getAll() {...}
public static Option<EtfVehicle> fromNumber(int number) {...}
public static Option<EtfVehicle> fromName(String name) {...}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment