Browse Source

javadoc + space around operands

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@277433 13f79535-47bb-0310-9956-ffa450edef68
master
Peter Reilly 21 years ago
parent
commit
82c0949e1a
1 changed files with 5 additions and 4 deletions
  1. +5
    -4
      src/main/org/apache/tools/ant/taskdefs/condition/Xor.java

+ 5
- 4
src/main/org/apache/tools/ant/taskdefs/condition/Xor.java View File

@@ -22,19 +22,20 @@ import java.util.Enumeration;


/** /**
* <tt>Xor</tt> task to exclusive or operations. * <tt>Xor</tt> task to exclusive or operations.
* This does not shortcut stuff
* This does not shortcut stuff.
*/ */
public class Xor extends ConditionBase implements Condition { public class Xor extends ConditionBase implements Condition {


/** /**
* @return true if all the contained conditions evaluates to true
* Evaluate the contained conditions.
* @return the result of xoring the conditions together.
* @throws org.apache.tools.ant.BuildException * @throws org.apache.tools.ant.BuildException
* if an error occurs
* if an error occurs.
*/ */
public boolean eval() throws BuildException { public boolean eval() throws BuildException {
Enumeration e = getConditions(); Enumeration e = getConditions();
//initial state is false. //initial state is false.
boolean state=false;
boolean state = false;
while (e.hasMoreElements()) { while (e.hasMoreElements()) {
Condition c = (Condition) e.nextElement(); Condition c = (Condition) e.nextElement();
//every condition is xored against the previous one //every condition is xored against the previous one


Loading…
Cancel
Save