private void findConnection(int from, int curr, int []conds){
        List<Connection> connections = Application.mediator.automatonTable.connections;
        int [][] trans = Application.mediator.matrix.transitions;
        for (int i = 0; i < trans[curr].length; i++) {
            
            if(trans[curr][i] > 0){
                if (posToZid[curr] < 0){
                    int index = Math.abs(posToZid[curr]) - 1;
                    conds[index] = trans[curr][i];
                }
                if(posToZid[i] >= 0){
                    Connection conn = new Connection(posToZid[from], posToZid[i], 
                            conds, Application.mediator.matrix.ids[from]);
                    connections.add(conn);
                    conds = Arrays.copyOf(conds, conds.length);
                    
                }else{
                    findConnection(from, i, Arrays.copyOf(conds, conds.length));
                }
            }
        }

    }