1212import com .mobilebox .repl .commands .IOSCommands ;
1313
1414/**
15- * This class acts as entry point to JavaREPL also provides commands that
16- * basically are wrappers over some Appium methods such as find an element, get
17- * source, etc.
15+ * This class acts as entry point to JavaREPL also provides commands that basically are wrappers
16+ * over some Appium methods such as find an element, get source, etc.
1817 *
1918 * @see <a href="https://github.com/albertlatacz/java-repl">JavaREPL</a>
2019 *
2120 */
2221public class Appium {
2322
24- public static AndroidCommands android ;
25- public static IOSCommands ios ;
26-
27- static {
28- android = new AndroidCommands ();
29- ios = new IOSCommands ();
30- }
31-
32- public static void main (String ... args ) throws Exception {
33- welcome ();
34- Main .main (args );
35- }
23+ public static AndroidCommands android ;
24+ public static IOSCommands ios ;
3625
37- private static void welcome (){
38- console ("----------------------------" );
39- console (" :::- Appium Java REPL -::: " + SEPARATOR );
40- console ("Type import static com.mobilebox.repl.Appium.*;" + SEPARATOR );
41- console ("Type help() for more options." );
42- console ("-----------------------------" + SEPARATOR );
43- }
44-
45- @ CommandRef (desc = "Prints this help." )
46- public static void help () {
47- printCommands (Appium .class );
48- }
49-
50- @ CommandRef (desc = "Quit Appium REPL" )
51- public static void exit () {
52- System .exit (0 );
53- }
54-
55- @ CommandRef (desc = "Prints all commands available for Android and iOS." )
56- public static void commands_appium () {
57- printCommands (AppiumCommands .class );
58- }
26+ static {
27+ android = new AndroidCommands ();
28+ ios = new IOSCommands ();
29+ }
5930
60- @ CommandRef ( desc = "Prints all commands available especifc for Android." )
61- public static void commands_android () {
62- printCommands ( AndroidCommands . class );
63- }
31+ public static void main ( String ... args ) throws Exception {
32+ welcome ();
33+ Main . main ( args );
34+ }
6435
65- @ CommandRef (desc = "Prints all commands available for iOS." )
66- public static void commands_ios () {
67- printCommands (IOSCommands .class );
68- }
69-
70- @ CommandRef (desc = "Prints all commands available for Android Device." )
71- public static void commands_android_device () {
72- printCommands (AndroidDeviceCommands .class );
73- }
74-
75- }
36+ private static void welcome () {
37+ console ("----------------------------" );
38+ console (" :::- Appium Java REPL -::: " + SEPARATOR );
39+ console ("Type import static com.mobilebox.repl.Appium.*;" + SEPARATOR );
40+ console ("Type help() for more options." );
41+ console ("-----------------------------" + SEPARATOR );
42+ }
43+
44+ @ CommandRef (desc = "Prints this help." )
45+ public static void help () {
46+ printCommands (Appium .class );
47+ }
48+
49+ @ CommandRef (desc = "Quit Appium REPL" )
50+ public static void exit () {
51+ System .exit (0 );
52+ }
53+
54+ @ CommandRef (desc = "Prints all commands available for Android and iOS." )
55+ public static void commands_appium () {
56+ printCommands (AppiumCommands .class );
57+ }
58+
59+ @ CommandRef (desc = "Prints all commands available especifc for Android." )
60+ public static void commands_android () {
61+ printCommands (AndroidCommands .class );
62+ }
63+
64+ @ CommandRef (desc = "Prints all commands available for iOS." )
65+ public static void commands_ios () {
66+ printCommands (IOSCommands .class );
67+ }
68+
69+ @ CommandRef (desc = "Prints all commands available for Android Device." )
70+ public static void commands_android_device () {
71+ printCommands (AndroidDeviceCommands .class );
72+ }
73+
74+ }
0 commit comments