[flexcoders] Re: Pagination using Flex Data Management Service

2007-03-09 Thread sid_flex
Jeff,

Thanks for your reply.

I assume that by paging from client to server you mean that the client
gets results fragment by fragment, based on the visible data. For
example, if my datagrid shows 8 rows and my paging is set to 5 rows, the
datagrid will only get the first two packages of data. In this example
10 rows. When scrolling down by one row at a time, the client retrieves
the next package as soon as we reach the 11th row. Correct?

Given the current FSD implementation and your suggestion to implement
server-side pagination using a fill parameter, the implementation using
FDS will probably the same as the implementation you would code for
RemoteObjects. Why not use RemoteObjects instaed of FDS?

Best regards,

Sieto



--- In flexcoders@yahoogroups.com, Jeff Vroom [EMAIL PROTECTED] wrote:

 When you have one large ArrayCollection on the client which you want
to
 load a page at a time, FDS currently only supports paging from client
to
 server.   The fill method currently must return all items from the
 database.  This is something we'd like to address in a future release.



 To implement a page at a time ArrayCollection, you can simply pass in
 the page index as a fill parameter and then code it just to return the
 number of items asked for.  One trick folks sometimes use is to return
 one more item than they display so that you can tell when you have hit
 the end of the list.



 Jeff



 

 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]
On
 Behalf Of sid_flex
 Sent: Thursday, March 08, 2007 9:51 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Pagination using Flex Data Management Service



 Hello,

 Pagination using Flex FDS should be simple. Nevertheless i'ts hard
 finding examples of succesfull implementations using pagination with
 Flex Data Management Service.

 Configuring the destination is eaasy. For example:
 destination id=product
 adapter ref=java-dao /

 properties
 sourceflex.testdrive.store.ProductAssembler/source
 scopeapplication/scope

 metadata
 identity property=productId! /
 /metadata

 network
 session-timeout11/session-timeout
 paging enabled=true pageSize=5 /
 throttle-inbound policy=ERROR max-frequency=500/
 throttle-outbound policy=REPLACE
 max-frequency=500/
 /network
 /properties
  ! nbsp;  /destination

 But what's the ! intended way to navigate through the pages returned?
 (Or is pagination only intended for optimised network trafic and will
 the result of ds.fill() always return the full result of the fill()
 method?)

 I'm looking for the best next page, previous page, last page,
 first page solution using FDS.

 Thanks in advance for your reply.

 Best regards,

 Sieto





RE: [flexcoders] Re: Pagination using Flex Data Management Service

2007-03-09 Thread Jeff Vroom
Yes, when you have one large ArrayCollection the paging from client to server 
works the way you describe.
 
When you are only storing one page on the client at a time (i.e. in a page 
sized ArrayCollection), remote object or FDMS work the same if your app is 
read-only.  You'd probably only use FDMS if you want to take advantage of the 
other features it offers (e.g. automatic change detection on the client, 
associations with lazy loading, etc.)
 
Jeff

 


From: flexcoders@yahoogroups.com on behalf of sid_flex
Sent: Fri 3/9/2007 7:07 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Pagination using Flex Data Management Service



Jeff,

Thanks for your reply.

I assume that by paging from client to server you mean that the client
gets results fragment by fragment, based on the visible data. For
example, if my datagrid shows 8 rows and my paging is set to 5 rows, the
datagrid will only get the first two packages of data. In this example
10 rows. When scrolling down by one row at a time, the client retrieves
the next package as soon as we reach the 11th row. Correct?

Given the current FSD implementation and your suggestion to implement
server-side pagination using a fill parameter, the implementation using
FDS will probably the same as the implementation you would code for
RemoteObjects. Why not use RemoteObjects instaed of FDS?

Best regards,

Sieto

--- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Jeff 
Vroom [EMAIL PROTECTED] wrote:

 When you have one large ArrayCollection on the client which you want
to
 load a page at a time, FDS currently only supports paging from client
to
 server. The fill method currently must return all items from the
 database. This is something we'd like to address in a future release.



 To implement a page at a time ArrayCollection, you can simply pass in
 the page index as a fill parameter and then code it just to return the
 number of items asked for. One trick folks sometimes use is to return
 one more item than they display so that you can tell when you have hit
 the end of the list.



 Jeff



 

 From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com  
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com ]
On
 Behalf Of sid_flex
 Sent: Thursday, March 08, 2007 9:51 AM
 To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
 Subject: [flexcoders] Pagination using Flex Data Management Service



 Hello,

 Pagination using Flex FDS should be simple. Nevertheless i'ts hard
 finding examples of succesfull implementations using pagination with
 Flex Data Management Service.

 Configuring the destination is eaasy. For example:
 destination id=product
 adapter ref=java-dao /

 properties
 sourceflex.testdrive.store.ProductAssembler/source
 scopeapplication/scope

 metadata
 identity property=productId! /
 /metadata

 network
 session-timeout11/session-timeout
 paging enabled=true pageSize=5 /
 throttle-inbound policy=ERROR max-frequency=500/
 throttle-outbound policy=REPLACE
 max-frequency=500/
 /network
 /properties
 ! nbsp; /destination

 But what's the ! intended way to navigate through the pages returned?
 (Or is pagination only intended for optimised network trafic and will
 the result of ds.fill() always return the full result of the fill()
 method?)

 I'm looking for the best next page, previous page, last page,
 first page solution using FDS.

 Thanks in advance for your reply.

 Best regards,

 Sieto




 
winmail.dat