class MarketTenor implements Comparable<MarketTenor>, Serializable {

  public static MarketTenor ofSpot(Tenor tenor) {
    if (tenor.getPeriod().equals(Period.ofDays(1))) {
      return MarketTenor.SN;
    }
    if (tenor.getPeriod().equals(Period.ofDays(7))) {
      return MarketTenor.SW;
    }
    return new MarketTenor(tenor.toString(), tenor, MARKET_CONVENTION_LAG);
  }

  private  MarketTenor(String code, Tenor tenor, int spotLagIndicator);

}