ScrapperMin a Web Automation Language

How to build Plugin for ScrapperMin

John Kenedy 2017-04-21

ScrapperMin can load any functions or methods you have created natively in JAVA (jar file) using

        EX_MethodName(param1, param2, param3)

The jar file must be placed in /sdcard/ScrapperMin/SMPlugins/sample.jar The MethodName must be unique among all jar files in that directory, or the first MethodName that it encountered will be called instead, the namespace does not matter since ScrapperMin will load all classes in all namespaces however please note that the Method must be a static method that accept parameter in type String[] or String and return String[] or String And the jar file is a specialize jar file for android which inside it must have a classes.dex. In order to create such jar file, follow below tutorial

  1. Create a file using any text editor and name in, inside the file put

                    class Hello 
                        public static String add(String a) 
                            return a + " makan";
  2. Save the file then compile into a normal Jar file

                    jar cvf Hello.jar Hello.class
  3. Create classes.dex file (must be name classes.dex) using Android SDK tools (dx.bat)

                    dx --dex --output=classes.dex Hello.jar
  4. Include the classes.dex into existing normal Jar file (please note, you can't create a new jar file or having different name from the normal jar file)

                    aapt add Hello.jar classes.dex
  5. After finish you will get final Hello.jar. To double check whether it is correct, copy it into another folder, rename it to zip extension and extract you should see at least 2 files, Hello.class and classes.dex inside the zip file, if it is correct then continue

  6. Place the Hello.jar inside /sdcard/ScrapperMin/SMPlugins folder, if the folder does not exist, create it and place the file there. Subsequently you can place all your Jar plugins in this folder.
    Then run ScrapperMin app, and use this syntax


    After run you will see a final result "Saya Makan" which is concatenation of Saya and Makan from the jar file. ScrapperMin Windows version also support plugin, it just the the plugin extension is DLL (must be windows .NET library), and place in SMPlugins folder of where your ScrapperMin is, all of the function parameters also must be String or String[] and return of the method must be String and String[] too.