001/*
002 * Copyright 2011-2019 Ping Identity Corporation
003 * All Rights Reserved.
004 */
005/*
006 * Copyright (C) 2015-2019 Ping Identity Corporation
007 *
008 * This program is free software; you can redistribute it and/or modify
009 * it under the terms of the GNU General Public License (GPLv2 only)
010 * or the terms of the GNU Lesser General Public License (LGPLv2.1 only)
011 * as published by the Free Software Foundation.
012 *
013 * This program is distributed in the hope that it will be useful,
014 * but WITHOUT ANY WARRANTY; without even the implied warranty of
015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
016 * GNU General Public License for more details.
017 *
018 * You should have received a copy of the GNU General Public License
019 * along with this program; if not, see <http://www.gnu.org/licenses>.
020 */
021package com.unboundid.ldap.sdk.unboundidds;
022
023
024
025import com.unboundid.util.LDAPSDKException;
026import com.unboundid.util.NotMutable;
027import com.unboundid.util.ThreadSafety;
028import com.unboundid.util.ThreadSafetyLevel;
029
030
031
032/**
033 * This class provides an exception that may be thrown when attempting to obtain
034 * the value of an updated attribute as it appeared before or after a change
035 * was processed, but the number of values for that attribute exceeded the
036 * maximum number to include in a changelog entry.
037 * <BR>
038 * <BLOCKQUOTE>
039 *   <B>NOTE:</B>  This class, and other classes within the
040 *   {@code com.unboundid.ldap.sdk.unboundidds} package structure, are only
041 *   supported for use against Ping Identity, UnboundID, and
042 *   Nokia/Alcatel-Lucent 8661 server products.  These classes provide support
043 *   for proprietary functionality or for external specifications that are not
044 *   considered stable or mature enough to be guaranteed to work in an
045 *   interoperable way with other types of LDAP servers.
046 * </BLOCKQUOTE>
047 */
048@NotMutable()
049@ThreadSafety(level=ThreadSafetyLevel.COMPLETELY_THREADSAFE)
050public final class ChangeLogEntryAttributeExceededMaxValuesException
051       extends LDAPSDKException
052{
053  /**
054   * The serial version UID for this serializable class.
055   */
056  private static final long serialVersionUID = -9108989779921909512L;
057
058
059
060  // The object providing information about the attribute that had more values
061  // than could be included in a changelog entry.
062  private final ChangeLogEntryAttributeExceededMaxValuesCount attrInfo;
063
064
065
066  /**
067   * Creates a new instance of this exception with the provided object.
068   *
069   * @param  message   The message to use for the exception.
070   * @param  attrInfo  An object providing information about the attribute that
071   *                   had more values than could be included in a changelog
072   *                   entry before and/or after the change was processed.
073   */
074  public ChangeLogEntryAttributeExceededMaxValuesException(
075              final String message,
076              final ChangeLogEntryAttributeExceededMaxValuesCount attrInfo)
077  {
078    super(message);
079
080    this.attrInfo = attrInfo;
081  }
082
083
084
085  /**
086   * Retrieves an object providing information about the attribute that had more
087   * values than could be included in a changelog entry before and/or after the
088   * change was processed.
089   *
090   * @return  An object providing information about the attribute that had more
091   *          values than could be included in a changelog entry before and/or
092   *          after the change was processed.
093   */
094  public ChangeLogEntryAttributeExceededMaxValuesCount getAttributeInfo()
095  {
096    return attrInfo;
097  }
098}