cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bruno René Santos <>
Subject ClassCastException: PersistentObjectSet as PersistentObject
Date Mon, 26 Sep 2011 21:41:48 GMT
Hello all,

I was trying to use java.util.Set as the base of my relationships as my GUI
framework uses it a lot. The problem was that on this piece of code:

// TODO: Andrus 1/31/2006 - IncrementalFaultList is not properly
                        // transferred between contexts....

                        List childObjects = new ArrayList(objects.size());
                        Iterator it = objects.iterator();
                        while (it.hasNext()) {
                            Persistent object = (Persistent);

                                    .getObjectId(), object));

which is on, the Persistent object =
(Persistent); returns a Set instead of a single item. When I
change the relationship on the Modeler to use Lists everything returns to

Is this a bug?

Bruno Santos

Bruno René Santos | | Gestor de Projectos | Analista |
Programador | Investigador

Holos - Soluções Avançadas em Tecnologias de Informação S.A.
Parque de Ciência e Tecnologia de Almada/Setúbal . Edifício Madan Parque
Rua dos Inventores . Quinta da Torre . 2825 - 182 Caparica . Portugal
Phone: +351 210 438 686 . Fax: +351 210 438 687 . Web:

This email and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
If you are not the intended recipient or the person responsible for
delivering the email to the intended recipient, be advised that you have
received this email in error and that any use, dissemination, forwarding,
printing, or copying of this email is strictly prohibited. If you have
received this email in error please notify Bruno René Santos by telephone on
+351 210 438 686

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message