File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -34,13 +34,7 @@ public class Main
3434
3535 public Main ()
3636 {
37- System .out .print ("-\r " );
38-
39- System .out .print ("+\r " );
40-
41- System .out .print ("-\r " );
42-
43- System .out .print ("+\r " );
37+ CommonRails .printSpinner ();
4438
4539 System .out .println ("[ Java National Finance Engine v.28.1.1 Software Processes Starting ]" );
4640
Original file line number Diff line number Diff line change @@ -66,6 +66,33 @@ public static <T> Integer size(ArrayList<T> list)
6666 return list .size ();
6767 }
6868
69+ public static void printSpinner ()
70+ {
71+ for (int i =0 ; i <250 ; i ++)
72+ {
73+ try
74+ {
75+ System .out .print ("- Loading.\r " );
76+
77+ Thread .sleep (500 );
78+
79+ System .out .print ("+ Loading..\r " );
80+
81+ Thread .sleep (500 );
82+
83+ System .out .print ("- Loading...\r " );
84+
85+ Thread .sleep (500 );
86+
87+ System .out .print ("+ Loading\r " );
88+ }
89+ catch (Exception e )
90+ {
91+ e .printStackTrace (System .err );
92+ }
93+ }
94+ }
95+
6996 public static void printSystemComponent (Object object , Integer hashcode , String line )
7097 {
7198 // Build the [Current: ...] field and pad the content inside the brackets to the desired total width
You can’t perform that action at this time.
0 commit comments