org.scijava.ops.engine.adapt.functional.InplacesToFunctions Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of scijava-ops-engine Show documentation
Show all versions of scijava-ops-engine Show documentation
Java implementation of the SciJava Ops matching engine.
The newest version!
/*-
* #%L
* Java implementation of the SciJava Ops matching engine.
* %%
* Copyright (C) 2016 - 2024 SciJava developers.
* %%
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
* #L%
*/
/*
* This is autogenerated source code -- DO NOT EDIT. Instead, edit the
* corresponding template in templates/ and rerun bin/generate.groovy.
*/
package org.scijava.ops.engine.adapt.functional;
import java.util.function.BiFunction;
import java.util.function.Function;
import org.scijava.function.Computers;
import org.scijava.function.Functions;
import org.scijava.function.Inplaces;
import org.scijava.ops.engine.BaseOpHints.Adaptation;
import org.scijava.ops.spi.Op;
import org.scijava.ops.spi.OpClass;
import org.scijava.ops.spi.OpCollection;
import org.scijava.ops.spi.OpDependency;
/**
* Collection of adaptation Ops to convert {@link Inplaces} into
* {@link Functions}.
*
* @author Gabriel Selzer
*/
public class InplacesToFunctions implements OpCollection {
@OpClass(names = "engine.adapt")
public static class Inplace1ToFunction1 implements Function, Function>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Function apply(Inplaces.Arity1 t) {
return (IO io) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace2_1ToFunction2 implements Function, BiFunction>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public BiFunction apply(Inplaces.Arity2_1 t) {
return (IO io, I2 in2) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp, in2);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace2_2ToFunction2 implements Function, BiFunction>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public BiFunction apply(Inplaces.Arity2_2 t) {
return (I1 in1, IO io) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, temp);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace3_1ToFunction3 implements Function, Functions.Arity3>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity3 apply(Inplaces.Arity3_1 t) {
return (IO io, I2 in2, I3 in3) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp, in2, in3);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace3_2ToFunction3 implements Function, Functions.Arity3>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity3 apply(Inplaces.Arity3_2 t) {
return (I1 in1, IO io, I3 in3) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, temp, in3);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace3_3ToFunction3 implements Function, Functions.Arity3>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity3 apply(Inplaces.Arity3_3 t) {
return (I1 in1, I2 in2, IO io) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, temp);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace4_1ToFunction4 implements Function, Functions.Arity4>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity4 apply(Inplaces.Arity4_1 t) {
return (IO io, I2 in2, I3 in3, I4 in4) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp, in2, in3, in4);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace4_2ToFunction4 implements Function, Functions.Arity4>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity4 apply(Inplaces.Arity4_2 t) {
return (I1 in1, IO io, I3 in3, I4 in4) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, temp, in3, in4);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace4_3ToFunction4 implements Function, Functions.Arity4>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity4 apply(Inplaces.Arity4_3 t) {
return (I1 in1, I2 in2, IO io, I4 in4) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, temp, in4);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace4_4ToFunction4 implements Function, Functions.Arity4>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity4 apply(Inplaces.Arity4_4 t) {
return (I1 in1, I2 in2, I3 in3, IO io) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, temp);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace5_1ToFunction5 implements Function, Functions.Arity5>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity5 apply(Inplaces.Arity5_1 t) {
return (IO io, I2 in2, I3 in3, I4 in4, I5 in5) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp, in2, in3, in4, in5);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace5_2ToFunction5 implements Function, Functions.Arity5>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity5 apply(Inplaces.Arity5_2 t) {
return (I1 in1, IO io, I3 in3, I4 in4, I5 in5) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, temp, in3, in4, in5);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace5_3ToFunction5 implements Function, Functions.Arity5>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity5 apply(Inplaces.Arity5_3 t) {
return (I1 in1, I2 in2, IO io, I4 in4, I5 in5) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, temp, in4, in5);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace5_4ToFunction5 implements Function, Functions.Arity5>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity5 apply(Inplaces.Arity5_4 t) {
return (I1 in1, I2 in2, I3 in3, IO io, I5 in5) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, temp, in5);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace5_5ToFunction5 implements Function, Functions.Arity5>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity5 apply(Inplaces.Arity5_5 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, IO io) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, temp);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace6_1ToFunction6 implements Function, Functions.Arity6>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity6 apply(Inplaces.Arity6_1 t) {
return (IO io, I2 in2, I3 in3, I4 in4, I5 in5, I6 in6) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp, in2, in3, in4, in5, in6);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace6_2ToFunction6 implements Function, Functions.Arity6>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity6 apply(Inplaces.Arity6_2 t) {
return (I1 in1, IO io, I3 in3, I4 in4, I5 in5, I6 in6) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, temp, in3, in4, in5, in6);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace6_3ToFunction6 implements Function, Functions.Arity6>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity6 apply(Inplaces.Arity6_3 t) {
return (I1 in1, I2 in2, IO io, I4 in4, I5 in5, I6 in6) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, temp, in4, in5, in6);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace6_4ToFunction6 implements Function, Functions.Arity6>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity6 apply(Inplaces.Arity6_4 t) {
return (I1 in1, I2 in2, I3 in3, IO io, I5 in5, I6 in6) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, temp, in5, in6);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace6_5ToFunction6 implements Function, Functions.Arity6>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity6 apply(Inplaces.Arity6_5 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, IO io, I6 in6) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, temp, in6);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace6_6ToFunction6 implements Function, Functions.Arity6>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity6 apply(Inplaces.Arity6_6 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, I5 in5, IO io) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, in5, temp);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace7_1ToFunction7 implements Function, Functions.Arity7>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity7 apply(Inplaces.Arity7_1 t) {
return (IO io, I2 in2, I3 in3, I4 in4, I5 in5, I6 in6, I7 in7) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp, in2, in3, in4, in5, in6, in7);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace7_2ToFunction7 implements Function, Functions.Arity7>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity7 apply(Inplaces.Arity7_2 t) {
return (I1 in1, IO io, I3 in3, I4 in4, I5 in5, I6 in6, I7 in7) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, temp, in3, in4, in5, in6, in7);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace7_3ToFunction7 implements Function, Functions.Arity7>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity7 apply(Inplaces.Arity7_3 t) {
return (I1 in1, I2 in2, IO io, I4 in4, I5 in5, I6 in6, I7 in7) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, temp, in4, in5, in6, in7);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace7_4ToFunction7 implements Function, Functions.Arity7>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity7 apply(Inplaces.Arity7_4 t) {
return (I1 in1, I2 in2, I3 in3, IO io, I5 in5, I6 in6, I7 in7) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, temp, in5, in6, in7);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace7_5ToFunction7 implements Function, Functions.Arity7>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity7 apply(Inplaces.Arity7_5 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, IO io, I6 in6, I7 in7) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, temp, in6, in7);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace7_6ToFunction7 implements Function, Functions.Arity7>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity7 apply(Inplaces.Arity7_6 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, I5 in5, IO io, I7 in7) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, in5, temp, in7);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace7_7ToFunction7 implements Function, Functions.Arity7>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity7 apply(Inplaces.Arity7_7 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, I5 in5, I6 in6, IO io) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, in5, in6, temp);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_1ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8 apply(Inplaces.Arity8_1 t) {
return (IO io, I2 in2, I3 in3, I4 in4, I5 in5, I6 in6, I7 in7, I8 in8) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(temp, in2, in3, in4, in5, in6, in7, in8);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_2ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8 apply(Inplaces.Arity8_2 t) {
return (I1 in1, IO io, I3 in3, I4 in4, I5 in5, I6 in6, I7 in7, I8 in8) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, temp, in3, in4, in5, in6, in7, in8);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_3ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8 apply(Inplaces.Arity8_3 t) {
return (I1 in1, I2 in2, IO io, I4 in4, I5 in5, I6 in6, I7 in7, I8 in8) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, temp, in4, in5, in6, in7, in8);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_4ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8 apply(Inplaces.Arity8_4 t) {
return (I1 in1, I2 in2, I3 in3, IO io, I5 in5, I6 in6, I7 in7, I8 in8) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, temp, in5, in6, in7, in8);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_5ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8 apply(Inplaces.Arity8_5 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, IO io, I6 in6, I7 in7, I8 in8) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, temp, in6, in7, in8);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_6ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8 apply(Inplaces.Arity8_6 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, I5 in5, IO io, I7 in7, I8 in8) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, in5, temp, in7, in8);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_7ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8 apply(Inplaces.Arity8_7 t) {
return (I1 in1, I2 in2, I3 in3, I4 in4, I5 in5, I6 in6, IO io, I8 in8) -> {
IO temp = createOp.apply(io);
copyOp.accept(io, temp);
t.mutate(in1, in2, in3, in4, in5, in6, temp, in8);
return temp;
};
}
}
@OpClass(names = "engine.adapt")
public static class Inplace8_8ToFunction8 implements Function, Functions.Arity8>, Op {
@OpDependency(name = "engine.create", hints={Adaptation.FORBIDDEN})
private Function createOp;
@OpDependency(name = "engine.copy", hints={Adaptation.FORBIDDEN})
private Computers.Arity1 copyOp;
/**
* @param t the Inplace to adapt
* @return an adaptation of inplace
*/
@Override
public Functions.Arity8