package com.itranswarp.bitcoin.script;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

public abstract class Op {

	protected final Log log = LogFactory.getLog(getClass());

	public final String name;

	public Op(String name) {
		this.name = name;
	}

	public abstract boolean execute(ScriptContext context);

	@Override
	public String toString() {
		return name;
	}
}

@@ -239,56 +239,307 @@
 ;%0A%0A%09
-public Op(String name) %7B%0A%09%09this.name = name;%0A%09%7D%0A
+/**%0A%09 * Op constructor.%0A%09 * %0A%09 * @param name%0A%09 *            Human-readable name.%0A%09 */%0A%09public Op(String name) %7B%0A%09%09this.name = name;%0A%09%7D%0A%0A%09/**%0A%09 * Execute the OP and return true if success.%0A%09 * %0A%09 * @param context%0A%09 *            ScriptContext object.%0A%09 * @return True if success, otherwise false.%0A%09 */
 %0A%09pu

add comment