#if (!$generate)
	#set ($generate = true)
	#foreach ($src in $types_void)
		#set ($sig0 = "")
		#set ($destSig0 = "")
		#set ($Src = $pp.firstToUpperCase($src))
		#if ($Src == "Object")
			#set ($src = "K")
			#set ($sig0 = "<K>")
		#end
		#foreach ($dest in $types_void)
			#set ($sig = $sig0)
			#set ($destSig = $destSig0)
			#set ($Dest = $pp.firstToUpperCase($dest))
			#if ($Dest == "Object")
				#set ($dest = "V")
				#set ($destSig = "<? super V>")
				#if ($Src == "Object")
					#set ($sig = "<K,V>")
				#else
					#set ($sig = "<V>")
				#end
			#end
			#set ($out = "de/grogra/xl/lang/${Src}To${Dest}Generator.java")
			$generator.parse("de/grogra/xl/lang/Generator.vm", $out)
		#end
	#end
#else

$pp.autogenerated

/*
 * Copyright (C) 2002 - 2007 Lehrstuhl Grafische Systeme, BTU Cottbus
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 3
 * of the License, or any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 */

package de.grogra.xl.lang;

/**
 * Instances of <code>${Src}To${Dest}Generator</code> represent
 * generator functions which take <code>$src</code>s as input
 * and yield sequences of values of
 * type <code>$dest</code>. Such instances are created by
 * lambda expressions of the XL programming language, e.g.,
#if ($src == "void")
 * <code>${Src}To${Dest}Generator f = $src => ${dest}*</code>
 * <i>some generator expression</i><code>;</code>.
#else
 * <code>${Src}To${Dest}Generator f = $src x => ${dest}*</code>
 * <i>some generator expression containing x</i><code>;</code>.
#end
 *
 * @author Ole Kniemeyer
 */
public interface ${Src}To${Dest}Generator${sig}
{
#if ($src == "void")
	/**
	 * Generates the sequence of values.
	 * 
	 * @param cons each value is yielded to this consumer
	 */
	void evaluate$Dest (${Dest}Consumer${destSig} cons);
#else
	/**
	 * Generates the sequence of values for parameter <code>x</code>.
	 * 
	 * @param cons each value is yielded to this consumer
	 * @param x where the generator function is to be evaluated
	 */
	void evaluate$Dest (${Dest}Consumer${destSig} cons, $src x);
#end
}
#end
