public static synchronized boolean createGrammarWithOutProbability(String text){
        // If the text is null then return
        if(text == null){
            System.out.println("Text to create grammar is null!");
            return false;
        }
        // Only leave text and numbers
        text = FileUtils.getTextAndDigits(text);

        // Create the body of the Grammar
        String grammar = "#JSGF V1.0" + EnvironmentUtils.NEW_LINE + EnvironmentUtils.NEW_LINE +
                "grammar " + SpeechManager.GRAMMAR + ";" + EnvironmentUtils.NEW_LINE + EnvironmentUtils.NEW_LINE;

        int counter = 0;

        for(String line : text.split("\n")){
            line = line.trim();
            if(!line.isEmpty()){
                grammar += "public <line_" + (++counter) + "> = " + line.trim() + ";" + EnvironmentUtils.NEW_LINE + EnvironmentUtils.NEW_LINE;
            }
        }

        try{
            // If the temp file does not exists then create it
            File temp = new File(SpeechManager.DIRECTORY);

            if(!temp.exists()){
                if(!temp.mkdir()){ throw new IOException("[" + SpeechManager.DIRECTORY + "] directory cannot be created!"); }
                // If this method creates this directory then ensure to delete it when exiting the JVM
                else{ temp.deleteOnExit(); }
            }

            // Write grammar into a document
            File file = new File(SpeechManager.DIRECTORY + EnvironmentUtils.SEPARATOR + SpeechManager.GRAMMAR_FILE);

            // Delete this file when exiting the JVM
            file.deleteOnExit();

            BufferedWriter bw = new BufferedWriter(new FileWriter(file.getAbsoluteFile()));
            bw.write(grammar);
            bw.close();
        }catch(Exception e){
            e.printStackTrace();
            return false;
        }
        // The Grammar was successfully created
        return true;
    }