1 10 package org.jgap.gp.function; 11 12 import org.jgap.*; 13 import org.jgap.gp.*; 14 import org.jgap.gp.impl.*; 15 16 22 public class Not 23 extends MathCommand { 24 25 private final static String CVS_REVISION = "$Revision: 1.4 $"; 26 27 public Not(final GPConfiguration a_conf) 28 throws InvalidConfigurationException { 29 super(a_conf, 1, CommandGene.BooleanClass); 30 } 31 32 public String toString() { 33 return "!&1"; 34 } 35 36 42 public String getName() { 43 return "Not"; 44 } 45 46 public boolean execute_boolean(ProgramChromosome c, int n, Object [] args) { 47 return!c.execute_boolean(n, 0, args); 48 } 49 } 50 | Popular Tags |