本文整理汇总了Java中org.eclipse.core.databinding.observable.IObservable类的典型用法代码示例。如果您正苦于以下问题:Java IObservable类的具体用法?Java IObservable怎么用?Java IObservable使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IObservable类属于org.eclipse.core.databinding.observable包,在下文中一共展示了IObservable类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
logger.debug ( "createObservable - {}", target );
if ( target instanceof IObservableList )
{
return Observables.proxyObservableList ( (IObservableList)target );
}
else if ( target instanceof KeyProviderFactory )
{
return Observables.proxyObservableList ( ( (KeyProviderFactory)target ).getKeyProviders () );
}
else if ( target instanceof KeyProvider )
{
return Observables.proxyObservableList ( ( (KeyProvider)target ).getKeys () );
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:20,代码来源:FactoryImpl.java
示例2: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
logger.info ( "create observable: {}", target );
if ( target instanceof ConnectionHolder )
{
return new RootFolderObserver ( (ConnectionHolder)target );
}
else if ( target instanceof FolderEntryWrapper )
{
final FolderEntry entry = AdapterHelper.adapt ( target, FolderEntry.class );
if ( entry != null )
{
// only return a new observer if the folder entry is of type FolderEntry
return new SubFolderObserver ( (FolderEntryWrapper)target );
}
else
{
return null;
}
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:26,代码来源:ConnectionObservableFactory.java
示例3: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
if ( target instanceof ConnectionHolder )
{
return new ConnectionWrapper ( (ConnectionHolder)target );
}
else if ( target instanceof ItemListWrapper )
{
return new ItemListObserver ( ( (ItemListWrapper)target ).getConnection () );
}
else if ( target instanceof QueryWrapper )
{
return ( (QueryWrapper)target ).getQueriesObservable ();
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:19,代码来源:ConnectionObservableFactory.java
示例4: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
if ( target instanceof IObservableSet )
{
return (IObservable)target;
}
else if ( target instanceof TreeNode )
{
return ( (TreeNode)target ).createObservable ();
}
else
{
return null;
}
}
开发者ID:eclipse,项目名称:neoscada,代码行数:17,代码来源:FactoryImpl.java
示例5: statusChanged
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
/**
* Status changed.
*
* @param status the status
*/
private void statusChanged(IStatus status)
{
for (Iterator it = targets.iterator(); it.hasNext();)
{
IObservable observable = (IObservable) it.next();
updater.updateBackground(findControl(observable), status);
}
for (Iterator it = targetDecorations.iterator(); it.hasNext();)
{
TargetDecoration targetDecoration = (TargetDecoration) it.next();
ControlDecoration decoration = targetDecoration.decoration;
updater.update(decoration, status);
updater.updateBackground(findControl(targetDecoration.target), status);
}
}
开发者ID:cplutte,项目名称:bts,代码行数:22,代码来源:BackgroundControlDecorationSupport.java
示例6: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
public IObservable createObservable(final Object target)
{
if (target instanceof IObservableList)
{
return (IObservable) target;
} else if (target instanceof BTSProject)
{
return project_multi.observe(target);
} else if (target instanceof BTSProjectDBCollection)
{
return coll_multi.observe(target);
} else if (target instanceof BTSDBCollectionRoleDesc)
{
return roleMembers_multi.observe(target);
}
return null;
}
开发者ID:cplutte,项目名称:bts,代码行数:19,代码来源:ProjectDBCollectionTreeFactory.java
示例7: dispose
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
public void dispose(){
if(this.cells != null){
for(TreeCell cell : this.cells){
if(cell != null){
cell.dispose();
}
}
}
if(this.currentChildren != null){
for(TreeRow row: this.currentChildren){
if(row != null){
row.dispose();
}
}
}
this.currentChildren = null;
for(IObservable o : externalObservables.values()){
o.dispose();
}
externalObservables.clear();
}
开发者ID:CloudScale-Project,项目名称:Environment,代码行数:25,代码来源:TreeRow.java
示例8: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
if ( target instanceof TreeNode )
{
return Observables.proxyObservableList ( ( (TreeNode)target ).getItems () );
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:10,代码来源:FactoryImpl.java
示例9: processRemove
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
/**
* @since 1.2
*/
protected void processRemove ( final Object element )
{
final IObservable obs = this.observables.remove ( element );
if ( obs != null )
{
obs.dispose ();
}
else
{
removeListenerFrom ( element );
}
}
开发者ID:eclipse,项目名称:neoscada,代码行数:16,代码来源:ListeningStyledCellLabelProvider.java
示例10: dispose
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public void dispose ()
{
for ( final IObservable obs : this.observables.values () )
{
obs.dispose ();
}
this.observables.clear ();
super.dispose ();
}
开发者ID:eclipse,项目名称:neoscada,代码行数:11,代码来源:ListeningStyledCellLabelProvider.java
示例11: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
public IObservable createObservable ( final Object target )
{
if ( target instanceof ConnectionHolder )
{
return new ConnectionWrapper ( (ConnectionHolder)target );
}
else if ( target instanceof FactoryInformationBean )
{
return Observables.proxyObservableSet ( ( (FactoryInformationBean)target ).getConfigurations () );
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:14,代码来源:ConnectionObservableFactory.java
示例12: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
if ( target == Activator.ROOT )
{
return Observables.proxyObservableSet ( Activator.getDefault ().getTreeRoot () );
}
else if ( target instanceof TreeNode )
{
return new UnionSet ( new IObservableSet[] { ( (TreeNode)target ).getChildren (), ( (TreeNode)target ).getConnections () } );
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:14,代码来源:ConnectionTreeObservableFactory.java
示例13: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
if ( target == Activator.ROOT )
{
return Activator.getDefault ().createDiscovererSet ();
}
else if ( target instanceof ConnectionDiscovererBean )
{
final ConnectionDiscovererBean element = (ConnectionDiscovererBean)target;
return element.getKnownConnections ();
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:15,代码来源:ConnectionObservableFactory.java
示例14: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
public IObservable createObservable ( final Object target )
{
if ( target instanceof ConnectionHolder )
{
return new ConnectionWrapper ( (ConnectionHolder)target );
}
else if ( target instanceof QueryListWrapper )
{
return ( (QueryListWrapper)target ).getObservableQueries ();
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:14,代码来源:ObservableFactory.java
示例15: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
public IObservable createObservable ( final Object target )
{
if ( target instanceof ConnectionHolder )
{
return new ConnectionWrapper ( (ConnectionHolder)target );
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:10,代码来源:ConnectionObservableFactory.java
示例16: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
public IObservable createObservable ()
{
if ( !this.subscribed )
{
subscribe ();
}
return Observables.proxyObservableSet ( this.groups );
}
开发者ID:eclipse,项目名称:neoscada,代码行数:9,代码来源:TreeNode.java
示例17: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
if ( target instanceof ServerManager )
{
return Observables.proxyObservableSet ( ( (ServerManager)target ).getServers () );
}
else if ( target instanceof ServerDescriptor )
{
return Observables.proxyObservableSet ( ( (ServerDescriptor)target ).getEndpoints () );
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:14,代码来源:ServersViewer.java
示例18: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable ( final Object target )
{
logger.debug ( "Getting observable for: {}", target );
if ( target instanceof IObservableSet )
{
return Observables.proxyObservableSet ( (IObservableSet)target );
}
else if ( target instanceof Master )
{
return Observables.proxyObservableSet ( ( (Master)target ).getEntries () );
}
else if ( target instanceof ItemEntry )
{
final ItemEntry itemEntry = (ItemEntry)target;
if ( itemEntry.getCustomizationRequest () != null && itemEntry.getCustomizationRequest ().getComponent () != null )
{
final WritableSet result = new WritableSet ();
result.add ( new ClassInformationProvider ( itemEntry.getCustomizationRequest ().getComponent ().getClass () ) );
return result;
}
}
else if ( target instanceof ClassInformationProvider )
{
return ( (ClassInformationProvider)target ).createSuper ( null );
}
return null;
}
开发者ID:eclipse,项目名称:neoscada,代码行数:29,代码来源:ComponentOutputObservableFactory.java
示例19: createObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
@Override
public IObservable createObservable(Object target, String path) {
EObject eObject = (EObject) target;
EClass eClass = eObject.eClass();
EStructuralFeature feature = eClass.getEStructuralFeature(path);
if (feature == null) {
throw new IllegalArgumentException("Feature not found: eClass=" + eClass.getName() + ", name=" + path);
}
return EMFObservables.observeValue(eObject, feature);
}
开发者ID:erdalkaraca,项目名称:lambda-ui,代码行数:13,代码来源:EMFObservableFactory.java
示例20: toObservable
import org.eclipse.core.databinding.observable.IObservable; //导入依赖的package包/类
private IObservable toObservable(Object dataContext, Binding binding) {
WritableValue wv = new WritableValue();
if (dataContext != null) {
// this binding element has a path to the root data context
wv.setValue(dataContext);
}
IObservable modelObservableValue = observe(wv, binding.getPath());
return modelObservableValue;
}
开发者ID:erdalkaraca,项目名称:lambda-ui,代码行数:12,代码来源:Binder.java
注:本文中的org.eclipse.core.databinding.observable.IObservable类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论