Hi Gordon,
Thanks for the feeback.
On 5/25/2011 9:49 AM, Gordon Yorke wrote:
> Hello Linda,
> Some feedback.
>
> Section 3.8.16.2.1 - Entities returned are more likely to be detached than new as they will have a persistent identity.
>
I have added a clarification with regard to primary keys.
> Section 6.3.5 - Should not need method : "<Y> CriteriaUpdate<T> set(Path<Y> attribute, Y value);" as the next method
> also covers this case.
>
> Section 6.3.1 &6.5.7 &6.5.8 - Treat should not operate on the metamodel, it should only operate on the path expressions.
> I know the pattern chosen for the JPQL has the JOIN TREAT operating on the metamodel but the where clause definely
> operates on the path expression. Operating on the path expression is far smoother than operating on both the path
> expression and the metamodel. The treat methods can be reduced to methods that take Path<> and Join<>. The examples
> would then become:
>
> CriteriaQuery<Customer> q = cb.createQuery(Customer.class);
> Root<Customer> customer = q.from(Customer.class);
> Join<Customer, Order> order = customer.join(Customer_.orders);
> q.where(cb.equal(cb.treat(order.get(Order_.product), Book.class).get(Book_.name),"Iliad"));
> q.select(customer);
>
> and
>
> CriteriaQuery<String> q = cb.createQuery(String.class);
> Root<Order> order = q.from(Order.class);
> Join<Order,Book> book = cb.treat(order.join(Order_.product), Book.class);
> q.select(book.get(Book_.isbn));
>
I have made these changes. I have flagged as an open issue whether or not we need "treatJoin"
methods that carry across the typing for use with the string-based API.
> Section 6.5.15 - example 2 should not be using Employee_ metamodel elements for Address attributes. Should also add a
> note to the spec stating that updating across implicit joins is not supported.
>
Fixed.
Thanks again,
-Linda
> --Gordon
>
> Linda DeMichiel wrote:
>> Greetings,
>>
>> I've just uploaded a draft of the JPA 2.1 specification that reflects
>> our progress to date.
>>
>> You can retrieve it from the Downloads section of the project website,
>> http://java.net/projects/jpa-spec/downloads.
>>
>> Please review carefully and post any feedback, comments, corrections, etc.
>> to the list.
>>
>> There are a number of open issues which I've flagged in the draft
>> and in its Appendix B. I'd like to get feedback on the draft first,
>> and then try close these out in a concall.
>>
>> The changebars in the draft reflect a superset of all technical changes.
>> (Some sporadic changebars are due purely to updates to the formatting--but
>> these should be fairly easy to identify.)
>>
>> thanks,
>>
>> -Linda