package Reldb.RelUserCode;

import org.reldb.rel.v0.types.*;
import org.reldb.rel.v0.types.builtin.*;
import org.reldb.rel.v0.types.userdefined.*;
import org.reldb.rel.v0.values.*;
import org.reldb.rel.v0.vm.Context;

public class op_TRIM__CHARACTER {
	private static final ValueCharacter do_TRIM(Context context, ValueCharacter s) {
		
		//          Trim leading and trailing blanks.
			return ValueCharacter.select(context.getGenerator(), s.stringValue().trim());
	}

	public static final void execute(Context context) {
		ValueCharacter p0 = (ValueCharacter)context.pop();
		context.push(do_TRIM(context, p0));
	}
}