public void addProduction( String nonTerminal, String rightHandSide ) {
        RightHandSide rightHandSideArray = new RightHandSide(); // Create new right hand side
        for( int i = 0; i < rightHandSide.length(); i++ ) { // Read the string
            int strStart = 0;
            switch ( rightHandSide.charAt( i ) ) {
                case '`': // If there is apostrophe in string
                    strStart = i;
                    i++;
                    while ( rightHandSide.charAt( i ) != '`' || rightHandSide.charAt( i - 1 ) == '\\' ) { // Extract what's between apostrophes
                        i++;
                    }
                    rightHandSideArray.add( getTerminal( rightHandSide.substring( strStart + 1, i ) ) ); // Add extracted to right hand side
                    break;
                case '~':
                    strStart = i;
                    i++;
                    while ( rightHandSide.charAt( i ) != '~' ) { // Extract what's between tildes
                        i++;
                    }
                    rightHandSideArray.add( getNonTerminal( rightHandSide.substring( strStart + 1, i ) ) ); // Add extracted to right hand side
                    break;
            }
        }
        if( !productions.containsKey( getNonTerminal( nonTerminal ) ) ) { // Add right hand side to non-Terminal rhs set
            HashSet<RightHandSide> tempSet = new HashSet<RightHandSide>();
            tempSet.add( rightHandSideArray );
            productions.put( getNonTerminal( nonTerminal ), tempSet );
        } else {
            productions.get( getNonTerminal( nonTerminal ) ).add( rightHandSideArray );
        }
    }