#include <assert.h>
#include <stdio.h>
#include "NodeList.h"
#include <algorithm>
#include <cstring>
#include <typeinfo>
Defines | |
#define | _LARGEFILE_SOURCE |
#define | _LARGEFILE64_SOURCE |
Enumerations | |
enum | nodeType { UNDEF, IN, OUT, BOOLEAN, MUTANT, ANALPTS, DELAY, SUSTAIN, RUNTIME, NOISE, COMMENT } |
Functions | |
void | readLine (istream &in) |
bool | isEmpty () |
bool | isEOF (istream &in) |
char | readChar (istream &in) |
string | readWord (istream &in, char &terminator) |
void | skipLine (istream &in) |
nodeType | readType (istream &in) |
string | readName (istream &in) |
int | readValue (istream &in, char &t) |
float | readFloat (istream &in) |
bool | readInitial (string &src, string &inputStr) |
bool | readInitial (string &init) |
string | readInitialSrc (istream &in) |
int | readSource (istream &in, NodeList &nl, int &source) |
bool | readMutant (istream &in, NodeList &nl, string &mutant) |
int | readDecision (istream &in, int &decision) |
void | setRandInputs (InputNode &n, NodeList &nl) |
void | readAnalPts (istream &in, NodeList &nl) |
bool | readParams (istream &in, InputNode &n, bool random, NodeList &nl) |
istream & | operator>> (istream &in, NodeList &nl) |
int | getWord (FILE *in, char *buf, int &index, string &str, char tok, bool alphaOnly) |
Variables | |
char | line [1000000000] |
int | offset = 100000000 |
#define _LARGEFILE64_SOURCE |
#define _LARGEFILE_SOURCE |
Copyright (C) 2004-2008 Tomas Helikar & Mathbio Research Group, Department of Mathematics, University of Nebraska at Omaha
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2, as published by the Free Software Foundation.
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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
enum nodeType |
int getWord | ( | FILE * | in, | |
char * | buf, | |||
int & | index, | |||
string & | str, | |||
char | tok, | |||
bool | alphaOnly | |||
) |
bool isEmpty | ( | ) |
Test if line is exhausted
bool isEOF | ( | istream & | in | ) |
Test if input is exhausted
istream& operator>> | ( | istream & | in, | |
NodeList & | nl | |||
) |
Reads in an Inputfile and sets up the network based on that file
void readAnalPts | ( | istream & | in, | |
NodeList & | nl | |||
) |
Read points of output analysis
char readChar | ( | istream & | in | ) |
Read a character from the working buffer
int readDecision | ( | istream & | in, | |
int & | decision | |||
) |
Read a decision table: a string of T and F characters
float readFloat | ( | istream & | in | ) |
Read in a float value
bool readInitial | ( | string & | init | ) |
Read the intial value for a chemical node: either True or False
bool readInitial | ( | string & | src, | |
string & | inputStr | |||
) |
Read the intial value for a chemical node: either True or False
string readInitialSrc | ( | istream & | in | ) |
Read the intial value for a chemical node: either True or False
void readLine | ( | istream & | in | ) |
Read a line from the working buffer
bool readMutant | ( | istream & | in, | |
NodeList & | nl, | |||
string & | mutant | |||
) |
read a word into string & mutant and return true if istream is empty
string readName | ( | istream & | in | ) |
Read in a chemical node name and return the name
Reads the start, dosage, and duration from the instream for an InputNode (Tomas Helikar 9/26/05)
int readSource | ( | istream & | in, | |
NodeList & | nl, | |||
int & | source | |||
) |
Read in a chemical node name, locate and return its index
nodeType readType | ( | istream & | in | ) |
Read in the line type
int readValue | ( | istream & | in, | |
char & | t | |||
) |
Read in an integer value
string readWord | ( | istream & | in, | |
char & | terminator | |||
) |
Read in a single word, deliminated by either ':', ",", or "\n"
void skipLine | ( | istream & | in | ) |
The remainder of the input line is read and discarded.
char line[1000000000] |
int offset = 100000000 |