Some sun.misc internal APIs are deprectaed in JDK 9 and will be encapsulated or removed in a future release.
/** * Creates a new cleaner. * * @param thunk * The cleanup code to be run when the cleaner is invoked. The * cleanup code is run directly from the reference-handler thread, * so it should be as simple and straightforward as possible. * * @return The new cleaner */ public static Cleaner create(Object ob, Runnable thunk) { if (thunk == null) return null; return add(new Cleaner(ob, thunk)); }
import java.util.*; import com.everis.csv.Cleaner; public boolean processRow(StepMetaInterface smi, StepDataInterface sdi) throws KettleException { Cleaner c = new Cleaner(); c.clean(); // The rest of it is for making it work // You will also need to make a Generate Rows step that inputs a row to this step. Object[] r = getRow(); if (r == null) { setOutputDone(); return false; } r = createOutputRow(r, data.outputRowMeta.size()); putRow(data.outputRowMeta, r); return true; }