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


Java DatabaseListChangeListener类代码示例

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


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

示例1: fireAddEvent

import ca.sqlpower.sql.DatabaseListChangeListener; //导入依赖的package包/类
private void fireAddEvent(SPDataSource dbcs) {
   	logger.debug("firing databaseAddedEvent :");
	int index = dataSources.size()-1;
	final DatabaseListChangeEvent e = new DatabaseListChangeEvent(this, index, dbcs);
   	synchronized(listeners) {
   	    Runnable runner = new Runnable() {
               public void run() {
                   for(DatabaseListChangeListener listener : listeners) {
                       logger.debug("\n"+ listener.toString());
                       listener.databaseAdded(e);
                   }
               }
           };
           runInForeground(runner);
	}
}
 
开发者ID:SQLPower,项目名称:wabit,代码行数:17,代码来源:WabitWorkspace.java

示例2: fireRemoveEvent

import ca.sqlpower.sql.DatabaseListChangeListener; //导入依赖的package包/类
private void fireRemoveEvent(int i, SPDataSource dbcs) {
  	logger.debug("firing databaseRemovedEvent:");
  	final DatabaseListChangeEvent e = new DatabaseListChangeEvent(this, i, dbcs);
  	synchronized(listeners) {
  	    Runnable runner = new Runnable() {
              public void run() {
                  for(DatabaseListChangeListener listener : listeners) {
                      logger.debug("\n"+ listener.toString());
                      listener.databaseRemoved(e);
                  }
              }
  	    };
  	    runInForeground(runner);
}
  }
 
开发者ID:SQLPower,项目名称:wabit,代码行数:16,代码来源:WabitWorkspace.java

示例3: addDatabaseListChangeListener

import ca.sqlpower.sql.DatabaseListChangeListener; //导入依赖的package包/类
public void addDatabaseListChangeListener(DatabaseListChangeListener l) {
	dbListChangeListeners.add(l);
}
 
开发者ID:SQLPower,项目名称:sqlpower-library,代码行数:4,代码来源:StubDataSourceCollection.java

示例4: removeDatabaseListChangeListener

import ca.sqlpower.sql.DatabaseListChangeListener; //导入依赖的package包/类
public void removeDatabaseListChangeListener(DatabaseListChangeListener l) {
	dbListChangeListeners.remove(l);
}
 
开发者ID:SQLPower,项目名称:sqlpower-library,代码行数:4,代码来源:StubDataSourceCollection.java

示例5: WabitWorkspace

import ca.sqlpower.sql.DatabaseListChangeListener; //导入依赖的package包/类
/**
   * Creates a new Wabit workspace. This is normally done by the session it
   * belongs to.
   */
  public WabitWorkspace() {
      listeners = new ArrayList<DatabaseListChangeListener>();
      this.variableResolver = new WorkspaceVariableResolver(this, this.getUUID(), "Workspace - " + this.getName());
setName(DEFAULT_NAME);
  }
 
开发者ID:SQLPower,项目名称:wabit,代码行数:10,代码来源:WabitWorkspace.java

示例6: addDatabaseListChangeListener

import ca.sqlpower.sql.DatabaseListChangeListener; //导入依赖的package包/类
public void addDatabaseListChangeListener(DatabaseListChangeListener l) {
	synchronized(listeners) {
		logger.debug("added DatabaseListChangeListener :"+ l.toString());
		listeners.add(l);
	}
}
 
开发者ID:SQLPower,项目名称:wabit,代码行数:7,代码来源:WabitWorkspace.java

示例7: removeDatabaseListChangeListener

import ca.sqlpower.sql.DatabaseListChangeListener; //导入依赖的package包/类
public void removeDatabaseListChangeListener(DatabaseListChangeListener l) {
   	synchronized(listeners) {
   		listeners.remove(l);
   	}
}
 
开发者ID:SQLPower,项目名称:wabit,代码行数:6,代码来源:WabitWorkspace.java


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