/// <summary>
/// Selects a collection of <see cref="$InfoType$" /> from the database
/// </summary>
/// <param name="$entityId$">$Param1Description$</param>
/// <returns>Data transfer object for the <see cref="$InfoType$" /></returns>
public $CollectionType$<$InfoType$> Get$Name$($parameterType$ $entityId$)
{
	return Get$Name$($entityId$, null);
}


/// <summary>
/// Selects a collection of <see cref="$InfoType$" /> from the database
/// </summary>
/// <param name="$entityId$">$Param1Description$</param>
/// <param name="transaction">Database transaction</param>
/// <returns>Collection of a Data transfer objects</returns>
internal $CollectionType$<$InfoType$> Get$Name$($parameterType$ $entityId$, DbTransaction transaction)
{
	Database database;
	DbCommand command;
	IDataReader reader = null;

	try
	{
		object[] parameters = new object[1];

		parameters[0] = $entityId$;

		database = DatabaseFactory.CreateDatabase();
		command = database.GetStoredProcCommand("[dbo].[$ProcedureName$]", parameters);
		reader = database.ExecuteReader(command);
		
		if (transaction != null)
		{
			reader = database.ExecuteReader(command, transaction);
		}
		else
		{
			reader = database.ExecuteReader(command);
		}

		$CollectionType$<$InfoType$> result = new $CollectionType$<$InfoType$>();
		$InfoType$ info;


		while (reader.Read())
		{
			info = new $InfoType$();
			
			$FillMethod$(info, reader);

			result.Add(info);
		}

		return result;
	}
	finally
	{
		if (reader != null)
		{
			reader.Dispose();
		}
	}
}