Options
"How to initialize plugins in java code (APPLET mode)?"
Hi,
I'm trying to test if I can run RM from the browser. However I couldn't seem to make the text plugin to load. I searched the forum but couldn't find similar application so I'm wondering if this is really possible. If it is possible, can someone please show me the correct way of initializing the plugin.
thanks,
Matt
Here's the code:
I'm trying to test if I can run RM from the browser. However I couldn't seem to make the text plugin to load. I searched the forum but couldn't find similar application so I'm wondering if this is really possible. If it is possible, can someone please show me the correct way of initializing the plugin.
thanks,
Matt
Here's the code:
Here's part of the output. From my understanding, it means that the text plugin did not load.
import com.rapidminer.RapidMiner;
import com.rapidminer.RapidMiner.ExecutionMode;
import com.rapidminer.repository.ProcessEntry;
import com.rapidminer.repository.RepositoryLocation;
import com.rapidminer.operator.IOContainer;
import com.rapidminer.Process;
import java.io.File;
import java.io.IOException;
public class MineText {
public void rmProcessRun() {
RapidMiner.setExecutionMode(ExecutionMode.APPLET);
System.setProperty("rapidminer.home", "/rapidminer");
//System.setProperty("rapidminer.init.plugins","true");
String pluginDirString = new File("/rapidminer/lib").getAbsolutePath();
System.setProperty(RapidMiner.PROPERTY_RAPIDMINER_INIT_PLUGINS_LOCATION, pluginDirString);
RapidMiner.init();
try {
RepositoryLocation pLoc = new RepositoryLocation("//RM/Text/Mine Documents");
ProcessEntry pEntry = (ProcessEntry) pLoc.locateEntry();
String processXML = pEntry.retrieveXML();
Process myProcess = new Process(processXML);
IOContainer result = myProcess.run();
System.out.println(result);
} catch (Exception e) {
e.printStackTrace();
}
}
}
com.rapidminer.operator.UserError: The dummy operator Read Document (replacing text:read_document) cannot be executed.
at com.rapidminer.operator.DummyOperator.doWork(DummyOperator.java:88)
at com.rapidminer.operator.Operator.execute(Operator.java:833)
at com.rapidminer.operator.execution.SimpleUnitExecutor.execute(SimpleUnitExecutor.java:51)
at com.rapidminer.operator.ExecutionUnit.execute(ExecutionUnit.java:709)
at com.rapidminer.operator.OperatorChain.doWork(OperatorChain.java:379)
at com.rapidminer.operator.SimpleOperatorChain.doWork(SimpleOperatorChain.java:61)
at com.rapidminer.operator.Operator.execute(Operator.java:833)
at com.rapidminer.operator.execution.SimpleUnitExecutor.execute(SimpleUnitExecutor.java:51)
at com.rapidminer.operator.ExecutionUnit.execute(ExecutionUnit.java:709)
at com.rapidminer.operator.OperatorChain.doWork(OperatorChain.java:379)
at com.rapidminer.operator.Operator.execute(Operator.java:833)
at com.rapidminer.Process.run(Process.java:925)
at com.rapidminer.Process.run(Process.java:848)
0
Answers
Best,
Marius