
jedi.example.MultipleOptionsExampleClosureFactory Maven / Gradle / Ivy
package jedi.example;
public class MultipleOptionsExampleClosureFactory implements IMultipleOptionsExampleClosureFactory {
/**
* @see jedi.example.MultipleOptionsExample#add
*/
public jedi.functional.Functor addFunctor(final java.lang.String a, final java.lang.String b) {
class Closure implements java.io.Serializable, jedi.functional.Functor {
public java.lang.String execute(final jedi.example.MultipleOptionsExample $receiver) {
try {
return $receiver.add(a, b);
}
catch (RuntimeException ex) {
throw ex;
}
catch (Exception ex) {
throw new jedi.JediException(ex);
}
}
public int hashCode() {
return ((17) * 37 + (a == null ? 0 : a.hashCode())) * 37 + (b == null ? 0 : b.hashCode());
}
public boolean equals(Object obj) {
if (obj == this) { return true; }
if (!(obj instanceof Closure)) { return false; }
return ((Closure) obj).equalsParameters(a, b);
}
private boolean equalsParameters(final java.lang.String $a, final java.lang.String $b) {
return ($a == null ? a == null : $a.equals(a)) && ($b == null ? b == null : $b.equals(b));
}
}
return new Closure();
}
/**
* @see jedi.example.MultipleOptionsExample#add
*/
public jedi.functional.Functor2 addProxyFunctor2(final jedi.example.MultipleOptionsExample $receiver) {
class Closure implements java.io.Serializable, jedi.functional.Functor2 {
public java.lang.String execute(final java.lang.String a, final java.lang.String b) {
try {
return $receiver.add(a, b);
}
catch (RuntimeException ex) {
throw ex;
}
catch (Exception ex) {
throw new jedi.JediException(ex);
}
}
public int hashCode() {
return (17) * 37 + ($receiver == null ? 0 : $receiver.hashCode());
}
public boolean equals(Object obj) {
if (obj == this) { return true; }
if (!(obj instanceof Closure)) { return false; }
return ((Closure) obj).equalsParameters($receiver);
}
private boolean equalsParameters(final jedi.example.MultipleOptionsExample $$receiver) {
return ($$receiver == null ? $receiver == null : $$receiver.equals($receiver));
}
}
return new Closure();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy