mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Nicolas Capponi
08.33.2014 8643a9160860e31611f034467f702eb3a712eb34
opendj3-server-dev/src/server/org/opends/server/admin/IntegerPropertyDefinition.java
@@ -22,6 +22,7 @@
 *
 *
 *      Copyright 2008 Sun Microsystems, Inc.
 *      Portions Copyright 2014 ForgeRock AS
 */
package org.opends.server.admin;
@@ -29,7 +30,7 @@
import static org.opends.server.util.Validator.ensureNotNull;
import static org.forgerock.util.Reject.ifNull;
import java.util.EnumSet;
import java.util.Locale;
@@ -276,7 +277,7 @@
  @Override
  public void validateValue(Integer value)
      throws IllegalPropertyValueException {
    ensureNotNull(value);
    ifNull(value);
    if (!allowUnlimited && value < lowerLimit) {
      throw new IllegalPropertyValueException(this, value);
@@ -297,7 +298,7 @@
  @Override
  public String encodeValue(Integer value)
          throws IllegalPropertyValueException {
    ensureNotNull(value);
    ifNull(value);
    // Make sure that we correctly encode negative values as "unlimited".
    if (allowUnlimited) {
@@ -315,7 +316,7 @@
  @Override
  public Integer decodeValue(String value)
      throws IllegalPropertyValueStringException {
    ensureNotNull(value);
    ifNull(value);
    if (allowUnlimited) {
      if (value.trim().equalsIgnoreCase(UNLIMITED)) {