Package jade.util.leap

Examples of jade.util.leap.List


  public synchronized void removeMTP(ContainerID cid, MTPDescriptor mtp) throws NotFoundException {
    Entry e = (Entry)entries.get(cid);
    if(e == null)
      throw new NotFoundException("No container named " + cid.getName() + " was found.");
    List l = e.getMTPs();
    l.remove(mtp);
  }
View Full Code Here


  private class NotificationHelperImpl implements NotificationHelper {
    public void init(Agent a) {
    }
   
    public void registerMessageListener(MessageListener ml) {
      List l = messageListeners.startModifying();
      l.add(ml);
      messageListeners.stopModifying();
    }
View Full Code Here

      l.add(ml);
      messageListeners.stopModifying();
    }
   
    public void deregisterMessageListener(MessageListener ml) {
      List l = messageListeners.startModifying();
      l.remove(ml);
      messageListeners.stopModifying();   
    }
View Full Code Here

      l.remove(ml);
      messageListeners.stopModifying();   
    }
   
    public void registerAgentListener(AgentListener al) {
      List l = agentListeners.startModifying();
      l.add(al);
      agentListeners.stopModifying();   
    }
View Full Code Here

      l.add(al);
      agentListeners.stopModifying();   
    }
   
    public void deregisterAgentListener(AgentListener al) {
      List l = agentListeners.startModifying();
      l.remove(al);
      agentListeners.stopModifying();   
    }
View Full Code Here

      l.remove(al);
      agentListeners.stopModifying();   
    }
   
    public void registerContainerListener(ContainerListener cl) {
      List l = containerListeners.startModifying();
      l.add(cl);
      containerListeners.stopModifying();   
    }
View Full Code Here

      l.add(cl);
      containerListeners.stopModifying();   
    }
   
    public void deregisterContainerListener(ContainerListener cl) {
      List l = containerListeners.startModifying();
      l.remove(cl);
      containerListeners.stopModifying();   
    }
View Full Code Here

   
    getContentPane().add(bar, BorderLayout.NORTH);
   
   
    // Retrieve logging information
    List infos = retrieveLogInfo();
   
    myTable = new LogTable(infos);
    JTable table = new JTable(myTable);
    getContentPane().add(new JScrollPane(table), BorderLayout.CENTER);
   
    //Allows the modification to the value in the cell 
    levelCombo = new JComboBox();
    List levels = myLogManager.getLogLevels();
    for (int i = 0; i < levels.size(); ++i) {
      LevelInfo l = (LevelInfo) levels.get(i);
      levelCombo.addItem(l.getName());
    }
   
    TableCellEditor levelEditor = new DefaultCellEditor(levelCombo)
    TableColumnModel columnModel = table.getColumnModel();
View Full Code Here

  public AID getController() {
    return controller;
  }
 
  private List retrieveLogInfo() throws FIPAException {
    List tmp = null;
    if (controller != null) {
      tmp = remoteRetrieveLogInfo(controller);
    }
    else {
      tmp = myLogManager.getAllLogInfo();
    }
    // Now sort log info in alphabetical order
    List infos = new ArrayList(tmp.size());
    Iterator it = tmp.iterator();
    while (it.hasNext()) {
      LoggerInfo li = (LoggerInfo) it.next();
      String name = li.toString();
      int i = 0;
      while (i < infos.size() && name.compareTo(infos.get(i).toString()) >= 0) {
        ++i;
      }
      infos.add(i, li);
    }
    return infos;
  }
View Full Code Here

  public void internalFrameIconified(InternalFrameEvent e) {}
  public void internalFrameDeiconified(InternalFrameEvent e) {}
  public void internalFrameOpened(InternalFrameEvent e) {}
 
  private String getLevelName(int n) {
    List l = myLogManager.getLogLevels();
    Iterator it = l.iterator();
    while (it.hasNext()) {
      LevelInfo li = (LevelInfo) it.next();
      if (n == li.getValue()) {
        return li.getName();
      }
View Full Code Here

TOP

Related Classes of jade.util.leap.List

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.