Hi, I would like to ask two questions, any help will be appreciated. 

1. Can I use generic type in Property? 
DateTimeInterval1 fails while DateTimeInterval2 is ok in the following snippet.
===========SNIPPET 1===========
public interface ITimeInterval<T> {
        Property<T> start();
        Property<T> end();
}
public interface DateTimeInterval1 extends ITimeInterval<LocalDate>, 
ValueComposite { // fail
}


public interface DateTimeInterval2 extends ValueComposite { // ok
        Property<LocalDate> start();
        Property<LocalDate> end();
}
===========SNIPPET 1===========


2. Can I use ValueComposite as map keys?
map1 fails while map2 is ok in the following snippet.
===========SNIPPET 2===========
public interface TestEntity extends EntityComposite {
        Property<Map<DateTimeInterval2, String>> map1();        // fail
        Property<Map<String, DateTimeInterval2>> map2();        // ok
}
===========SNIPPET 2===========

Reply via email to