/*
 * JaamSim Discrete Event Simulation
 * Copyright (C) 2011 Ausenco Engineering Canada Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * 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.
 */
package com.sandwell.JavaSimulation;

import com.jaamsim.input.Parser;

public class StringInput extends Input<String> {

	public StringInput(String key, String cat, String def) {
		super(key, cat, def);
	}

	@Override
	public void parse(StringVector input) throws InputErrorException {
		Input.assertCount(input, 1);
		value = input.firstElement();
		this.updateEditingFlags();
	}
	@Override
	public String getValueString() {
		String str = super.getValueString();

		if (Parser.needsQuoting(str))
			return String.format("'%s'", str);
		else
			return str;
	}
}

@@ -637,42 +637,8 @@
 n;%0A%0A
-import com.jaamsim.input.Parser;%0A%0A
 publ
@@ -947,186 +947,6 @@
 %0A%09%7D%0A
-%09@Override%0A%09public String getValueString() %7B%0A%09%09String str = super.getValueString();%0A%0A%09%09if (Parser.needsQuoting(str))%0A%09%09%09return String.format(%22'%25s'%22, str);%0A%09%09else%0A%09%09%09return str;%0A%09%7D%0A
 %7D%0A

remove additional valueString quoting in StringInput