@Test public void testToString() throws Exception { PrimitiveObjectFactory<Boolean> factory = PrimitiveObjectFactory.create(boolean.class); assertThat(factory.toString(true),equalTo(Boolean.TRUE.toString())); assertThat(factory.toString(false),equalTo(Boolean.FALSE.toString())); }
@Override public String toString(final T value) { return value.toString(); }
PrimitiveObjectFactory implements ObjectFactory<T> { @Override public String toString(final T value) { return value.toString(); } }
PrimitiveObjectFactory implements ObjectFactory<T> { @Override public String toString(final T value) { return value.toString(); } private  PrimitiveObjectFactory(final Class<? extends T> valueClass); }
PrimitiveObjectFactory implements ObjectFactory<T> { @Override public String toString(final T value) { return value.toString(); } private  PrimitiveObjectFactory(final Class<? extends T> valueClass); @Override Class<? extends T> targetClass(); @Override @SuppressWarnings("unchecked") T fromString(final String rawValue); @Override String toString(final T value); static PrimitiveObjectFactory<T> create(final Class<? extends T> valueClass); }
PrimitiveObjectFactory implements ObjectFactory<T> { @Override public String toString(final T value) { return value.toString(); } private  PrimitiveObjectFactory(final Class<? extends T> valueClass); @Override Class<? extends T> targetClass(); @Override @SuppressWarnings("unchecked") T fromString(final String rawValue); @Override String toString(final T value); static PrimitiveObjectFactory<T> create(final Class<? extends T> valueClass);  }