import java.math.BigInteger;
import java.security.SecureRandom
import gnu.getopt.Getopt;


public class RSA_skeleton {

    public static void main(String[] args){

        StringBuilder bitSizeStr = new StringBuilder();
        StringBuilder nStr = new StringBuilder();
        StringBuilder dStr = new StringBuilder();
        StringBuilder eStr = new StringBuilder();
        StringBuilder m = new StringBuilder();

        pcl(args, bitSizeStr, nStr, dStr, eStr,m);

        if(!bitSizeStr.toString().equalsIgnoreCase("")){
            //This means you want to create a new key
            genRSAkey(bitSizeStr);
        }

        if(!eStr.toString().equalsIgnoreCase("")){
            RSAencrypt(m, nStr, eStr);
        }

        if(!dStr.toString().equalsIgnoreCase("")){
            RSAdecrypt(m, nStr, dStr);
        }


    }



    private static void RSAencrypt(StringBuilder m, StringBuilder nStr, StringBuilder eStr) {
        // TODO Auto-generated method stub
    }

    private static void RSAdecrypt(StringBuilder cStr, StringBuilder nStr,
            StringBuilder dStr){
        // TODO Auto-generated method stub
    }

    private static void genRSAkey(StringBuilder bitSizeStr) {
        // TODO Auto-generated method stub
    }


    /**
     * This function Processes the Command Line Arguments.
     */
    private static void pcl(String[] args, StringBuilder bitSizeStr,
            StringBuilder nStr, StringBuilder dStr, StringBuilder eStr,
            StringBuilder m) {
        /*
         * http://www.urbanophile.com/arenn/hacking/getopt/gnu.getopt.Getopt.html
         */
        Getopt g = new Getopt("Chat Program", args, "hke:d:b:n:i:");
        int c;
        String arg;
        while ((c = g.getopt()) != -1){
            switch(c){
                case 'i':
                    arg = g.getOptarg();
                    m.append(arg);
                    break;
                case 'e':
                    arg = g.getOptarg();
                    eStr.append(arg);
                    break;
                case 'n':
                    arg = g.getOptarg();
                    nStr.append(arg);
                    break;
                case 'd':
                    arg = g.getOptarg();
                    dStr.append(arg);
                    break;
                case 'k':
                    break;
                case 'b':
                    arg = g.getOptarg();
                    bitSizeStr.append(arg);
                    break;
                case 'h':
                    callUsage(0);
                case '?':
                    break; // getopt() already printed an error
                default:
                    break;
            }
        }
    }

    private static void callUsage(int exitStatus) {

        String useage = "";

        System.err.println(useage);
        System.exit(exitStatus);

    }


}

@@ -55,16 +55,17 @@
 reRandom
+;
 %0Aimport 
@@ -105,18 +105,8 @@
  RSA
-_skeleton 
 %7B%0A%0A 
@@ -149,16 +149,66 @@
 args)%7B%0A%0A
+        StringBuilder kStr = new StringBuilder();%0A
         
@@ -470,16 +470,22 @@
 cl(args,
+ kStr,
  bitSize
@@ -526,16 +526,9 @@
  if(
-!bitSize
+k
 Str.
@@ -548,35 +548,37 @@
 ualsIgnoreCase(%22
+k
 %22))
+ 
 %7B%0A            //
@@ -579,84 +579,192 @@
     
-//This means you want to create a new key%0A            genRSAkey(bitSizeStr);
+if(!bitSizeStr.toString().equalsIgnoreCase(%22%22))%7B%0A                genRSAkey(Integer.parseInt(bitSizeStr.toString()));%0A            %7D else %7B%0A                genRSAkey(1024);%0A            %7D
 %0A   
@@ -1319,37 +1319,27 @@
 nRSAkey(
-StringBuilder
+int
  bitSize
 Str) %7B%0A 
@@ -1330,19 +1330,16 @@
  bitSize
-Str
 ) %7B%0A    
@@ -1373,24 +1373,105 @@
 method stub%0A
+        System.out.println(%22generate key%22);%0A        System.out.println(bitSize);%0A
     %7D%0A%0A%0A    
@@ -1583,16 +1583,48 @@
 %5B%5D args,
+ StringBuilder kStr,%0A           
  StringB
@@ -2568,16 +2568,54 @@
 se 'k':%0A
+                    kStr.append('k');%0A
         

update parameter parsing