private void setupTerminals(HashMap<String, Object[]> terminalsMap) {

        String termname = "";
        String termclass = "";
        Terminal term = null;
        Object[] entry = null;

        for (Iterator<String> iter = terminalsMap.keySet().iterator(); iter.hasNext();) {
            try {
                // first we get the name
                termname = iter.next();

                // then the entry
                entry = terminalsMap.get(termname);

                // then the fully qualified class string
                termclass = (String) entry[0];
                log.debug("Preparing terminal [" + termname + "] " + termclass);

                // get a new class object instance (e.g. load class and instantiate it)
                term = (Terminal) Class.forName(termclass).newInstance();

                // and put an instance + references into myTerminals
                terminals.put(termname, term);
                String[] aliases = (String[]) entry[1];
                for (int i = 0; i < aliases.length; i++) {
                    // without overwriting existing !!!
                    if (!terminals.containsKey(aliases[i])) {
                        terminals.put(aliases[i], term);
                    }
                }

            } catch (Exception e) {
                log.error("setupTerminals()", e);
            }

        }
        // check if we got all
        log.debug("Terminals:");
        for (Iterator<String> iter = terminals.keySet().iterator(); iter.hasNext();) {
            String tn = iter.next();
            log.debug(tn + "=" + terminals.get(tn));
        }
    }// setupTerminals