001/*
002 * CDDL HEADER START
003 *
004 * The contents of this file are subject to the terms of the
005 * Common Development and Distribution License, Version 1.0 only
006 * (the "License").  You may not use this file except in compliance
007 * with the License.
008 *
009 * You can obtain a copy of the license at legal-notices/CDDLv1_0.txt
010 * or http://forgerock.org/license/CDDLv1.0.html.
011 * See the License for the specific language governing permissions
012 * and limitations under the License.
013 *
014 * When distributing Covered Code, include this CDDL HEADER in each
015 * file and include the License file at legal-notices/CDDLv1_0.txt.
016 * If applicable, add the following below this CDDL HEADER, with the
017 * fields enclosed by brackets "[]" replaced with your own identifying
018 * information:
019 *      Portions Copyright [yyyy] [name of copyright owner]
020 *
021 * CDDL HEADER END
022 *
023 *
024 *      Portions Copyright 2013-2014 ForgeRock AS
025 */
026package org.opends.server.core;
027
028import org.forgerock.opendj.ldap.ByteString;
029
030/**
031 * This abstract class wraps/decorates a given extended operation. This class
032 * will be extended by sub-classes to enhance the functionality of the
033 * ExtendedOperationBasis.
034 */
035public abstract class ExtendedOperationWrapper extends
036    OperationWrapper<ExtendedOperation> implements ExtendedOperation
037{
038
039  /**
040   * Creates a new extended operation wrapper based on the provided extended
041   * operation.
042   *
043   * @param extended
044   *          The extended operation to wrap
045   */
046  public ExtendedOperationWrapper(ExtendedOperation extended)
047  {
048    super(extended);
049  }
050
051  /** {@inheritDoc} */
052  @Override
053  public String getRequestOID()
054  {
055    return getOperation().getRequestOID();
056  }
057
058  /** {@inheritDoc} */
059  @Override
060  public String getResponseOID()
061  {
062    return getOperation().getResponseOID();
063  }
064
065  /** {@inheritDoc} */
066  @Override
067  public ByteString getRequestValue()
068  {
069    return getOperation().getRequestValue();
070  }
071
072  /** {@inheritDoc} */
073  @Override
074  public ByteString getResponseValue()
075  {
076    return getOperation().getResponseValue();
077  }
078
079  /** {@inheritDoc} */
080  @Override
081  public void setResponseOID(String responseOID)
082  {
083    getOperation().setResponseOID(responseOID);
084  }
085
086  /** {@inheritDoc} */
087  @Override
088  public void setResponseValue(ByteString responseValue)
089  {
090    getOperation().setResponseValue(responseValue);
091  }
092
093}