/*****************************************************
 * parser-utils.h: Exports functions for reading input
 * from the user and analyzing the result.
 */

#ifndef ParserUtils_Included
#define ParserUtils_Included

#include <sstream>
#include <string>
#include "common-types.h"
using namespace std;

/* Straight out of simpio.h. */
string GetLine();
int    GetInteger(); 

/* Straight out of strutils.h */
string ConvertToLowerCase(string input);

/* Returns whether a stringstream contains no more data. */
bool   IsEndOfInput(stringstream& s);

/* Parses a placeT out of a stringstream and returns whether the operation
 * succeeded.
 */
bool   ParseLocation(stringstream& s, placeT& result);

/* Prints a message telling the user to press enter to continue, then
 * fulfills that promise.
 */
void   PressEnterToContinue();

#endif
