Package org.python.pydev.plugin

Examples of org.python.pydev.plugin.StatusInfo


                    if (dialog.open() == Window.OK) {
                        Object firstResult = dialog.getFirstResult();
                        if (firstResult instanceof IProject) {
                            found[0] = firstResult;
                        } else {
                            found[0] = new CoreException(new StatusInfo(IStatus.ERROR,
                                    "Expected project to be selected."));
                        }
                    }
                }
            });
            if (found[0] == null) {
                return null;
            }
            if (found[0] instanceof IProject) {
                project = (IProject) found[0];
            } else {
                if (found[0] instanceof CoreException) {
                    throw (CoreException) found[0];
                } else {
                    throw new CoreException(new StatusInfo(IStatus.ERROR, "Expected project, found: " + found[0]));
                }
            }
        }
        IInterpreterManager pythonInterpreterManager = getInterpreterManager(project);
        String projName = project.getName();
View Full Code Here


            fOverlayStore.setValue((String) fTextFields.get(textControl), number);
        updateStatus(status);
    }

    protected IStatus validatePositiveNumber(String number) {
        StatusInfo status = new StatusInfo();
        if (number.length() == 0) {
            status.setError("empty_input??");
        } else {
            try {
                int value = Integer.parseInt(number);
                if (value < 0)
                    status.setError("invalid_input??");
            } catch (NumberFormatException e) {
                status.setError("invalid_input??");
            }
        }
        return status;
    }
View Full Code Here

        return composite;
    }

    private void doSelectionChanged(Object[] objects) {
        if (objects.length != 1) {
            updateStatus(new StatusInfo(IStatus.ERROR, "")); //$NON-NLS-1$
            setSelectionResult(null);
        } else {
            updateStatus(new StatusInfo());
            setSelectionResult(objects);
        }
    }
View Full Code Here

TOP

Related Classes of org.python.pydev.plugin.StatusInfo

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.