Re: RequestFactory can not support embedded class and owned 1-to-many in one Entity

2011-01-26 Thread QkQk
Hi David,
 Yes, i am trying request like
 "findUrlMd5Req.with("pTagSet", "pTagOwnedSet").fire", where pTagSet
and pTagOwnedSet are defined in an entity class.
"
@Persistent (defaultFetchGroup="true")
  @Embedded
  private PTag pTagSet;
..

@Persistent(mappedBy="bookPTag", defaultFetchGroup="true")
  @Element(dependent = "true")
  private List pTagOwnedSet= new ArrayList();

PTagProxy is defined as
@ProxyFor(value=PTag.class)
public interface PTagProxy extends ValueProxy {
..

PTagOwnedProxy  is defined as
@ProxyFor(value=PTagOwned.class, locator=locator-for-pTagOwned)
public interface PTagOwnedProxy extends EntityProxy {
"

As I said, if containing only embedded class or owned 1-to-many class,
it works. Combined two type of classes above will return only owned 1-
to-many proxy.

Is it a limitation on the implementation? How to debug in this case?
Thanks,

On Jan 26, 10:28 pm, David Chandler  wrote:
> Are you putting both property names in .with(), as in
> .with("embeddedProperty","ownedOneToManyProperty")?
>
> Both are required.
>
> /dmc
>
>
>
>
>
>
>
>
>
> On Wed, Jan 26, 2011 at 9:23 AM, QkQk  wrote:
> > Hi,
> >  I have one question about RF proxy support. I am using gwt2.1.1 and
> > jdo in appEngine 1.4.0. I found out  if a Entity class contains both
> > owned 1-to-many subclass and embedded class. Then, RF only return
> > owned 1-to-many proxy. If it contains only embedded class or owned
> > class, then RF works fine.
>
> >  Is it a limitation of current release of RF or any other reason?
> > Thanks,
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" group.
> > To post to this group, send email to google-web-toolkit@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-web-toolkit+unsubscr...@googlegroups.com > cr...@googlegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/google-web-toolkit?hl=en.
>
> --
> David Chandler
> Developer Programs Engineer, Google Web Toolkit
> w:http://code.google.com/
> b:http://googlewebtoolkit.blogspot.com/
> t: @googledevtools

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



RequestFactory can not support embedded class and owned 1-to-many in one Entity

2011-01-26 Thread QkQk
Hi,
 I have one question about RF proxy support. I am using gwt2.1.1 and
jdo in appEngine 1.4.0. I found out  if a Entity class contains both
owned 1-to-many subclass and embedded class. Then, RF only return
owned 1-to-many proxy. If it contains only embedded class or owned
class, then RF works fine.

 Is it a limitation of current release of RF or any other reason?
Thanks,

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: How to return nested 1-to-many EntityProxy

2011-01-24 Thread QkQk
Hi Y2i,
 Sorry to make you mis-understand.
 I am query PTagLinks, which contains list of PTagOwned class, which
contains list of RIdxWord class.
As I said, i have tried multiple combinations of request 'with'. Even
i changed  to "Req.with("pTagOwnedSet.grandChildren").fire". I can
still see PTagOwned list. RIdxwordProxy list in PTagOwnedProxy will be
null.


On Jan 25, 9:38 am, Y2i  wrote:
> Assuming you are querying PTasLinks, does RIdxWord also have  pTagOwnedSet
> array?
>
> I believe in the post Thomas meant something like 
> Req.with("pTagOwnedSet.grandChildren.pTagOwnedSet").fire().
>  That's what I would try too.  
> Because with("pTagOwnedSet.grandChildren").with("pTagOwnedSet") must be the
> same as with("pTagOwnedSet.grandChildren")
>
> But honestly I've never done with() for more than 1 level, and only for 1:1
> relationships.  I prefer querying sets little by little, and only when a
> user needs the data.

