src/grammar.cpp
std::string Grammar::printExpansionType(Expansion * e) {
	switch(e->getType()) {
		case UNPARSED_SECTION:
			return "UNPARSED_SECTION";
			break;
		case KLEENE_STAR:
			return "KLEENE_STAR";
			break;
		case PLUS_OPERATOR:
			return "PLUS_OPERATOR";
			break;
		case REQUIRED_GROUPING:
			return "REQUIRED_GROUPING";
			break;
		case OPTIONAL_GROUPING:
			return "OPTIONAL_GROUPING";
			break;
		case SEQUENCE:
			return "SEQUENCE";
			break;
		case TOKEN:
			return "TOKEN";
			break;
		case ALTERNATE_SET:
			return "ALTERNATIVE_SET";
			break;
		case TAG:
			return "TAG";
			break;
		default:
			return "UNKNOWN TYPE";
			break;
	}
	return "ERROR";
}
///Helper function that returns a string representation of the type of Expansion
Helper function that returns a string representation of the type of Expansion
Helper function that returns a string representation of the type of Expansion
std::string Grammar::printExpansionType(Expansion * e) {
	switch(e->getType()) {
		case UNPARSED_SECTION:
			return "UNPARSED_SECTION";
			break;
		case KLEENE_STAR:
			return "KLEENE_STAR";
			break;
		case PLUS_OPERATOR:
			return "PLUS_OPERATOR";
			break;
		case REQUIRED_GROUPING:
			return "REQUIRED_GROUPING";
			break;
		case OPTIONAL_GROUPING:
			return "OPTIONAL_GROUPING";
			break;
		case SEQUENCE:
			return "SEQUENCE";
			break;
		case TOKEN:
			return "TOKEN";
			break;
		case ALTERNATE_SET:
			return "ALTERNATIVE_SET";
			break;
		case TAG:
			return "TAG";
			break;
		default:
			return "UNKNOWN TYPE";
			break;
	}
	return "ERROR";
}
std :: string Grammar :: printExpansionType ( Expansion * e ) { switch ( e -> getType ( ) ) { case UNPARSED_SECTION : return " " ; break ; case KLEENE_STAR : return " " ; break ; case PLUS_OPERATOR : return " " ; break ; case REQUIRED_GROUPING : return " " ; break ; case OPTIONAL_GROUPING : return " " ; break ; case SEQUENCE : return " " ; break ; case TOKEN : return " " ; break ; case ALTERNATE_SET : return " " ; break ; case TAG : return " " ; break ; default : return " " ; break ; } return " " ; }
Helper function that returns a string representation of the type of Expansion
Helper function that returns a string representation of the type of Expansion