当前位置: 首页>>代码示例>>Java>>正文


Java SetChangeEvent类代码示例

本文整理汇总了Java中org.eclipse.core.databinding.observable.set.SetChangeEvent的典型用法代码示例。如果您正苦于以下问题:Java SetChangeEvent类的具体用法?Java SetChangeEvent怎么用?Java SetChangeEvent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


SetChangeEvent类属于org.eclipse.core.databinding.observable.set包,在下文中一共展示了SetChangeEvent类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: handleSetChange

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
@Override
public void handleSetChange ( final SetChangeEvent event )
{
    for ( final Iterator<?> it = event.diff.getAdditions ().iterator (); it.hasNext (); )
    {
        addListenerTo ( it.next () );
    }
    for ( final Iterator<?> it = event.diff.getRemovals ().iterator (); it.hasNext (); )
    {
        processRemove ( it.next () );
    }
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:13,代码来源:ListeningStyledCellLabelProvider.java

示例2: handleSetChange

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
@Override
public void handleSetChange ( final SetChangeEvent event )
{
    for ( final Iterator<?> it = event.diff.getAdditions ().iterator (); it.hasNext (); )
    {
        addListenerTo ( it.next () );
    }
    for ( final Iterator<?> it = event.diff.getRemovals ().iterator (); it.hasNext (); )
    {
        removeListenerFrom ( it.next () );
    }
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:13,代码来源:ListeningLabelProvider.java

示例3: MonitorsViewTable

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
public MonitorsViewTable ( final Composite parent, final IViewSite viewSite, final int style, final WritableSet monitors, final List<ColumnProperties> columnSettings )
{
    super ( parent, style );

    this.monitors = monitors;

    final FillLayout layout = new FillLayout ();
    setLayout ( layout );

    this.tableViewer = new TableViewer ( this, SWT.H_SCROLL | SWT.V_SCROLL | SWT.FULL_SELECTION | SWT.MULTI );
    this.tableRef.set ( this.tableViewer );
    createColumns ( this.tableViewer );
    applyColumSettings ( columnSettings );
    this.tableViewer.getTable ().setHeaderVisible ( true );
    this.tableViewer.getTable ().setLinesVisible ( true );
    this.tableViewer.setUseHashlookup ( true );
    this.tableViewer.setSorter ( new Sorter ( Columns.LAST_FAIL_TIMESTAMP, SWT.DOWN ) );
    this.tableViewer.getTable ().setSortDirection ( SWT.DOWN );

    hookContextMenu ( this.tableViewer.getControl (), this.tableViewer, viewSite );

    viewSite.setSelectionProvider ( this.tableViewer );

    final ObservableSetContentProvider contentProvider = new ObservableSetContentProvider ();
    this.tableViewer.setContentProvider ( contentProvider );
    this.tableViewer.setLabelProvider ( new MonitorTableLabelProvider ( Properties.observeEach ( contentProvider.getKnownElements (), BeanProperties.values ( new String[] { "id", "monitor" } ) ), Settings.getTimeZone () ) ); //$NON-NLS-1$ //$NON-NLS-2$
    this.tableViewer.setInput ( this.monitors );

    contentProvider.getRealizedElements ().addSetChangeListener ( new ISetChangeListener () {
        @Override
        public void handleSetChange ( final SetChangeEvent event )
        {
            if ( !MonitorsViewTable.this.scrollLock )
            {
                MonitorsViewTable.this.tableViewer.getTable ().setTopIndex ( 0 );
            }
        }
    } );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:40,代码来源:MonitorsViewTable.java

示例4: TagListSelected

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
public TagListSelected(Composite parent, int style, Composite callLayout) {
	super(parent, style);
	
	this.callLayoutOnMe = callLayout;

	tagRowLayout = new RowLayout();
	tagRowLayout.wrap = true;
	tagRowLayout.pack = true;
	tagRowLayout.fill = true;
	setLayout(tagRowLayout);
	
	/**
	 * We keep track of the selected tags through a set change listener.
	 * This widget doesn't actually know which issue it's looking at tags
	 * for.
	 */
	selectedTags.addSetChangeListener(new ISetChangeListener() {

		@SuppressWarnings("unchecked")
		@Override
		public void handleSetChange(SetChangeEvent arg0) {
			Set<TagVM> removals = arg0.diff.getRemovals();
			for (TagVM removeMe : removals) {
				removeTagFromSelected(removeMe.getName());
			}
			Set<TagVM> additions = arg0.diff.getAdditions();
			for (TagVM addMe : additions) {
				addTagToSelected(addMe);
			}
			callLayoutOnMe.layout(true, true);
			callLayoutOnMe.pack(true);
		}

	});
}
 
开发者ID:sjclemen,项目名称:peten,代码行数:36,代码来源:TagListSelected.java

示例5: initAccessControllChangeTrack

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
/**
 * Modell m�dos�t�s�ra t�rt�n� feliratkoz�s �s annak hat�s�ra jogosults�g ellen�rz�s inid�t�sa
 */
public void initAccessControllChangeTrack() {
	try {
		@SuppressWarnings("deprecation")
		AdvancedIncQueryEngine engine = AdvancedIncQueryEngine
				.createUnmanagedEngine(resource);
		Set<IQuerySpecification<? extends IncQueryMatcher<? extends IPatternMatch>>> specifications = QuerySpecificationRegistry
				.getContributedQuerySpecifications();
		ArrayList<IObservableSet> observableSetList = new ArrayList<IObservableSet>();

		for (IQuerySpecification<? extends IncQueryMatcher<? extends IPatternMatch>> s : specifications) {
			IObservableSet set = IncQueryObservables.observeMatchesAsSet(s
					.getMatcher(engine));
			observableSetList.add(set);
		}

		IObservableSet[] observabelArray = observableSetList
				.toArray(new IObservableSet[observableSetList.size()]);
		UnionSet union = new UnionSet(observabelArray);
		union.addSetChangeListener(new ISetChangeListener() {

			@Override
			public void handleSetChange(SetChangeEvent event) {
				// �llpotv�ltoz�k ellen�rz�se
				if (verifier.getLastExecutionStep() == null
						|| verifier.getLastExecutionStep() != getChangeState()) {
					// Jogosults�g ki�rt�kel�s elind�t�sa
					verifier.printExecutedResult(getChangeState());
				} else {
					// Az �llapotv�ltoz�k megegyeznek, ekkor nem kell semmit
					// se csin�lni
				}
			}
		});
	} catch (IncQueryException e) {
		e.printStackTrace();
	}

}
 
开发者ID:FTSRG,项目名称:mondo-collab-framework,代码行数:42,代码来源:AccessControlManager.java

示例6: handleSetChange

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
@Override
public void handleSetChange ( final SetChangeEvent event )
{
    handleDiff ( event.diff );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:6,代码来源:ConnectionTreeManager.java

示例7: handleSetChange

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
@Override
public void handleSetChange ( final SetChangeEvent event )
{
    DiscovererListener.this.handleSetChange ( event.diff );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:6,代码来源:DiscovererListener.java

示例8: handleSetChange

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
@Override
public void handleSetChange ( final SetChangeEvent event )
{
    this.implNode.getConnections ().removeAll ( event.diff.getRemovals () );
    this.implNode.getConnections ().addAll ( event.diff.getAdditions () );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:7,代码来源:AllConnectionsNode.java

示例9: handleSetChange

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
@Override
public void handleSetChange ( final SetChangeEvent event )
{
    ComponentVisibility.this.handleSetChange ( event.diff );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:6,代码来源:ComponentVisibility.java

示例10: handleSetChange

import org.eclipse.core.databinding.observable.set.SetChangeEvent; //导入依赖的package包/类
@Override
public void handleSetChange ( final SetChangeEvent event )
{
    event.diff.applyTo ( SubTrackingVisibleComponent.this.descriptors );
}
 
开发者ID:eclipse,项目名称:neoscada,代码行数:6,代码来源:SubTrackingVisibleComponent.java


注:本文中的org.eclipse.core.databinding.observable.set.SetChangeEvent类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。