From 36820ec411d23eed704a6d429522c40d132663c5 Mon Sep 17 00:00:00 2001 From: Gideon le Grange Date: Thu, 5 Jan 2017 15:08:42 +0200 Subject: [PATCH] Removed stray example --- src/main/java/examples/Issue27.java | 69 ----------------------------- 1 file changed, 69 deletions(-) delete mode 100644 src/main/java/examples/Issue27.java diff --git a/src/main/java/examples/Issue27.java b/src/main/java/examples/Issue27.java deleted file mode 100644 index 9999351..0000000 --- a/src/main/java/examples/Issue27.java +++ /dev/null @@ -1,69 +0,0 @@ -package examples; - -import java.util.ArrayList; -import java.util.List; -import java.util.Map; -import me.legrange.mikrotik.MikrotikApiException; -import me.legrange.mikrotik.ResultListener; - -/** - * Example to show that different character sets may work some times. - * - * @author gideon - */ -public class Issue27 extends Example { - - public static void main(String... args) throws Exception { - Issue27 ex = new Issue27(); - ex.connect(); - ex.con.setTimeout(2000); - ex.test2(); - ex.test1(); - Thread.sleep(60000); - for (String tag : ex.tags) { - ex.con.cancel(tag); - } - ex.disconnect(); - } - - private void test1() throws MikrotikApiException { - String tag = con.execute("/interface/pppoe-server/server/listen return .id,.dead,disabled,service-name,interface,max-mtu,max-mru,mrru,default-profile,authentication", new ResultListener() { - @Override - public void receive(Map result) { - System.out.println(result); - } - - @Override - public void error(MikrotikApiException ex) { - System.out.println(ex); - } - - @Override - public void completed() { - } - }); - tags.add(tag); - } - - private void test2() throws MikrotikApiException { - String tag = con.execute("/interface/listen where type=l2tp-in or type=l2tp-out or type=ovpn-in or type=ovpn-out or type=ppp-in or type=ppp-out or type=pppoe-in or type=pppoe-out or type=pptp-in or type=pptp-out or type=sstp-in or type=sstp-out return .id,.dead,.nextid,disabled,dynamic,running,slave,name,type,comment", new ResultListener() { - @Override - public void receive(Map result) { - System.out.println(result); - } - - @Override - public void error(MikrotikApiException ex) { - System.out.println(ex); - } - - @Override - public void completed() { - } - }); - tags.add(tag); - } - - List tags = new ArrayList<>(); - -}