]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.scl.runtime/src/org/simantics/scl/runtime/function/UnsaturatedFunction6.java
Fixed multiple issues causing dangling references to discarded queries
[simantics/platform.git] / bundles / org.simantics.scl.runtime / src / org / simantics / scl / runtime / function / UnsaturatedFunction6.java
1 /**
2  * This code is generated in org.simantics.scl.runtime.generation.GenerateFunctions.
3  * Do not edit manually!
4  */
5 package org.simantics.scl.runtime.function;
6
7 @SuppressWarnings("all")
8 public class UnsaturatedFunction6 implements Function {
9     private final Function f;
10     private final Object p0;
11     private final Object p1;
12     private final Object p2;
13     private final Object p3;
14     private final Object p4;
15     private final Object p5;
16
17     public UnsaturatedFunction6(Function f, Object p0, Object p1, Object p2, Object p3, Object p4, Object p5) {
18         this.f = f;
19         this.p0 = p0;
20         this.p1 = p1;
21         this.p2 = p2;
22         this.p3 = p3;
23         this.p4 = p4;
24         this.p5 = p5;
25     }
26
27     @Override
28     public Object apply(Object p6) {
29         return f.apply(p0, p1, p2, p3, p4, p5, p6);
30     }
31
32     @Override
33     public Object apply(Object p6, Object p7) {
34         return f.apply(p0, p1, p2, p3, p4, p5, p6, p7);
35     }
36
37     @Override
38     public Object apply(Object p6, Object p7, Object p8) {
39         return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8);
40     }
41
42     @Override
43     public Object apply(Object p6, Object p7, Object p8, Object p9) {
44         return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9);
45     }
46
47     @Override
48     public Object apply(Object p6, Object p7, Object p8, Object p9, Object p10) {
49         return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10);
50     }
51
52     @Override
53     public Object apply(Object p6, Object p7, Object p8, Object p9, Object p10, Object p11) {
54         return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11);
55     }
56
57     @Override
58     public Object apply(Object p6, Object p7, Object p8, Object p9, Object p10, Object p11, Object p12) {
59         return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12);
60     }
61
62     @Override
63     public Object apply(Object p6, Object p7, Object p8, Object p9, Object p10, Object p11, Object p12, Object p13) {
64         return f.applyArray(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13);
65     }
66
67     @Override
68     public Object applyArray(Object ... ps) {
69         Object[] nps = new Object[ps.length + 6];
70         nps[0] = p0;
71         nps[1] = p1;
72         nps[2] = p2;
73         nps[3] = p3;
74         nps[4] = p4;
75         nps[5] = p5;
76         for(int i=0;i<ps.length;++i)
77             nps[i + 6] = ps[i];
78         return f.applyArray(nps);
79     }
80
81     @Override
82     public String toString() {
83         StringBuilder sb = new StringBuilder();
84         sb.append("(").append(f);
85         sb.append(" ").append(p0);
86         sb.append(" ").append(p1);
87         sb.append(" ").append(p2);
88         sb.append(" ").append(p3);
89         sb.append(" ").append(p4);
90         sb.append(" ").append(p5);
91         sb.append(")");
92         return sb.toString();
93     }
94
95     @Override
96     public int hashCode() {
97         int result = f.hashCode();
98         result = 31 * result + (p0 == null ? 0 : p0.hashCode());
99         result = 31 * result + (p1 == null ? 0 : p1.hashCode());
100         result = 31 * result + (p2 == null ? 0 : p2.hashCode());
101         result = 31 * result + (p3 == null ? 0 : p3.hashCode());
102         result = 31 * result + (p4 == null ? 0 : p4.hashCode());
103         result = 31 * result + (p5 == null ? 0 : p5.hashCode());
104         return result;
105     }
106
107     @Override
108     public boolean equals(Object obj) {
109         if (this == obj)
110             return true;
111         if (obj == null)
112             return false;
113         if (getClass() != obj.getClass())
114             return false;
115         UnsaturatedFunction6 other = (UnsaturatedFunction6) obj;
116         if(!f.equals(other.f))
117             return false;
118         if(p0 == null) {
119             if (other.p0 != null)
120                 return false;
121         } else if (!p0.equals(other.p0))
122             return false;
123         if(p1 == null) {
124             if (other.p1 != null)
125                 return false;
126         } else if (!p1.equals(other.p1))
127             return false;
128         if(p2 == null) {
129             if (other.p2 != null)
130                 return false;
131         } else if (!p2.equals(other.p2))
132             return false;
133         if(p3 == null) {
134             if (other.p3 != null)
135                 return false;
136         } else if (!p3.equals(other.p3))
137             return false;
138         if(p4 == null) {
139             if (other.p4 != null)
140                 return false;
141         } else if (!p4.equals(other.p4))
142             return false;
143         if(p5 == null) {
144             if (other.p5 != null)
145                 return false;
146         } else if (!p5.equals(other.p5))
147             return false;
148         return true;
149     }
150
151 }