Did you find this thread
http://www.mail-archive.com/[EMAIL PROTECTED]/msg06219.html in the
archive. It solved all my proxy problems thus far.

-Ken

> -----Original Message-----
> From: Glauber Andrade [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, November 26, 2003 10:28 AM
> To: [EMAIL PROTECTED]
> Subject: proxy ClassCastException
> Importance: High
>
>
> I am trying to use proxy (my first time) and I am getting a
> ClassCastException.
> What do I need to do? How do I cast ?
> Thanks,
>
> Glauber
>
> ////////////////////////////////////
>       Query q = QueryFactory.newQuery(NotaRecibo.class, crit);
>       Collection c = broker.getCollectionByQuery(q);
>       Iterator iter = c.iterator();
>       Object[][] data = new Object[c.size()][17];
>       NotaRecibo nota = null;
>       while (iter.hasNext()) {
>          nota = (NotaRecibo) iter.next();    ===> ClassCastException
>          ...
> ////////////////////////////////////
>    <class-descriptor
>       class="com......data.NotaRecibo"
>      proxy="dynamic"
>       table="notasrecibos"
>    >
> ...
> ////////////////////////////////////
> public interface InterfaceNotaRecibo {
> ...
> ////////////////////////////////////
> public class NotaRecibo implements InterfaceNotaRecibo {
> ...
> ////////////////////////////////////
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>



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

Reply via email to