Iterator iter = this.transports.iterator(); while ( iter.hasNext() ) { Transporter next = (Transporter)iter.next();
Enumeration iter = this.transports.elements(); while ( iter.hasMoreElements() ) { Transporter next = (Transporter)iter.nextElement();
    public Entity getExteriorUnitAt( int loc, boolean isRear ) {	// Walk through this entity's transport components;	// check each for an exterior unit in turn.	// Stop after the first match.	Iterator iter = this.transports.iterator();	while ( iter.hasNext() ) {	    Transporter next = (Transporter)iter.next();            Entity exterior = next.getExteriorUnitAt( loc, isRear );	    if ( null != exterior ) {		return exterior;	    }	}	// If we got here, none of our transports        // carry an exterior unit at that location.	return null;    }