2 * This code is generated in org.simantics.scl.runtime.generation.GenerateFunctions.
3 * Do not edit manually!
5 package org.simantics.scl.runtime.function;
7 @SuppressWarnings("all")
8 public class UnsaturatedFunction2 implements Function {
9 private final Function f;
10 private final Object p0;
11 private final Object p1;
13 public UnsaturatedFunction2(Function f, Object p0, Object p1) {
20 public Object apply(Object p2) {
21 return f.apply(p0, p1, p2);
25 public Object apply(Object p2, Object p3) {
26 return f.apply(p0, p1, p2, p3);
30 public Object apply(Object p2, Object p3, Object p4) {
31 return f.apply(p0, p1, p2, p3, p4);
35 public Object apply(Object p2, Object p3, Object p4, Object p5) {
36 return f.apply(p0, p1, p2, p3, p4, p5);
40 public Object apply(Object p2, Object p3, Object p4, Object p5, Object p6) {
41 return f.apply(p0, p1, p2, p3, p4, p5, p6);
45 public Object apply(Object p2, Object p3, Object p4, Object p5, Object p6, Object p7) {
46 return f.apply(p0, p1, p2, p3, p4, p5, p6, p7);
50 public Object apply(Object p2, Object p3, Object p4, Object p5, Object p6, Object p7, Object p8) {
51 return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8);
55 public Object apply(Object p2, Object p3, Object p4, Object p5, Object p6, Object p7, Object p8, Object p9) {
56 return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9);
60 public Object applyArray(Object ... ps) {
61 Object[] nps = new Object[ps.length + 2];
64 for(int i=0;i<ps.length;++i)
66 return f.applyArray(nps);
70 public String toString() {
71 StringBuilder sb = new StringBuilder();
72 sb.append("(").append(f);
73 sb.append(" ").append(p0);
74 sb.append(" ").append(p1);
80 public int hashCode() {
81 int result = f.hashCode();
82 result = 31 * result + (p0 == null ? 0 : p0.hashCode());
83 result = 31 * result + (p1 == null ? 0 : p1.hashCode());
88 public boolean equals(Object obj) {
93 if (getClass() != obj.getClass())
95 UnsaturatedFunction2 other = (UnsaturatedFunction2) obj;
96 if(!f.equals(other.f))
101 } else if (!p0.equals(other.p0))
104 if (other.p1 != null)
106 } else if (!p1.equals(other.p1))