public static <T> NullableCoder<T> of(Coder<T> valueCoder) {
    if (valueCoder instanceof NullableCoder) {
      return (NullableCoder<T>) valueCoder;
    }
    return new NullableCoder<>(valueCoder);
  }
@Test
  public void testNestedNullableCoder() {
    NullableCoder<Double> coder = NullableCoder.of(DoubleCoder.of());
    assertThat(NullableCoder.of(coder), theInstance(coder));
  }