Example #1
0
    public void updateConnectorHierarchy(List<ServerConnector> children) {
      Set<String> connectorIds = new HashSet<String>();
      for (ServerConnector child : children) {
        if (child instanceof ComponentConnector) {
          connectorIds.add(child.getConnectorId());
          idToDetailsMap.put(child.getConnectorId(), (ComponentConnector) child);
        }
      }

      Set<String> removedDetails = new HashSet<String>();
      for (Entry<String, ComponentConnector> entry : idToDetailsMap.entrySet()) {
        ComponentConnector connector = entry.getValue();
        String id = connector.getConnectorId();
        if (!connectorIds.contains(id)) {
          removedDetails.add(entry.getKey());
          if (idToRowIndex.containsKey(id)) {
            getWidget().setDetailsVisible(idToRowIndex.get(id), false);
          }
        }
      }

      for (String id : removedDetails) {
        idToDetailsMap.remove(id);
        idToRowIndex.remove(id);
      }
    }
Example #2
0
 @Override
 public Object invoke(Object target, Method method, Object[] params) {
   MethodInvocation invocation =
       new MethodInvocation(
           connector.getConnectorId(), rpcInterface.getName(), method.getName(), params);
   connector
       .getConnection()
       .addMethodInvocationToQueue(invocation, method.isDelayed(), method.isLastOnly());
   // No RPC iface should have a return value
   return null;
 }
Example #3
0
 @Override
 public Object invoke(Object target, Method method, Object[] params) {
   MethodInvocation invocation =
       new MethodInvocation(
           connector.getConnectorId(), rpcInterface.getName(), method.getName(), params);
   ServerRpcQueue serverRpcQueue = ServerRpcQueue.get(connector.getConnection());
   serverRpcQueue.add(invocation, method.isLastOnly());
   if (!method.isDelayed()) {
     serverRpcQueue.flush();
   }
   // No RPC iface should have a return value
   return null;
 }