Eclipse Platform
Release 3.0

org.eclipse.team.ui.synchronize
Interface ISynchronizeManager


public interface ISynchronizeManager

Manages synchronization view participants. Clients can programatically add or remove participant instances from this manager. Managed participants are available to clients whereas un-managed participants can still exist but won't be available generally available to clients until explicitly added to the manager.

Participants added to the manager will benefit from the manager's lifecycle support. The participants will automatically have their #init method and #dispose called when the manager starts and is shutdown and if persistable will be allowed to save their state on shutdown.

Clients are not intended to implement this interface.

Since:
3.0
See Also:
ISynchronizeParticipant, TeamUI#getSynchronizeManager()

Field Summary
static Object FAMILY_SYNCHRONIZE_OPERATION
          Constant identifying the job family identifier for a background job that affects the synchronization state of resources.
 
Method Summary
 void addSynchronizeParticipantListener(ISynchronizeParticipantListener listener)
          Registers the given listener for participant notifications.
 void addSynchronizeParticipants(ISynchronizeParticipant[] participants)
          Adds the given participants to the synchronize manager.
 ISynchronizeParticipantReference[] get(String id)
          Returns the registered synchronize participants with the given type id.
 ISynchronizeParticipantReference get(String id, String secondayId)
          Returns the registered synchronize participants with the given type id and instance id.
 ISynchronizeParticipantDescriptor getParticipantDescriptor(String type)
          Returns the participant descriptor for the given participant type id or null if a descriptor is not found for that id.
 ISynchronizeParticipantReference[] getSynchronizeParticipants()
          Returns a collection of synchronize participant references registered with the synchronize manager.
 void removeSynchronizeParticipantListener(ISynchronizeParticipantListener listener)
          Deregisters the given listener for participant notifications.
 void removeSynchronizeParticipants(ISynchronizeParticipant[] participants)
          Removes the given participants from the synchronize manager.
 ISynchronizeView showSynchronizeViewInActivePage()
          Opens the synchronize view in the perspective defined by the user in the team synchronize perferences.
 

Field Detail

FAMILY_SYNCHRONIZE_OPERATION

public static final Object FAMILY_SYNCHRONIZE_OPERATION
Constant identifying the job family identifier for a background job that affects the synchronization state of resources. All clients that schedule background jobs that affect synchronization state should include this job family in their implementation of belongsTo.

See Also:
Job#belongsTo(Object)
Method Detail

addSynchronizeParticipantListener

public void addSynchronizeParticipantListener(ISynchronizeParticipantListener listener)
Registers the given listener for participant notifications. Has no effect if an identical listener is already registered.

Parameters:
listener - listener to register

removeSynchronizeParticipantListener

public void removeSynchronizeParticipantListener(ISynchronizeParticipantListener listener)
Deregisters the given listener for participant notifications. Has no effect if an identical listener is not already registered.

Parameters:
listener - listener to deregister

addSynchronizeParticipants

public void addSynchronizeParticipants(ISynchronizeParticipant[] participants)
Adds the given participants to the synchronize manager. Has no effect for equivalent participants are already registered. The participants will be added to any existing synchronize views.

Parameters:
participants - participants to add

removeSynchronizeParticipants

public void removeSynchronizeParticipants(ISynchronizeParticipant[] participants)
Removes the given participants from the synchronize manager. If the participants are being displayed in any synchronize views, their associated pages will be closed.

Parameters:
participants - participants to remove

getSynchronizeParticipants

public ISynchronizeParticipantReference[] getSynchronizeParticipants()
Returns a collection of synchronize participant references registered with the synchronize manager.

Returns:
a collection of synchronize participants registered with the synchronize manager.

get

public ISynchronizeParticipantReference[] get(String id)
Returns the registered synchronize participants with the given type id. It is possible to have multiple instances of the same participant type.

Parameters:
id - the type indentifier for the participant
Returns:
the registered synchronize participants with the given id, or an empty list if there are none with that id registered.

get

public ISynchronizeParticipantReference get(String id,
                                            String secondayId)
Returns the registered synchronize participants with the given type id and instance id.

Parameters:
id - the type indentifier for the participant
Returns:
the registered synchronize participants with the given id, or null if none with that id is not registered.

showSynchronizeViewInActivePage

public ISynchronizeView showSynchronizeViewInActivePage()
Opens the synchronize view in the perspective defined by the user in the team synchronize perferences.

Returns:
the opened synchronize view or null if it can't be opened.

getParticipantDescriptor

public ISynchronizeParticipantDescriptor getParticipantDescriptor(String type)
Returns the participant descriptor for the given participant type id or null if a descriptor is not found for that id.

Returns:
the participant descriptor for the given participant id or null if a descriptor is not found for that id.

Eclipse Platform
Release 3.0

Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp. and others 2000, 2004. All rights reserved.