use of com.cubrid.cubridmanager.core.broker.model.BrokerStatusInfos in project cubrid-manager by CUBRID.
the class BrokerDBListNode method propertyChange.
/**
* Litsen the broker's status changing.
*
* @param evt PropertyChangeEvent
*/
public void propertyChange(PropertyChangeEvent evt) {
if (BrokerNode.PROP_BROKER_STATUS.equals(evt.getPropertyName())) {
BrokerStatusInfos bsi = brokerNode.getBrokerStatusInfos();
dbList.clear();
if (bsi == null || bsi.getAsinfo() == null || bsi.getAsinfo().isEmpty()) {
fireStructureChange(PROP_DB_LIST, dbList);
return;
}
for (ApplyServerInfo asi : bsi.getAsinfo()) {
if ("IDLE".equals(asi.getAs_status()) || StringUtil.isEmpty(asi.getAs_dbname()) || dbList.contains(asi.getAs_dbname())) {
continue;
}
dbList.add(asi.getAs_dbname());
}
fireStructureChange(PROP_DB_LIST, dbList);
}
}
Aggregations