From 21230edbafdd30fcf0c43d1dc64ccbf4ca5e06a8 Mon Sep 17 00:00:00 2001 From: Andrew Branson Date: Wed, 7 May 2014 17:33:57 +0200 Subject: Agent now extends Item, so they can have workflows. All traces of the old 'Entity' superclasses should be removed, including proxies and paths. Very large change, breaks API compatibility with CRISTAL 2.x. --- .../java/com/c2kernel/gui/tabs/PropertiesPane.java | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src/main/java/com/c2kernel/gui/tabs/PropertiesPane.java') diff --git a/src/main/java/com/c2kernel/gui/tabs/PropertiesPane.java b/src/main/java/com/c2kernel/gui/tabs/PropertiesPane.java index 7cbd00e..b6fca75 100644 --- a/src/main/java/com/c2kernel/gui/tabs/PropertiesPane.java +++ b/src/main/java/com/c2kernel/gui/tabs/PropertiesPane.java @@ -24,7 +24,7 @@ import javax.swing.JOptionPane; import javax.swing.JPanel; import javax.swing.SwingConstants; -import com.c2kernel.entity.proxy.EntityProxyObserver; +import com.c2kernel.entity.proxy.ProxyObserver; import com.c2kernel.entity.proxy.ItemProxy; import com.c2kernel.entity.proxy.MemberSubscription; import com.c2kernel.gui.MainFrame; @@ -40,7 +40,7 @@ import com.c2kernel.utils.Language; * @version $Revision: 1.44 $ $Date: 2005/08/31 07:21:20 $ * @author $Author: abranson $ */ -public class PropertiesPane extends EntityTabPane implements EntityProxyObserver, ActionListener { +public class PropertiesPane extends ItemTabPane implements ProxyObserver, ActionListener { Box propertyBox; JButton eraseButton; @@ -94,25 +94,25 @@ public class PropertiesPane extends EntityTabPane implements EntityProxyObserver @Override public void reload() { - Gateway.getStorage().clearCache(sourceEntity.getSysKey(), ClusterStorage.PROPERTY); + Gateway.getStorage().clearCache(sourceItem.getSysKey(), ClusterStorage.PROPERTY); loadedProps = new HashMap(); - initForEntity(sourceEntity); + initForItem(sourceItem); } @Override public void run() { Thread.currentThread().setName("Property Pane Builder"); - if (sourceEntity instanceof NodeAgent) { + if (sourceItem instanceof NodeAgent) { remove(domAdmin); remove(domTitle); eraseButton.setEnabled(false); } else if (domAdmin != null) - domAdmin.setEntity((ItemProxy)sourceEntity.getEntity()); + domAdmin.setEntity(sourceItem.getItem()); propertyBox.removeAll(); propertyBox.add(Box.createGlue()); revalidate(); - sourceEntity.getEntity().subscribe(new MemberSubscription(this, ClusterStorage.PROPERTY, true)); + sourceItem.getItem().subscribe(new MemberSubscription(this, ClusterStorage.PROPERTY, true)); } /** @@ -140,7 +140,7 @@ public class PropertiesPane extends EntityTabPane implements EntityProxyObserver JOptionPane.QUESTION_MESSAGE, null, null, oldVal); if (newVal!=null && !(newVal.equals(oldVal))) { try { - ((ItemProxy)sourceEntity.getEntity()).setProperty(MainFrame.userAgent, e.getActionCommand(), newVal); + (sourceItem.getItem()).setProperty(MainFrame.userAgent, e.getActionCommand(), newVal); } catch (Exception ex) { MainFrame.exceptionDialog(ex); } @@ -186,7 +186,7 @@ public class PropertiesPane extends EntityTabPane implements EntityProxyObserver return; try { - MainFrame.userAgent.execute((ItemProxy)sourceEntity.getEntity(), predefStep, params); + MainFrame.userAgent.execute(sourceItem.getItem(), predefStep, params); } catch (Exception ex) { MainFrame.exceptionDialog(ex); } -- cgit v1.2.3