Ejemplo n.º 1
0
  /**
   * Gets an Lcd model.
   *
   * @param sys The subsytem managing the model
   * @param id The model Id.
   * @return The Lcd model or null if no Lcd model were found.
   */
  public SnmpModelLcd getModelLcd(SnmpSubSystem sys, int id) {
    SubSysLcdManager subsys = subs.get(sys);

    if (subsys == null) return null;

    return subsys.getModelLcd(id);
  }
Ejemplo n.º 2
0
  /**
   * Adds an Lcd model.
   *
   * @param sys The subsytem managing the model.
   * @param id The model Id.
   * @param lcd The Lcd model.
   */
  public void addModelLcd(SnmpSubSystem sys, int id, SnmpModelLcd lcd) {

    SubSysLcdManager subsys = subs.get(sys);
    if (subsys == null) {
      subsys = new SubSysLcdManager();
      subs.put(sys, subsys);
    }

    subsys.addModelLcd(id, lcd);
  }
Ejemplo n.º 3
0
  /**
   * Removes an Lcd model.
   *
   * @param sys The subsytem managing the model.
   * @param id The model Id.
   */
  public void removeModelLcd(SnmpSubSystem sys, int id)
      throws SnmpUnknownModelLcdException, SnmpUnknownSubSystemException {

    SubSysLcdManager subsys = subs.get(sys);
    if (subsys != null) {
      SnmpModelLcd lcd = subsys.removeModelLcd(id);
      if (lcd == null) {
        throw new SnmpUnknownModelLcdException("Model : " + id);
      }
    } else throw new SnmpUnknownSubSystemException(sys.toString());
  }