[jsword-devel] jsword-devel Digest, Vol 47, Issue 11
Yiguang Hu
yighu at yahoo.com
Sun Apr 20 05:01:40 MST 2008
DM,
Yes. It makes perfect sense to refactor the
getOSISString method with one more parameter like
startCount instead of making another one.
I think it is useful to make "total" available for
client. So that user may know the significance of the
key word from the numerical statistics.
Regarding paging, looks like we do need some way such
as cache to avoiding repeating the process of
searching/count total etc for the same
key/locale/book, when we start to take into account of
performance.
Thanks
Yiguang
--- DM Smith <dmsmith555 at yahoo.com> wrote:
> Yiguang,
>
> This is a good idea. But, I'd rather replace the
> current call with
> your suggestion. Right now it is not set in stone.
>
> Question: How would you propose the handling of
> "total"?
>
> Is it only known on the server side and when the
> call can return no
> more then it returns an empty string? This would
> lead to having an
> active next button when there is no next.
>
> Or should it be available on the client?
>
> Should we add something like the following that will
> get the "total"?
>
>
> In Him,
> DM
>
> On Apr 19, 2008, at 10:57 PM, Yiguang Hu wrote:
>
> > DM,
> >
> > I'd like to propose another api in DwrBridge.java
> > similar to getOSISString:
> >
> > public String getOSISString(String bookInitials,
> > String reference, int maxKeyCount)
> >
> > The new api better be called something other than
> > getOSISString such as
> >
> > public String getOSISStringAny(String
> bookInitials,
> > String reference, int startCount, int maxKeyCount)
> >
> > for easy use with DWR.
> >
> > This api need to deal with the bounday condition
> such
> > as the following scenario:
> > if (startCount<0){
> > startCount=0;
> > }
> > if (total<startCount+maxKeyCount){
> > startCount=total-maxKeyCount;
> > }
> >
> > With this api, we could create paging effect with
> > buttons"<<" and ">>" etc to navigate forward and
> > backward through all the search results instead of
> the
> > first maxKeyCount results.
> >
> > Thanks
> > Yiguang
> >
____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
More information about the jsword-devel
mailing list