@@ -0,0 +1,1970 @@
+/*%0A * Copyright 2017 Real Logic Ltd.%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A * http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A * See the License for the specific language governing permissions and%0A * limitations under the License.%0A */%0Apackage org.agrona.collections;%0A%0Aimport java.io.Serializable;%0A%0A/**%0A * Mutable reference that is useful for capturing an object reference when using lambdas.%0A *%0A * @param %3CT%3E type of the reference.%0A */%0Apublic class MutableReference%3CT%3E implements Serializable%0A%7B%0A    /**%0A     * For convenient access.%0A     */%0A    public T ref;%0A%0A    /**%0A     * Default constructor.%0A     */%0A    public MutableReference()%0A    %7B%0A    %7D%0A%0A    /**%0A     * Set the reference at construction.%0A     *%0A     * @param ref to be set.%0A     */%0A    public MutableReference(final T ref)%0A    %7B%0A        this.ref = ref;%0A    %7D%0A%0A    /**%0A     * Get the current value of the reference.%0A     *%0A     * @return the current value of the reference.%0A     */%0A    public T get()%0A    %7B%0A        return ref;%0A    %7D%0A%0A    /**%0A     * Set the current value of the reference.%0A     *%0A     * @param ref to be set.%0A     */%0A    public void set(final T ref)%0A    %7B%0A        this.ref = ref;%0A    %7D%0A%0A    public boolean equals(final Object o)%0A    %7B%0A        if (this == o)%0A        %7B%0A            return true;%0A        %7D%0A%0A        if (o == null %7C%7C getClass() != o.getClass())%0A        %7B%0A            return false;%0A        %7D%0A%0A        final MutableReference%3C?%3E that = (MutableReference%3C?%3E)o;%0A%0A        return ref != null ? ref.equals(that.ref) : that.ref == null;%0A    %7D%0A%0A    public int hashCode()%0A    %7B%0A        return ref != null ? ref.hashCode() : 0;%0A    %7D%0A%7D%0A

Add MutableReference.