/*
 *  gen_data.h from ObjectProDSP 0.2
 *  Copyright (C) 1994 1995, Mountain Math Software, All rights reserved.
 *  Licensed for free use and distribution under version 2 of the Gnu General
 *  Public License. Please see file COPYING for details and restrictions.
 *  
 *  ObjectProDSP is a trademark of Mountain Math Software.
 */
class ostream ;

struct InsertList {
	int where ;
	int count ;
	double * values ;
	char ** strings ;
};

enum format {f_none,f_dec,f_hex,f_oct,f_float};
class GenData {
	const char * file_name ;
	int fields_per_line ;
	int start_val ;
	int skip_val ;
	int max_val ;
	format form ;
	int total_out ;
	int total_count ;
	ostream * str ;
	int width ;
	double divisor ;
	double multiplier ;
	int flds ;
	InsertList * insert ;
	void out_val(int val, format f) ;
	void out_val(double v) ;
	void out_val(const char *st);
	void field_out();
	int check_insert(int val);
	void out(InsertList& ins);
public:
	GenData(const char * name,int fields,int strt_val, int skp_val, int mx_val,
		format f,int tot=100000,int w=0,InsertList * ins=0,double dvs=1.,
		double fac = 1.);
	void out();
};

