예제 #1
0
  public String getConfiguredPassword() {

    String result = null;

    Configuration c = getConfiguration();
    if (c != null) {

      NameValue nv = c.findNameValueByName(NMSConstants.PASSWORD);
      if (nv != null) {

        result = nv.getValue();
      }
    }

    return (result);
  }
예제 #2
0
  /** {@inheritDoc} */
  public int getConfiguredUpdateHour() {

    int result = 4;

    Configuration c = getConfiguration();
    if (c != null) {

      NameValue nv = c.findNameValueByName(NMSConstants.UPDATE_HOUR);
      if (nv != null) {

        result = Util.str2int(nv.getValue(), result);
      }
    }

    return (result);
  }
예제 #3
0
  public String getConfiguredUserName() {

    String result = null;

    Configuration c = getConfiguration();
    if (c != null) {

      NameValue nv = c.findNameValueByName(NMSConstants.USER_NAME);
      if (nv != null) {

        result = nv.getValue();
      }
    }

    return (result);
  }
예제 #4
0
  public String getConfiguredZipCode() {

    String result = null;

    Configuration c = getConfiguration();
    if (c != null) {

      NameValue nv = c.findNameValueByName(NMSConstants.ZIP_CODE);
      if (nv != null) {

        result = nv.getValue();
      }
    }

    return (result);
  }
예제 #5
0
  public String getConfiguredCountry() {

    String result = null;

    Configuration c = getConfiguration();
    if (c != null) {

      NameValue nv = c.findNameValueByName(NMSConstants.COUNTRY);
      if (nv != null) {

        result = nv.getValue();
      }
    }

    return (result);
  }
예제 #6
0
  /**
   * Convenience method to get the configured Recorder Source.
   *
   * @return A directory path as a String.
   */
  public String getConfiguredRecorderSource() {

    String result = null;

    Configuration c = getConfiguration();
    if (c != null) {

      NameValue nv = c.findNameValueByName(NMSConstants.RECORDING_DEVICE);
      if (nv != null) {

        result = nv.getValue();
      }
    }

    return (result);
  }
예제 #7
0
  /**
   * Convenience method to get the configured value of PORT, if an OnDemand service defines one.
   *
   * @return A String object.
   */
  public int getConfiguredPort() {

    int result = 8080;

    Configuration c = getConfiguration();
    if (c != null) {

      NameValue nv = c.findNameValueByName(NMSConstants.PORT);
      if (nv != null) {

        result = Util.str2int(nv.getValue(), result);
      }
    }

    return (result);
  }