![]() |
![]() |
org.eclipse.team.ui_3.6.101.R37x_v20111109-0800itor) throws CoreException { // Byte code: // 0: aload_0 // 1: invokevirtual 238 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:isDirty ()Z // 4: ifeq +133 -> 137 // 7: aload_0 // 8: invokevirtual 237 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:isConnected ()Z // 11: ifeq +13 -> 24 // 14: aload_0 // 15: iconst_1 // 16: aload_1 // 17: invokevirtual 243 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:saveDocument (ZLorg/eclipse/core/runtime/IProgressMonitor;)Z // 20: pop // 21: goto +116 -> 137 // 24: aload_0 // 25: invokevirtual 242 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:getResource ()Lorg/eclipse/core/resources/IResource; // 28: astore_2 // 29: aload_2 // 30: instanceof 109 // 33: ifeq +100 -> 133 // 36: new 101 java/io/ByteArrayInputStream // 39: dup // 40: aload_0 // 41: invokevirtual 240 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:getContent ()[B // 44: invokespecial 215 java/io/ByteArrayInputStream:<init> ([B)V // 47: astore_3 // 48: aload_2 // 49: checkcast 109 org/eclipse/core/resources/IFile // 52: astore 4 // 54: aload 4 // 56: invokeinterface 245 1 0 // 61: ifeq +17 -> 78 // 64: aload 4 // 66: aload_3 // 67: iconst_0 // 68: iconst_1 // 69: aload_1 // 70: invokeinterface 247 5 0 // 75: goto +13 -> 88 // 78: aload 4 // 80: aload_3 // 81: iconst_0 // 82: aload_1 // 83: invokeinterface 246 4 0 // 88: aload_0 // 89: iconst_0 // 90: putfield 208 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:fDirty Z // 93: goto +24 -> 117 // 96: astore 5 // 98: aload_0 // 99: invokevirtual 235 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:fireContentChanged ()V // 102: aload_3 // 103: ifnull +11 -> 114 // 106: aload_3 // 107: invokevirtual 214 java/io/ByteArrayInputStream:close ()V // 110: goto +4 -> 114 // 113: pop // 114: aload 5 // 116: athrow // 117: aload_0 // 118: invokevirtual 235 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:fireContentChanged ()V // 121: aload_3 // 122: ifnull +11 -> 133 // 125: aload_3 // 126: invokevirtual 214 java/io/ByteArrayInputStream:close ()V // 129: goto +4 -> 133 // 132: pop // 133: aload_0 // 134: invokevirtual 236 org/eclipse/team/internal/ui/synchronize/LocalResourceTypedElement:updateTimestamp ()V // 137: return // Line number table: // Java source line #86 -> byte code offset #0 // Java source line #87 -> byte code offset #7 // Java source line #88 -> byte code offset #14 // Java source line #90 -> byte code offset #24 // Java source line #91 -> byte code offset #29 // Java source line #92 -> byte code offset #36 // Java source line #94 -> byte code offset #48 // Java source line #95 -> byte code offset #54 // Java source line #96 -> byte code offset #64 // Java source line #98 -> byte code offset #78 // Java source line #99 -> byte code offset #88 // Java source line #100 -> byte code offset #96 // Java source line #101 -> byte code offset #98 // Java source line #102 -> byte code offset #102 // Java source line #104 -> byte code offset #106 // Java source line #105 -> byte code offset #113 // Java source line #107 -> byte code offset #114 // Java source line #101 -> byte code offset #117 // Java source line #102 -> byte code offset #121 // Java source line #104 -> byte code offset #125 // Java source line #105 -> byte code offset #132 // Java source line #109 -> byte code offset #133 // Java source line #112 -> byte code offset #137 // Local variable table: // start length slot name signature // 0 138 0 this LocalResourceTypedElement // 0 138 1 monitor IProgressMonitor // 28 21 2 resource IResource // 47 79 3 is java.io.ByteArrayInputStream // 52 27 4 file org.eclipse.core.resources.IFile // 96 19 5 localObject Object // 113 1 6 localIOException1 java.io.IOException // 132 1 7 localIOException2 java.io.IOException // Exception table: // from to target type // 48 96 96 finally // 106 110 113 java/io/IOException // 125 129 132 java/io/IOException } public InputStream getContents() throws CoreException { if (exists) { return super.getContents(); } return null; } public Object getAdapter(Class adapter) { if (adapter == ISharedDocumentAdapter.class) { if (isSharedDocumentsEnable()) { return getSharedDocumentAdapter(); } return null; } return Platform.getAdapterManager().getAdapter(this, adapter); } private synchronized ISharedDocumentAdapter getSharedDocumentAdapter() { if (sharedDocumentAdapter == null) { sharedDocumentAdapter = new EditableSharedDocumentAdapter(new EditableSharedDocumentAdapter.ISharedDocumentAdapterListener() { public void handleDocumentConnected() { updateTimestamp(); if (sharedDocumentListener != null) { sharedDocumentListener.handleDocumentConnected(); } } public void handleDocumentFlushed() { fireContentChanged(); if (sharedDocumentListener != null) { sharedDocumentListener.handleDocumentFlushed(); } } public void handleDocumentDeleted() { update(); if (sharedDocumentListener != null) { sharedDocumentListener.handleDocumentDeleted(); } } public void handleDocumentSaved() { updateTimestamp(); if (sharedDocumentListener != null) { sharedDocumentListener.handleDocumentSaved(); } } public void handleDocumentDisconnected() { if (sharedDocumentListener != null) { sharedDocumentListener.handleDocumentDisconnected(); } } }); } return sharedDocumentAdapter; } public boolean isEditable() { IResource resource = getResource(); return (resource.getType() == 1) && (exists); } public boolean isConnected() { return (sharedDocumentAdapter != null) && (sharedDocumentAdapter.isConnected()); } public boolean saveDocument(boolean overwrite, IProgressMonitor monitor) throws CoreException { if (isConnected()) { IEditorInput input = sharedDocumentAdapter.getDocumentKey(this); sharedDocumentAdapter.saveDocument(input, overwrite, monitor); updateTimestamp(); return true; } return false; } protected InputStream createStream() throws CoreException { InputStream inputStream = super.createStream(); updateTimestamp(); return inputStream; } void updateTimestamp() { if (getResource().exists()) { timestamp = getResource().getLocalTimeStamp(); } else { exists = false; } } private long getTimestamp() { return timestamp; } public int hashCode() { return getResource().hashCode(); } public boolean equals(Object obj) { if (obj == this) { return true; } if ((obj instanceof LocalResourceTypedElement)) { LocalResourceTypedElement otherElement = (LocalResourceTypedElement)obj; return (otherElement.getResource().equals(getResource())) && (exists == exists); } return false; } public void update() { exists = getResource().exists(); } public boolean isSynchronized() { long current = getResource().getLocalTimeStamp(); return current == getTimestamp(); } public boolean exists() { return exists; } protected void fireContentChanged() { super.fireContentChanged(); } public void discardBuffer() { if (sharedDocumentAdapter != null) { sharedDocumentAdapter.releaseBuffer(); } super.discardBuffer(); } public boolean isSharedDocumentsEnable() { return (useSharedDocument) && (getResource().getType() == 1) && (exists); } public void enableSharedDocument(boolean enablement) { useSharedDocument = enablement; } public boolean isDirty() { return (fDirty) || ((sharedDocumentAdapter != null) && (sharedDocumentAdapter.hasBufferedContents())); } public void setSharedDocumentListener(EditableSharedDocumentAdapter.ISharedDocumentAdapterListener sharedDocumentListener) { this.sharedDocumentListener = sharedDocumentListener; } public String getAuthor() { return author; } public void fetchAuthor(IProgressMonitor monitor) throws CoreException { author = null; IFileHistoryProvider fileHistoryProvider = Utils.getHistoryProvider(getResource()); if (fileHistoryProvider == null) { return; } IFileRevision revision = fileHistoryProvider.getWorkspaceFileRevision(getResource()); if (revision == null) { return; } revision = revision.withAllProperties(monitor); author = revision.getAuthor(); } public void setAuthor(String author) { this.author = author; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.LocalResourceTypedElement * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.jface.viewers.IColorDecorator; import org.eclipse.jface.viewers.IFontDecorator; import org.eclipse.jface.viewers.ILabelDecorator; import org.eclipse.jface.viewers.LabelProvider; import org.eclipse.swt.graphics.Color; import org.eclipse.swt.graphics.Font; import org.eclipse.swt.graphics.Image; class MultiLabelDecorator extends LabelProvider implements ILabelDecorator, IFontDecorator, IColorDecorator { private ILabelDecorator[] decorators; public MultiLabelDecorator(ILabelDecorator[] decorators) { this.decorators = decorators; } public Image decorateImage(Image image, Object element) { for (int i = 0; i < decorators.length; i++) { ILabelDecorator decorator = decorators[i]; Image newImage = decorator.decorateImage(image, element); if (newImage != null) { image = newImage; } } return image; } public String decorateText(String text, Object element) { for (int i = 0; i < decorators.length; i++) { ILabelDecorator decorator = decorators[i]; String newText = decorator.decorateText(text, element); if (newText != null) { text = newText; } } return text; } public void dispose() { for (int i = 0; i < decorators.length; i++) { ILabelDecorator d = decorators[i]; d.dispose(); } } public Font decorateFont(Object element) { for (int i = 0; i < decorators.length; i++) { ILabelDecorator decorator = decorators[i]; if ((decorator instanceof IFontDecorator)) { return ((IFontDecorator)decorator).decorateFont(element); } } return null; } public Color decorateForeground(Object element) { for (int i = 0; i < decorators.length; i++) { ILabelDecorator decorator = decorators[i]; if ((decorator instanceof IColorDecorator)) { return ((IColorDecorator)decorator).decorateForeground(element); } } return null; } public Color decorateBackground(Object element) { for (int i = 0; i < decorators.length; i++) { ILabelDecorator decorator = decorators[i]; if ((decorator instanceof IColorDecorator)) { return ((IColorDecorator)decorator).decorateBackground(element); } } return null; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.MultiLabelDecorator * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.jface.action.Action; import org.eclipse.jface.viewers.AbstractTreeViewer; import org.eclipse.jface.viewers.Viewer; import org.eclipse.swt.widgets.Control; class NavigationActionGroup$1 extends Action { final NavigationActionGroup this$0; private final Viewer val$viewer; NavigationActionGroup$1(NavigationActionGroup paramNavigationActionGroup, Viewer paramViewer) { this$0 = paramNavigationActionGroup;val$viewer = paramViewer; } public void run() { if ((val$viewer.getControl().isDisposed()) || (!(val$viewer instanceof AbstractTreeViewer))) { return; } val$viewer.getControl().setRedraw(false); ((AbstractTreeViewer)val$viewer).collapseToLevel(val$viewer.getInput(), -1); val$viewer.getControl().setRedraw(true); } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.NavigationActionGroup.1 * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.compare.ICompareNavigator; import org.eclipse.jface.action.Action; import org.eclipse.jface.action.IMenuManager; import org.eclipse.jface.action.IToolBarManager; import org.eclipse.jface.viewers.AbstractTreeViewer; import org.eclipse.jface.viewers.Viewer; import org.eclipse.swt.widgets.Control; import org.eclipse.team.internal.ui.Utils; import org.eclipse.team.internal.ui.synchronize.actions.ExpandAllAction; import org.eclipse.team.internal.ui.synchronize.actions.NavigateAction; import org.eclipse.team.ui.synchronize.ISynchronizePage; import org.eclipse.team.ui.synchronize.ISynchronizePageConfiguration; import org.eclipse.team.ui.synchronize.SynchronizePageActionGroup; import org.eclipse.ui.IActionBars; public class NavigationActionGroup extends SynchronizePageActionGroup { private ExpandAllAction expandAllAction; private Action collapseAll; private NavigateAction gotoNext; private NavigateAction gotoPrevious; public void initialize(ISynchronizePageConfiguration configuration) { super.initialize(configuration); Viewer viewer = configuration.getPage().getViewer(); if ((viewer instanceof AbstractTreeViewer)) { expandAllAction = new ExpandAllAction((AbstractTreeViewer)viewer); Utils.initAction(expandAllAction, "action.expandAll."); collapseAll = new Action() { private final Viewer val$viewer; public void run() { if ((val$viewer.getControl().isDisposed()) || (!(val$viewer instanceof AbstractTreeViewer))) { return; } val$viewer.getControl().setRedraw(false); ((AbstractTreeViewer)val$viewer).collapseToLevel(val$viewer.getInput(), -1); val$viewer.getControl().setRedraw(true); } }; Utils.initAction(collapseAll, "action.collapseAll."); ICompareNavigator nav = (ICompareNavigator)configuration.getProperty("org.eclipse.team.ui.P_NAVIGATOR"); if (nav != null) { gotoNext = new NavigateAction(configuration, true); gotoPrevious = new NavigateAction(configuration, false); } } } public void fillContextMenu(IMenuManager manager) { if ((manager == null) || (expandAllAction == null)) { return; } if (manager.find("org.eclipse.team.internal.ui.RemoveFromView") != null) { manager.insertBefore("org.eclipse.team.internal.ui.RemoveFromView", expandAllAction); } else { appendToGroup(manager, "navigate", expandAllAction); } } public void fillActionBars(IActionBars actionBars) { IToolBarManager manager = actionBars.getToolBarManager(); appendToGroup(manager, "navigate", collapseAll); if (gotoNext != null) { appendToGroup(manager, "navigate", gotoNext); } if (gotoPrevious != null) { appendToGroup(manager, "navigate", gotoPrevious); } } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.NavigationActionGroup * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import java.util.ArrayList; import java.util.Iterator; import java.util.List; import org.eclipse.core.resources.IResource; import org.eclipse.team.core.subscribers.ISubscriberChangeEvent; import org.eclipse.team.core.subscribers.ISubscriberChangeListener; import org.eclipse.team.core.subscribers.Subscriber; import org.eclipse.team.core.synchronize.SyncInfo; import org.eclipse.team.core.synchronize.SyncInfoSet; import org.eclipse.team.core.variants.IResourceVariantComparator; import org.eclipse.team.internal.core.subscribers.SubscriberSyncInfoCollector; public class RefreshChangeListener implements ISubscriberChangeListener, RefreshParticipantJob.IChangeDescription { private List changes = new ArrayList(); private SubscriberSyncInfoCollector collector; private IResource[] resources; public RefreshChangeListener(IResource[] resources, SubscriberSyncInfoCollector collector) { this.resources = resources; this.collector = collector; } public void subscriberResourceChanged(ISubscriberChangeEvent[] deltas) { for (int i = 0; i < deltas.length; i++) { ISubscriberChangeEvent delta = deltas[i]; if (delta.getFlags() == 1) { changes.add(delta); } } } public SyncInfo[] getChanges() { List changedSyncInfos = new ArrayList(); SyncInfoSet set = collector.getSyncInfoSet(); for (Iterator it = changes.iterator(); it.hasNext();) { ISubscriberChangeEvent delta = (ISubscriberChangeEvent)it.next(); SyncInfo info = set.getSyncInfo(delta.getResource()); if ((info != null) && (interestingChange(info))) { changedSyncInfos.add(info); } } return (SyncInfo[])changedSyncInfos.toArray(new SyncInfo[changedSyncInfos.size()]); } private boolean interestingChange(SyncInfo info) { int kind = info.getKind(); if (isThreeWay()) { int direction = SyncInfo.getDirection(kind); return (direction == 8) || (direction == 12); } return SyncInfo.getChange(kind) != 0; } private boolean isThreeWay() { return collector.getSubscriber().getResourceComparator().isThreeWay(); } public int getChangeCount() { return getChanges().length; } public IResource[] getResources() { return resources; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshChangeListener * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.core.runtime.IStatus; import org.eclipse.team.core.synchronize.SyncInfo; import org.eclipse.team.ui.synchronize.ISynchronizeParticipant; public class RefreshEvent implements IRefreshEvent { int type; SyncInfo[] changes; long startTime = 0L; long stopTime = 0L; IStatus status; private final ISynchronizeParticipant participant; private final RefreshParticipantJob.IChangeDescription description; private boolean isLink; public RefreshEvent(int type, ISynchronizeParticipant participant, RefreshParticipantJob.IChangeDescription description) { this.type = type; this.participant = participant; this.description = description; } public int getRefreshType() { return type; } public long getStartTime() { return startTime; } public void setStartTime(long startTime) { this.startTime = startTime; } public long getStopTime() { return stopTime; } public void setStopTime(long stopTime) { this.stopTime = stopTime; } public IStatus getStatus() { return status; } public void setStatus(IStatus status) { this.status = status; } public ISynchronizeParticipant getParticipant() { return participant; } public RefreshParticipantJob.IChangeDescription getChangeDescription() { return description; } public boolean isLink() { return isLink; } public void setIsLink(boolean isLink) { this.isLink = isLink; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshEvent * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import java.util.HashMap; import java.util.Map; import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.team.core.diff.IDiff; import org.eclipse.team.core.diff.IDiffChangeEvent; import org.eclipse.team.core.diff.IDiffChangeListener; import org.eclipse.team.core.diff.IDiffTree; public class RefreshModelParticipantJob$ChangeDescription implements RefreshParticipantJob.IChangeDescription, IDiffChangeListener { Map changes; final RefreshModelParticipantJob this$0; public RefreshModelParticipantJob$ChangeDescription(RefreshModelParticipantJob paramRefreshModelParticipantJob) { this$0 = paramRefreshModelParticipantJob; changes = new HashMap(); } public int getChangeCount() { return changes.size(); } public void diffsChanged(IDiffChangeEvent event, IProgressMonitor monitor) { IDiff[] additions = event.getAdditions(); for (int i = 0; i < additions.length; i++) { IDiff node = additions[i]; changes.put(node.getPath(), node); } IDiff[] changed = event.getChanges(); for (int i = 0; i < changed.length; i++) { IDiff node = changed[i]; changes.put(node.getPath(), node); } } public void propertyChanged(IDiffTree tree, int property, IPath[] paths) {} } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshModelParticipantJob.ChangeDescription * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import java.util.HashMap; import java.util.Map; import org.eclipse.core.resources.mapping.ResourceMapping; import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IStatus; import org.eclipse.team.core.diff.IDiff; import org.eclipse.team.core.diff.IDiffChangeEvent; import org.eclipse.team.core.diff.IDiffChangeListener; import org.eclipse.team.core.diff.IDiffTree; import org.eclipse.team.core.mapping.IResourceDiffTree; import org.eclipse.team.core.mapping.ISynchronizationContext; import org.eclipse.team.internal.core.mapping.GroupProgressMonitor; import org.eclipse.team.ui.synchronize.ISynchronizeParticipant; import org.eclipse.team.ui.synchronize.ModelSynchronizeParticipant; public class RefreshModelParticipantJob extends RefreshParticipantJob { private final ResourceMapping[] mappings; private IProgressMonitor group; private int groupTicks; public class ChangeDescription implements RefreshParticipantJob.IChangeDescription, IDiffChangeListener { Map changes = new HashMap(); public ChangeDescription() {} public int getChangeCount() { return changes.size(); } public void diffsChanged(IDiffChangeEvent event, IProgressMonitor monitor) { IDiff[] additions = event.getAdditions(); for (int i = 0; i < additions.length; i++) { IDiff node = additions[i]; changes.put(node.getPath(), node); } IDiff[] changed = event.getChanges(); for (int i = 0; i < changed.length; i++) { IDiff node = changed[i]; changes.put(node.getPath(), node); } } public void propertyChanged(IDiffTree tree, int property, IPath[] paths) {} } public RefreshModelParticipantJob(ISynchronizeParticipant participant, String jobName, String taskName, ResourceMapping[] mappings, IRefreshSubscriberListener listener) { super(participant, jobName, taskName, listener); this.mappings = mappings; } /* Error */ protected void doRefresh(RefreshParticipantJob.IChangeDescription changeListener, IProgressMonitor monitor) throws org.eclipse.core.runtime.CoreException { // Byte code: // 0: aload_0 // 1: invokevirtual 114 org/eclipse/team/internal/ui/synchronize/RefreshModelParticipantJob:getParticipant ()Lorg/eclipse/team/ui/synchronize/ISynchronizeParticipant; // 4: checkcast 63 org/eclipse/team/ui/synchronize/ModelSynchronizeParticipant // 7: invokevirtual 120 org/eclipse/team/ui/synchronize/ModelSynchronizeParticipant:getContext ()Lorg/eclipse/team/core/mapping/ISynchronizationContext; // 10: astore_3 // 11: aload_3 // 12: invokeinterface 126 1 0 // 17: aload_1 // 18: checkcast 60 org/eclipse/team/internal/ui/synchronize/RefreshModelParticipantJob$ChangeDescription // 21: invokeinterface 124 2 0 // 26: aload_3 // 27: aload_0 // 28: getfield 110 org/eclipse/team/internal/ui/synchronize/RefreshModelParticipantJob:mappings [Lorg/eclipse/core/resources/mapping/ResourceMapping; // 31: aload_2 // 32: invokeinterface 127 3 0 // 37: invokestatic 112 org/eclipse/core/runtime/jobs/Job:getJobManager ()Lorg/eclipse/core/runtime/jobs/IJobManager; // 40: aload_3 // 41: aload_2 // 42: invokeinterface 121 3 0 // 47: goto +27 -> 74 // 50: pop // 51: goto +23 -> 74 // 54: astore 4 // 56: aload_3 // 57: invokeinterface 126 1 0 // 62: aload_1 // 63: checkcast 60 org/eclipse/team/internal/ui/synchronize/RefreshModelParticipantJob$ChangeDescription // 66: invokeinterface 125 2 0 // 71: aload 4 // 73: athrow // 74: aload_3 // 75: invokeinterface 126 1 0 // 80: aload_1 // 81: checkcast 60 org/eclipse/team/internal/ui/synchronize/RefreshModelParticipantJob$ChangeDescription // 84: invokeinterface 125 2 0 // 89: return // Line number table: // Java source line #65 -> byte code offset #0 // Java source line #67 -> byte code offset #11 // Java source line #69 -> byte code offset #26 // Java source line #72 -> byte code offset #37 // Java source line #73 -> byte code offset #50 // Java source line #76 -> byte code offset #54 // Java source line #77 -> byte code offset #56 // Java source line #78 -> byte code offset #71 // Java source line #77 -> byte code offset #74 // Java source line #79 -> byte code offset #89 // Local variable table: // start length slot name signature // 0 90 0 this RefreshModelParticipantJob // 0 90 1 changeListener RefreshParticipantJob.IChangeDescription // 0 90 2 monitor IProgressMonitor // 10 65 3 context ISynchronizationContext // 54 18 4 localObject Object // 50 1 5 localInterruptedException InterruptedException // Exception table: // from to target type // 37 47 50 java/lang/InterruptedException // 11 54 54 finally } protected int getChangeCount() { return ((ModelSynchronizeParticipant)getParticipant()).getContext().getDiffTree().size(); } protected int getIncomingChangeCount() { IResourceDiffTree diffTree = ((ModelSynchronizeParticipant)getParticipant()).getContext().getDiffTree(); return (int)diffTree.countFor(512, 768); } protected int getOutgoingChangeCount() { IResourceDiffTree diffTree = ((ModelSynchronizeParticipant)getParticipant()).getContext().getDiffTree(); return (int)diffTree.countFor(256, 768); } protected void handleProgressGroupSet(IProgressMonitor group, int ticks) { this.group = group; groupTicks = ticks; } protected RefreshParticipantJob.IChangeDescription createChangeDescription() { return new ChangeDescription(); } public boolean belongsTo(Object family) { if ((family instanceof RefreshModelParticipantJob)) { RefreshModelParticipantJob rmpj = (RefreshModelParticipantJob)family; return rmpj.getParticipant() == getParticipant(); } if (family == getParticipant()) { return true; } return super.belongsTo(family); } public IStatus run(IProgressMonitor monitor) { if (group != null) { monitor = wrapMonitorWithGroup(monitor); } return super.run(monitor); } private IProgressMonitor wrapMonitorWithGroup(IProgressMonitor monitor) { return new GroupProgressMonitor(monitor, group, groupTicks); } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshModelParticipantJob * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.jface.util.IPropertyChangeListener; import org.eclipse.jface.util.PropertyChangeEvent; class RefreshParticipantJob$1 implements IPropertyChangeListener { final RefreshParticipantJob.GotoActionWrapper this$1; RefreshParticipantJob$1(RefreshParticipantJob.GotoActionWrapper paramGotoActionWrapper) { this$1 = paramGotoActionWrapper; } public void propertyChange(PropertyChangeEvent event) { if (event.getProperty().equals("enabled")) { Boolean bool = (Boolean)event.getNewValue(); this$1.setEnabled(bool.booleanValue()); } } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.1 * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.jobs.IJobChangeEvent; import org.eclipse.core.runtime.jobs.JobChangeAdapter; class RefreshParticipantJob$2 extends JobChangeAdapter { final RefreshParticipantJob this$0; RefreshParticipantJob$2(RefreshParticipantJob paramRefreshParticipantJob) { this$0 = paramRefreshParticipantJob; } public void done(IJobChangeEvent event) { if (this$0.shouldReschedule()) { IStatus result = event.getResult(); if ((result.getSeverity() == 8) && (!RefreshParticipantJob.access$0(this$0))) { return; } long delay = RefreshParticipantJob.access$1(); if (result == RefreshParticipantJob.access$2()) { delay = 5000L; } this$0.schedule(delay); RefreshParticipantJob.access$3(this$0, true); } } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.2 * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.core.runtime.jobs.Job; import org.eclipse.ui.actions.ActionFactory.IWorkbenchAction; class RefreshParticipantJob$3 implements IRefreshSubscriberListener { final RefreshParticipantJob this$0; private final IRefreshSubscriberListener val$listener; private final RefreshParticipantJob.GotoActionWrapper val$actionWrapper; RefreshParticipantJob$3(RefreshParticipantJob paramRefreshParticipantJob, IRefreshSubscriberListener paramIRefreshSubscriberListener, RefreshParticipantJob.GotoActionWrapper paramGotoActionWrapper) { this$0 = paramRefreshParticipantJob;val$listener = paramIRefreshSubscriberListener;val$actionWrapper = paramGotoActionWrapper; } public void refreshStarted(IRefreshEvent event) { if (val$listener != null) { val$listener.refreshStarted(event); } } public ActionFactory.IWorkbenchAction refreshDone(IRefreshEvent event) { if (val$listener != null) { boolean isModal = RefreshParticipantJob.access$4(this$0); event.setIsLink(!isModal); ActionFactory.IWorkbenchAction runnable = val$listener.refreshDone(event); if (runnable != null) { if (isModal) { if (runnable != null) { Job update = new RefreshParticipantJob.4(this, "", runnable); update.setSystem(true); update.schedule(); } } else { val$actionWrapper.setGotoAction(runnable); } } RefreshParticipantJob.removeRefreshListener(this); } return null; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.3 * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.Status; import org.eclipse.ui.actions.ActionFactory.IWorkbenchAction; import org.eclipse.ui.progress.UIJob; class RefreshParticipantJob$4 extends UIJob { final RefreshParticipantJob.3 this$1; private final ActionFactory.IWorkbenchAction val$runnable; RefreshParticipantJob$4(RefreshParticipantJob.3 param3, String $anonymous0, ActionFactory.IWorkbenchAction paramIWorkbenchAction) { super($anonymous0);this$1 = param3;val$runnable = paramIWorkbenchAction; } public IStatus runInUIThread(IProgressMonitor monitor) { val$runnable.run(); return Status.OK_STATUS; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.4 * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; class RefreshParticipantJob$5 extends RefreshParticipantJob.Notification { final RefreshParticipantJob this$0; private final int val$state; private final IRefreshEvent val$event; RefreshParticipantJob$5(RefreshParticipantJob paramRefreshParticipantJob, int paramInt, IRefreshEvent paramIRefreshEvent) { super(paramRefreshParticipantJob, null);this$0 = paramRefreshParticipantJob;val$state = paramInt;val$event = paramIRefreshEvent; } protected void notify(IRefreshSubscriberListener listener) { switch (val$state) { case 1: listener.refreshStarted(val$event); break; case 2: listener.refreshDone(val$event); break; } } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.5 * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.core.runtime.IStatus; import org.eclipse.jface.dialogs.ErrorDialog; import org.eclipse.team.internal.ui.TeamUIMessages; import org.eclipse.team.internal.ui.Utils; import org.eclipse.ui.actions.ActionFactory.IWorkbenchAction; final class RefreshParticipantJob$GotoActionWrapper extends WorkbenchAction { private ActionFactory.IWorkbenchAction gotoAction; private IStatus status; final RefreshParticipantJob this$0; private RefreshParticipantJob$GotoActionWrapper(RefreshParticipantJob paramRefreshParticipantJob) { this$0 = paramRefreshParticipantJob; } RefreshParticipantJob$GotoActionWrapper(RefreshParticipantJob paramRefreshParticipantJob, GotoActionWrapper paramGotoActionWrapper) { this(paramRefreshParticipantJob); } public void run() { if ((status != null) && (!status.isOK())) { ErrorDialog.openError(Utils.getShell(null), null, TeamUIMessages.RefreshSubscriberJob_3, status); } else if (gotoAction != null) { gotoAction.run(); } } public boolean isEnabled() { if (gotoAction != null) { return gotoAction.isEnabled(); } return true; } public String getText() { if (gotoAction != null) { return gotoAction.getText(); } return null; } public String getToolTipText() { if ((status != null) && (!status.isOK())) { return status.getMessage(); } if (gotoAction != null) { return gotoAction.getToolTipText(); } return Utils.shortenText(100, this$0.getName()); } public void dispose() { super.dispose(); if (gotoAction != null) { gotoAction.dispose(); } } public void setGotoAction(ActionFactory.IWorkbenchAction gotoAction) { this.gotoAction = gotoAction; setEnabled(isEnabled()); setToolTipText(getToolTipText()); gotoAction.addPropertyChangeListener(new RefreshParticipantJob.1(this)); } public void setStatus(IStatus status) { this.status = status; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.GotoActionWrapper * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; public abstract interface RefreshParticipantJob$IChangeDescription { public abstract int getChangeCount(); } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.IChangeDescription * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.ProgressMonitorWrapper; class RefreshParticipantJob$NonblockingProgressMonitor extends ProgressMonitorWrapper { private final RefreshParticipantJob job; private long blockTime; private static final int THRESHOLD = 250; private boolean wasBlocking; final RefreshParticipantJob this$0; protected RefreshParticipantJob$NonblockingProgressMonitor(RefreshParticipantJob paramRefreshParticipantJob1, IProgressMonitor monitor, RefreshParticipantJob job) { super(monitor);this$0 = paramRefreshParticipantJob1;wasBlocking = false; this.job = job; } public boolean isCanceled() { if (super.isCanceled()) { return true; } if ((job.shouldReschedule()) && (job.isBlocking())) { if (blockTime == 0L) { blockTime = System.currentTimeMillis(); } else if (System.currentTimeMillis() - blockTime > 250L) { wasBlocking = true; return true; } } else { blockTime = 0L; } wasBlocking = false; return false; } public boolean wasBlocking() { return wasBlocking; } } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.NonblockingProgressMonitor * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import org.eclipse.core.runtime.ISafeRunnable; import org.eclipse.core.runtime.SafeRunner; abstract class RefreshParticipantJob$Notification implements ISafeRunnable { private IRefreshSubscriberListener listener; final RefreshParticipantJob this$0; private RefreshParticipantJob$Notification(RefreshParticipantJob paramRefreshParticipantJob) { this$0 = paramRefreshParticipantJob; } RefreshParticipantJob$Notification(RefreshParticipantJob paramRefreshParticipantJob, Notification paramNotification) { this(paramRefreshParticipantJob); } public void run(IRefreshSubscriberListener listener) { this.listener = listener; SafeRunner.run(this); } public void run() throws Exception { notify(listener); } public void handleException(Throwable exception) {} protected abstract void notify(IRefreshSubscriberListener paramIRefreshSubscriberListener); } /* Location: * Qualified Name: org.eclipse.team.internal.ui.synchronize.RefreshParticipantJob.Notification * Java Class Version: 1.2 (46.0) * JD-Core Version: 0.7.1 */ package org.eclipse.team.internal.ui.synchronize; import java.util.ArrayList; import java.util.List; import org.eclipse.core.runtime.Assert; import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.ISafeRun Further reading...For more information on Java 1.5 Tiger, you may find Java 1.5 Tiger, A developer's Notebook by D. Flanagan and B. McLaughlin from O'Reilly of interest.New!JAR listings
|