src/main/java/Alergia.java
private void insertInLexMinSort(List<FptaNode> redList, FptaNode blue){
        int index = 0;
        int bluePrefixSize = blue.getPrefix().size();
        for (FptaNode r : redList){
            if(r.getPrefix().size() < bluePrefixSize){
                index += 1;
            }else{
                break;
            }
        }
        redList.add(index, blue);
    }
/**
     * Insert blue in redList while preserving lexicographically minimal order.
     * @param redList list of automaton states/red nodes
     * @param blue blue node
     */
Insert blue in redList while preserving lexicographically minimal order.
@param redList list of automaton states/red nodes
@param blue blue node
Insert blue in redList while preserving lexicographically minimal order . @param redList list of automaton states / red nodes @param blue blue node
private void insertInLexMinSort(List<FptaNode> redList, FptaNode blue){
        int index = 0;
        int bluePrefixSize = blue.getPrefix().size();
        for (FptaNode r : redList){
            if(r.getPrefix().size() < bluePrefixSize){
                index += 1;
            }else{
                break;
            }
        }
        redList.add(index, blue);
    }
private void insertInLexMinSort ( List < FptaNode > redList , FptaNode blue ) { int index = 0 ; int bluePrefixSize = blue . getPrefix ( ) . size ( ) ; for ( FptaNode r : redList ) { if ( r . getPrefix ( ) . size ( ) < bluePrefixSize ) { index += 1 ; } else { break ; } } redList . add ( index , blue ) ; }
Insert blue in redList while preserving lexicographically minimal order.
Insert blue in redList while preserving lexicographically minimal order .