mirko dijo:
> Antonio Gallardo wrote:
>>>Yes, I know I can pass collection of objects. But I'm afraid of memory
>>>usage if the collections are huge. :) But I think I'll do as you said,
>>>in the future maybe a iterator will be able to be passed :)
>>
>>
>> This is a good question, but as usually we can "paginate" the output,
>> then
>> there cannot be to big collections at all. Also OJB can use some lazy
>> load
>> that will load objects only if they are requested. There are also
>> proxies
>> for beans, etc. See the features of OJB.
>
> Hmm, in the OJB Faq there is:
> Q:
> How to page and sort?
>
> A:
> ..
> There is no paging support in OJB. OJB is concerned with
> Object/Relational mapping and not with application specific presentation
> details like presenting a scrollable page of items.
> ..
>
> But using the techniques you mentioned "paginating" is not necessary to
> restrict collections size.

As mentioned before you can use lazy loads to do this.
>
> I looked on the OJB Block (Cocoon 2.1.3) and I noticed that there is
> only OJB - JDO components, can I use ODMG or PB API?

Yes.

>
> Can I safely update OJB Block from CVS to my Cocoon 2.1.3 installation?

Yes.
>
> I have also question about OJB Block samples. I think the flow
> (employee.js) contains to much code. In my opinion there should be only
> one Employee class used in flow and EmployeeImpl should be hidden from
> the flow view. In every flow function I will need to get PM factory
> component, instantiate my bean, instantiate my persistent bean, call OJB
> method passing bean and factory...

I don't remember too much about the samples. At that time the OJB
integration with Cocoon does not exist at all. Some people talked about
that but nothing more. Also woody and flow was very new too. The samples
just showed the idea is viable. I am planning to refactor the samples
after I end the current work and write some better samples.

I think it is a good idea to have 2 classes from the SoC point of view.
The employee.class are the data (a bean). The employeeImpl.class is the
model in the MVC paradigm.

For more info about that, please review the devel archives I posted some
mails while trying to do the all thing work.

If you prefer other approach you are free to do it as you consider
convenient. This was just a sample. :-D

>
> But I see problem to do it in my way: you need to get PM factory in the
> flow and pass it in the persistence objects method calls.

Yes. This is the way we found.

> Is the way to use OJB in Cocoon presented in the sample OK? And are you
> using that way in your other Cocoon/OJB projects?

Yes. 2 project are using more or less the same approach.

Best Regards,

Antonio Gallardo

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to