5353
5454import org .scijava .ops .OpField ;
5555import org .scijava .ops .core .OpCollection ;
56- import org .scijava .ops .core . computer . Computer ;
56+ import org .scijava .ops .function . Computers ;
5757import org .scijava .param .Parameter ;
5858import org .scijava .plugin .Plugin ;
5959import org .scijava .struct .ItemIO ;
@@ -69,117 +69,117 @@ public final class ConvertTypes<C extends ComplexType<C>, T extends IntegerType<
6969 @ OpField (names = "convert.bit" )
7070 @ Parameter (key = "input" )
7171 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
72- public final Computer <C , BitType > complexToBit = (input , output ) -> output .set (input .getRealDouble () != 0 );
72+ public final Computers . Arity1 <C , BitType > complexToBit = (input , output ) -> output .set (input .getRealDouble () != 0 );
7373
7474 @ OpField (names = "convert.bit" )
7575 @ Parameter (key = "input" )
7676 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
77- public final Computer <T , BitType > integerToBit = (input , output ) -> output .set (input .getIntegerLong () != 0 );
77+ public final Computers . Arity1 <T , BitType > integerToBit = (input , output ) -> output .set (input .getIntegerLong () != 0 );
7878
7979 @ OpField (names = "convert.uint2" )
8080 @ Parameter (key = "input" )
8181 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
82- public final Computer <C , Unsigned2BitType > complexToUint2 = (input , output ) -> output .set ((long ) input .getRealDouble ());
82+ public final Computers . Arity1 <C , Unsigned2BitType > complexToUint2 = (input , output ) -> output .set ((long ) input .getRealDouble ());
8383
8484 @ OpField (names = "convert.uint2" )
8585 @ Parameter (key = "input" )
8686 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
87- public final Computer <T , Unsigned2BitType > integerToUint2 = (input , output ) -> output .set (input .getIntegerLong ());
87+ public final Computers . Arity1 <T , Unsigned2BitType > integerToUint2 = (input , output ) -> output .set (input .getIntegerLong ());
8888
8989 @ OpField (names = "convert.uint4" )
9090 @ Parameter (key = "input" )
9191 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
92- public final Computer <C , Unsigned4BitType > complexToUint4 = (input , output ) -> output .set ((long ) input .getRealDouble ());
92+ public final Computers . Arity1 <C , Unsigned4BitType > complexToUint4 = (input , output ) -> output .set ((long ) input .getRealDouble ());
9393
9494 @ OpField (names = "convert.uint4" )
9595 @ Parameter (key = "input" )
9696 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
97- public final Computer <T , Unsigned4BitType > integerToUint4 = (input , output ) -> output .set (input .getIntegerLong ());
97+ public final Computers . Arity1 <T , Unsigned4BitType > integerToUint4 = (input , output ) -> output .set (input .getIntegerLong ());
9898
9999 @ OpField (names = "convert.byte" )
100100 @ Parameter (key = "input" )
101101 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
102- public final Computer <C , ByteType > complexToInt8 = (input , output ) -> output .set ((byte ) input .getRealDouble ());
102+ public final Computers . Arity1 <C , ByteType > complexToInt8 = (input , output ) -> output .set ((byte ) input .getRealDouble ());
103103
104104 @ OpField (names = "convert.byte" )
105105 @ Parameter (key = "input" )
106106 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
107- public final Computer <T , ByteType > integerToInt8 = (input , output ) -> output .set ((byte ) input .getIntegerLong ());
107+ public final Computers . Arity1 <T , ByteType > integerToInt8 = (input , output ) -> output .set ((byte ) input .getIntegerLong ());
108108
109109 @ OpField (names = "convert.uint8" )
110110 @ Parameter (key = "input" )
111111 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
112- public final Computer <C , UnsignedByteType > complexToUint8 = (input , output ) -> output .set ((int ) input .getRealDouble ());
112+ public final Computers . Arity1 <C , UnsignedByteType > complexToUint8 = (input , output ) -> output .set ((int ) input .getRealDouble ());
113113
114114 @ OpField (names = "convert.uint8" )
115115 @ Parameter (key = "input" )
116116 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
117- public final Computer <T , UnsignedByteType > integerToUint8 = (input , output ) -> output .set (input .getInteger ());
117+ public final Computers . Arity1 <T , UnsignedByteType > integerToUint8 = (input , output ) -> output .set (input .getInteger ());
118118
119119 @ OpField (names = "convert.uint12" )
120120 @ Parameter (key = "input" )
121121 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
122- public final Computer <C , Unsigned12BitType > complexToUint12 = (input , output ) -> output .set ((long ) input .getRealDouble ());
122+ public final Computers . Arity1 <C , Unsigned12BitType > complexToUint12 = (input , output ) -> output .set ((long ) input .getRealDouble ());
123123
124124 @ OpField (names = "convert.uint12" )
125125 @ Parameter (key = "input" )
126126 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
127- public final Computer <T , Unsigned12BitType > integerToUint12 = (input , output ) -> output .set (input .getIntegerLong ());
127+ public final Computers . Arity1 <T , Unsigned12BitType > integerToUint12 = (input , output ) -> output .set (input .getIntegerLong ());
128128
129129 @ OpField (names = "convert.int16" )
130130 @ Parameter (key = "input" )
131131 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
132- public final Computer <C , ShortType > complexToInt16 = (input , output ) -> output .set ((short ) input .getRealDouble ());
132+ public final Computers . Arity1 <C , ShortType > complexToInt16 = (input , output ) -> output .set ((short ) input .getRealDouble ());
133133
134134 @ OpField (names = "convert.int16" )
135135 @ Parameter (key = "input" )
136136 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
137- public final Computer <T , ShortType > integerToInt16 = (input , output ) -> output .set ((short ) input .getIntegerLong ());
137+ public final Computers . Arity1 <T , ShortType > integerToInt16 = (input , output ) -> output .set ((short ) input .getIntegerLong ());
138138
139139 @ OpField (names = "convert.uint16" )
140140 @ Parameter (key = "input" )
141141 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
142- public final Computer <C , UnsignedShortType > complexToUint16 = (input , output ) -> output .set ((int ) input .getRealDouble ());
142+ public final Computers . Arity1 <C , UnsignedShortType > complexToUint16 = (input , output ) -> output .set ((int ) input .getRealDouble ());
143143
144144 @ OpField (names = "convert.uint16" )
145145 @ Parameter (key = "input" )
146146 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
147- public final Computer <T , UnsignedShortType > integerToUint16 = (input , output ) -> output .set (input .getInteger ());
147+ public final Computers . Arity1 <T , UnsignedShortType > integerToUint16 = (input , output ) -> output .set (input .getInteger ());
148148
149149 @ OpField (names = "convert.int32" )
150150 @ Parameter (key = "input" )
151151 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
152- public final Computer <C , IntType > complexToInt32 = (input , output ) -> output .set ((int ) input .getRealDouble ());
152+ public final Computers . Arity1 <C , IntType > complexToInt32 = (input , output ) -> output .set ((int ) input .getRealDouble ());
153153
154154 @ OpField (names = "convert.int32" )
155155 @ Parameter (key = "input" )
156156 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
157- public final Computer <T , IntType > integerToInt32 = (input , output ) -> output .set (input .getInteger ());
157+ public final Computers . Arity1 <T , IntType > integerToInt32 = (input , output ) -> output .set (input .getInteger ());
158158
159159 @ OpField (names = "convert.uint32" )
160160 @ Parameter (key = "input" )
161161 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
162- public final Computer <C , UnsignedIntType > complexToUint32 = (input , output ) -> output .set ((long ) input .getRealDouble ());
162+ public final Computers . Arity1 <C , UnsignedIntType > complexToUint32 = (input , output ) -> output .set ((long ) input .getRealDouble ());
163163
164164 @ OpField (names = "convert.uint32" )
165165 @ Parameter (key = "input" )
166166 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
167- public final Computer <T , UnsignedIntType > integerToUint32 = (input , output ) -> output .set (input .getIntegerLong ());
167+ public final Computers . Arity1 <T , UnsignedIntType > integerToUint32 = (input , output ) -> output .set (input .getIntegerLong ());
168168
169169 @ OpField (names = "convert.int64" )
170170 @ Parameter (key = "input" )
171171 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
172- public final Computer <C , LongType > complexToInt64 = (input , output ) -> output .set ((long ) input .getRealDouble ());
172+ public final Computers . Arity1 <C , LongType > complexToInt64 = (input , output ) -> output .set ((long ) input .getRealDouble ());
173173
174174 @ OpField (names = "convert.int64" )
175175 @ Parameter (key = "input" )
176176 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
177- public final Computer <T , LongType > integerToInt64 = (input , output ) -> output .set (input .getIntegerLong ());
177+ public final Computers . Arity1 <T , LongType > integerToInt64 = (input , output ) -> output .set (input .getIntegerLong ());
178178
179179 @ OpField (names = "convert.uint64" )
180180 @ Parameter (key = "input" )
181181 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
182- public final Computer <C , UnsignedLongType > complexToUint64 = (input , output ) -> {
182+ public final Computers . Arity1 <C , UnsignedLongType > complexToUint64 = (input , output ) -> {
183183 final BigDecimal bd = BigDecimal .valueOf (input .getRealDouble ());
184184 final BigDecimal r = bd .remainder (BigDecimal .ONE );
185185 if (r .compareTo (BigDecimal .ZERO ) == 0 ) {
@@ -192,7 +192,7 @@ public final class ConvertTypes<C extends ComplexType<C>, T extends IntegerType<
192192 @ OpField (names = "convert.uint128" )
193193 @ Parameter (key = "input" )
194194 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
195- public final Computer <C , Unsigned128BitType > complexToUint128 = (input , output ) -> {
195+ public final Computers . Arity1 <C , Unsigned128BitType > complexToUint128 = (input , output ) -> {
196196 final BigDecimal bd = BigDecimal .valueOf (input .getRealDouble ());
197197 final BigDecimal r = bd .remainder (BigDecimal .ONE );
198198 if (r .compareTo (BigDecimal .ZERO ) == 0 ) {
@@ -205,27 +205,27 @@ public final class ConvertTypes<C extends ComplexType<C>, T extends IntegerType<
205205 @ OpField (names = "convert.uint128" )
206206 @ Parameter (key = "input" )
207207 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
208- public final Computer <T , Unsigned128BitType > integerToUint128 = (input , output ) -> output .set (input .getBigInteger ());
208+ public final Computers . Arity1 <T , Unsigned128BitType > integerToUint128 = (input , output ) -> output .set (input .getBigInteger ());
209209
210210 @ OpField (names = "convert.float32" )
211211 @ Parameter (key = "input" )
212212 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
213- public final Computer <C , FloatType > complexToFloat32 = (input , output ) -> output .set (input .getRealFloat ());
213+ public final Computers . Arity1 <C , FloatType > complexToFloat32 = (input , output ) -> output .set (input .getRealFloat ());
214214
215215 @ OpField (names = "convert.cfloat32" )
216216 @ Parameter (key = "input" )
217217 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
218- public final Computer <C , ComplexFloatType > complexToCfloat32 = (input , output ) -> output .set (input .getRealFloat (),
218+ public final Computers . Arity1 <C , ComplexFloatType > complexToCfloat32 = (input , output ) -> output .set (input .getRealFloat (),
219219 input .getImaginaryFloat ());
220220
221221 @ OpField (names = "convert.float64" )
222222 @ Parameter (key = "input" )
223223 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
224- public final Computer <C , DoubleType > complexToFloat64 = (input , output ) -> output .set (input .getRealDouble ());
224+ public final Computers . Arity1 <C , DoubleType > complexToFloat64 = (input , output ) -> output .set (input .getRealDouble ());
225225
226226 @ OpField (names = "convert.cfloat64" )
227227 @ Parameter (key = "input" )
228228 @ Parameter (key = "output" , itemIO = ItemIO .BOTH )
229- public final Computer <C , ComplexDoubleType > complexToCfloat64 = (input , output ) -> output .set (input .getRealDouble (),
229+ public final Computers . Arity1 <C , ComplexDoubleType > complexToCfloat64 = (input , output ) -> output .set (input .getRealDouble (),
230230 input .getImaginaryDouble ());
231231}
0 commit comments