 In the case of , how can you "query set little by little" in 2nd
level? please suggest. Thanks,

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: RequestFactory does not preserve owned 1-to-many list order

2011-01-24 Thread QkQk
Hi David,
 Thanks for the reply. What i want is support for 'collection' of
embedded classes. I am using gwt2.1.1 + appengine sdk 1.4.0. What i
found is jdo implementation in appEngine seems not support this
feature. I saw your sample code of 'listwidget' by JPA. it seems ok.
Is it correct?

On Jan 22, 12:08 am, David Chandler  wrote:
> As of 2.1.1, RF now supports @Embedded types using ValueProxy on the client.
> Docs are lagging, will update shortly.
>
> /dmc
>
> On Fri, Jan 21, 2011 at 9:18 AM, David Sowerby 
> wrote:
>
>
>
>
>
>
>
>
>
> > Hi qkQk
>
> > I don't think @Embedded is supported by RequestFactory.  See
> >http://code.google.com/webtoolkit/doc/trunk/DevGuideRequestFactory.html
> > under Entity Relationships
>
> > On Jan 20, 2:42 pm, QkQk  wrote:
> > > Hi Thomas,
> > >  you are correct in list order. It's my mistake.
> > >  For the second question, i have tried
> > > @Persistent(embeddedElement="true") on collection of embedded
> > > class,but does not work on appEngine sdk 1.4.0. Can you provide a
> > > working example? Is it possible to have embedded class or collection
> > > of embedded class on a child entity of owned 1-to-many relationship.
>
> > > Another question confused me is in RequestFactory doc says "It is not
> > > necessary to represent every property and method from the server-side
> > > entity in the EntityProxy, only getters and setters for properties
> > > that should be exposed to the client." Does it mean RF will smart
> > > download only properties specified in EntityProxy or it will download
> > > whole property set no matter what.
> > > Thanks,
> > > On Jan 19, 11:58 pm, Thomas Broyer  wrote:
>
> > > > On Wednesday, January 19, 2011 4:42:35 AM UTC+1, QkQk wrote:
>
> > > > > Hi,
> > > > >  I am using gwt2.1.1's requestfactory on owned 1-to-many relationship
> > > > > in jdo. I found the ordering of child list is missing as passed back
> > > > > to entityproxy.
>
> > > > If you declared your property as a List (and not a
> > > > Set > the
> > > > case where the ordering was messed up by RequestFactory).
>
> > > > > Another question is jdo seems not support collection
> > > > > of embedded class.
>
> > > > It seems like it actually does:
> >http://www.datanucleus.org/products/accessplatform/jdo/orm/embedded.h...
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" group.
> > To post to this group, send email to google-web-toolkit@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-web-toolkit+unsubscr...@googlegroups.com > cr...@googlegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/google-web-toolkit?hl=en.
>
> --
> David Chandler
> Developer Programs Engineer, Google Web Toolkit
> w:http://code.google.com/
> b:http://googlewebtoolkit.blogspot.com/
> t: @googledevtools

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: How to return nested 1-to-many EntityProxy

2011-01-24 Thread QkQk
Hi Y2i,
 I have tried suggestion from Thomas Broyer with various combinations
on 'with' clause but does not work. From debug inf, i can see 'PTag'
class been retrieved but not 'RIdxWord'. my sample code is the
following:
"
class PTasLinks {
..
/* 1st layer owned 1-to-many relationship */
 @Persistent(mappedBy="bookPTag", defaultFetchGroup="true")
  @Element(dependent = "true")
  private List pTagOwnedSet= new ArrayList();
..
}

class PTagOwned {
..
/* 2nd layer  realtionship */
   @Persistent(mappedBy = "bookPTagOwned", defaultFetchGroup="true")
   @Element(dependent = "true")
   private List grandChildren =
   new ArrayList();
..
}

Req.with("pTagOwnedSet.grandChildren").with("pTagOwnedSet").fire
"
I wonder if layered access cannot be complete in one request. Then, it
will need another request to complete. Is it necessary? Please help to
clarify. Thanks

On Jan 22, 1:29 am, Y2i  wrote:
> with("child").with("child") will not help.  You probably need something like
> with("child.child").
> Also, this thread may 
> helphttps://groups.google.com/forum/#!topic/google-web-toolkit/sCW3JQ5Axh...

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



How to return nested 1-to-many EntityProxy

2011-01-21 Thread QkQk
Hi,
  I have made layered 1-to-many relationship, says, parent-children-
grandchildren.  It works fine to access grandchildren from children in
server. But passing back as 'null' of grandchildren  thru
requestfactory. I am using request with( propertyRefs). Even multiple
with(propertyRef1).with(propertyRef2) does not work, where
propertyRef1 for child's and grandchild property. Please someone
kindly help!

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: RequestFactory does not preserve owned 1-to-many list order

2011-01-20 Thread QkQk

Hi Thomas,
 you are correct in list order. It's my mistake.
 For the second question, i have tried
@Persistent(embeddedElement="true") on collection of embedded
class,but does not work on appEngine sdk 1.4.0. Can you provide a
working example? Is it possible to have embedded class or collection
of embedded class on a child entity of owned 1-to-many relationship.

Another question confused me is in RequestFactory doc says "It is not
necessary to represent every property and method from the server-side
entity in the EntityProxy, only getters and setters for properties
that should be exposed to the client." Does it mean RF will smart
download only properties specified in EntityProxy or it will download
whole property set no matter what.
Thanks,
On Jan 19, 11:58 pm, Thomas Broyer  wrote:
> On Wednesday, January 19, 2011 4:42:35 AM UTC+1, QkQk wrote:
>
> > Hi,
> >  I am using gwt2.1.1's requestfactory on owned 1-to-many relationship
> > in jdo. I found the ordering of child list is missing as passed back
> > to entityproxy.
>
> If you declared your property as a List (and not a
> Set case where the ordering was messed up by RequestFactory).
>
> > Another question is jdo seems not support collection
> > of embedded class.
>
> It seems like it actually 
> does:http://www.datanucleus.org/products/accessplatform/jdo/orm/embedded.h...

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



RequestFactory does not preserve owned 1-to-many list order

2011-01-18 Thread QkQk
Hi,
 I am using gwt2.1.1's requestfactory on owned 1-to-many relationship
in jdo. I found the ordering of child list is missing as passed back
to entityproxy.  Another question is jdo seems not support collection
of embedded class. Even RF enables embedded class in new release. This
makes coding difficult.
 Any suggestion.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.