Package org.jab.docsearch.utils

Examples of org.jab.docsearch.utils.DocTypeHandler


            NewHandlerDialog nhd = new NewHandlerDialog(monitor, NEW_HANDLER, true);
            nhd.init();
            nhd.setVisible(true);
            if (nhd.returnBool) {
                //
                DocTypeHandler dh = new DocTypeHandler(nhd.extField.getText(), nhd.descField.getText(), nhd.appField.getText());
                monitor.handlerList.add(dh);
                setList();
            }
        } // end for adding a handler
        else if (s.equals(REMOVE)) {
            int chosen = handlerList.getSelectedIndex();
            if (chosen != -1) {
                removeItemAt(chosen);
                monitor.handlerList.remove(chosen);
                setList();
            }
        } // end for adding a handler
        else if (s.equals(EDIT)) {
            int chosen = handlerList.getSelectedIndex();
            if (chosen != -1) {
                //
                NewHandlerDialog nhd = new NewHandlerDialog(monitor, EDIT_HANDLER, true);
                // set the values of the selected item
                nhd.init();
                nhd.setDTH(monitor.handlerList.get(chosen));
                nhd.setVisible(true);
                if (nhd.returnBool) {
                    DocTypeHandler dh = monitor.handlerList.get(chosen);
                    dh = new DocTypeHandler(nhd.extField.getText(), nhd.descField.getText(), nhd.appField.getText());
                    monitor.handlerList.set(chosen, dh);
                    setList();
                }
            } // end for item chosen
        } // end for editing a handler
View Full Code Here


        if (numHndlrs > 0) {
            String listItems[] = new String[numHndlrs];
            Iterator<DocTypeHandler> it = monitor.handlerList.iterator();
            int curI = 0;
            while (it.hasNext()) {
                DocTypeHandler dh = it.next();
                listItems[curI] = dh.descName();
                curI++;
            }
            handlerList.setListData(listItems);
        }
    } // end for setlist
View Full Code Here

TOP

Related Classes of org.jab.docsearch.utils.DocTypeHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.