Package org.eclipse.ui.progress

Examples of org.eclipse.ui.progress.IProgressService.run()


    public boolean executeCreateOperation() {
        ComponentCreateOperation createComponent = new ComponentCreateOperation(getComponentController(), this);
        try {
            IProgressService service = PlatformUI.getWorkbench().getProgressService();
            service.run(false, true, createComponent);
            return true;
        } catch (InterruptedException e) {
            return false;
        } catch (Exception e) {
            logger.error("Unable to create " + getComponentType(), e);
View Full Code Here


    }

    private void refreshProject(final RefreshResourceAction action) throws InvocationTargetException,
            InterruptedException {
        final IProgressService service = PlatformUI.getWorkbench().getProgressService();
        service.run(false, false, new IRunnableWithProgress() {
            public void run(final IProgressMonitor monitor) throws InvocationTargetException {
                monitor.beginTask("Refreshing project...", IProgressMonitor.UNKNOWN);
                try {
                    action.run(null);
                } catch (Throwable e) {
View Full Code Here

            }
        };

        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        try {
            service.run(true, true, saveToServerRunnable);
        } catch (InterruptedException e) {
            logger.warn("Operation cancelled: " + e.getMessage());
        } catch (InvocationTargetException e) {
            Throwable cause = e.getTargetException();
            if (cause instanceof InsufficientPermissionsException) {
View Full Code Here

                .getString("RunTestsAction.CannotOpenRunTestsView.error"));
        }

        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        try {
            service.run(false, false, new IRunnableWithProgress() {
                @Override
                public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
                    if (monitor != null) {
                        monitor.beginTask("Run Test for '" + getSelectedResource().getName() + "'", 2);
                    }
View Full Code Here

    // U T I L I T I E S
    protected boolean testConnection(final Controller controller, final ForceProject forceProject)
            throws InvocationTargetException {
        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        try {
            service.run(false, false, new IRunnableWithProgress() {
                public void run(IProgressMonitor monitor) throws InvocationTargetException {
                    monitor.beginTask("Validating connection", 2);
                    monitor.worked(1);
                    try {
                        ContainerDelegate.getInstance().getServiceLocator().getProjectService().getConnectionFactory().getConnection(forceProject);
View Full Code Here

        }
    }

    private void prepareSyncParticipant() throws InvocationTargetException, InterruptedException {
        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        service.run(true, true, new IRunnableWithProgress() {
            @Override
            public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
                monitor.beginTask("Preparing and evaluating Synchronize results", 3);
                try {
                    if (syncParticipant == null) {
View Full Code Here

            }
        };

        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        try {
            service.run(false, true, applyNatureOperation);
        } catch (InterruptedException e) {
            logger.warn("Operation cancelled: " + e.getMessage());
        } catch (InvocationTargetException e) {
            logger.error("Unable to apply Force.com Online Nature to project '" + project.getName() + "'.",
                ForceExceptionUtils.getRootCause(e));
View Full Code Here

    }

    private void deploy() throws InvocationTargetException {
        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        try {
            service.run(true, true, new IRunnableWithProgress() {
                @Override
                public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
                    monitor.beginTask("Deploying components...", 1);
                    try {
                        deploymentWizard.getDeploymentController().finish(new SubProgressMonitor(monitor, 3));
View Full Code Here

        return true;
    }

    protected void syncCheckWork() throws InvocationTargetException, InterruptedException {
        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        service.run(true, true, new IRunnableWithProgress() {
            @Override
            public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
                monitor.beginTask("Synchronize check against server", 2);
                try {
                    monitorWork(monitor);
View Full Code Here

    }

    protected void fetchRemoteComponents() {
        IProgressService service = PlatformUI.getWorkbench().getProgressService();
        try {
            service.run(true, true, new WorkspaceModifyOperation() {
                @Override
                protected void execute(IProgressMonitor monitor) throws CoreException, InvocationTargetException,
                InterruptedException {
                    if(monitor==null){
                        monitor= new NullProgressMonitor();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.