Hi all,

I'm just playing around with the AndroMDA 3.0M2 release (by the way
congratulations for that), and I think I found a problem with
StrutsUseCaseForm.vsl.

I have a FrontEndUseCase "Reservierung" (sorry for the german naming...),
and here are the private member of the generated ReservierungForm:

public class ReservierungForm extends ValidatorForm implements Serializable
{
    private java.lang.String anzahlTickets;
    private de.moviepalace.services.tickets.ReservierungVO reservierung;
    private java.lang.String vorstellungOid;
    private Object[] vorstellungOidBackingList;
    private java.lang.String kinoname;
    private Object[] kinonameBackingList;
    private java.lang.String datum;
    private de.moviepalace.services.tickets.VorstellungVO
ausgewaehlteVorstellung;
    private java.lang.String filmtitel;
...
}

especially there are two Arrays (BackingLists).

Therefore the toString-Method is generated that way:

   public String toString()
    {
        final StringBuffer buffer = new StringBuffer().append('[');

        buffer.append("anzahlTickets=");
        buffer.append(String.valueOf(this.getAnzahlTickets()));
        buffer.append(",reservierung=");
        buffer.append(String.valueOf(this.getReservierung()));
        buffer.append(",vorstellungOid=");
        buffer.append(String.valueOf(this.getVorstellungOid()));
        buffer.append(",vorstellungOidBackingList=");
        buffer.append(toString(this.getKinonameBackingList()));
        buffer.append(",kinoname=");
        buffer.append(String.valueOf(this.getKinoname()));
        buffer.append(",kinonameBackingList=");
        buffer.append(toString(this.getKinonameBackingList()));
        buffer.append(",datum=");
        buffer.append(String.valueOf(this.getDatum()));
        buffer.append(",ausgewaehlteVorstellung=");
        buffer.append(String.valueOf(this.getAusgewaehlteVorstellung()));
        buffer.append(",filmtitel=");
        buffer.append(String.valueOf(this.getFilmtitel()));

        return buffer.append(']').toString();
    }

with calls to the private helper method toString(Object[] objects). But
unfortunatly this method is not generated.

The Template says:

#if ($arrayPresent || $collectionPresent)
    private final static String toString(Object[] objects)
    {
...
    }
#end

so probably there's a problem with arrayPresent or collectionPresent:

#set ($collectionPresent = false)
#set ($arrayPresent = false)
#foreach ($field in $fields)
#if ($field.type.collectionType)
#set ($collectionPresent = true)
#end
#if ($field.type.arrayType)
#set ($arrayPresent = true)
#end

it seems that a check for $field.hasBackingList() is missing, right?

I'll try it out and see what will happen... (It seems that I'm starting to
understand how this stuff works... great!)

Regards
Stefan




-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
Andromda-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/andromda-user

Reply via email to