@@ -0,0 +1,2357 @@
+package org.apache.cassandra.utils;%0A/*%0A * %0A * Licensed to the Apache Software Foundation (ASF) under one%0A * or more contributor license agreements.  See the NOTICE file%0A * distributed with this work for additional information%0A * regarding copyright ownership.  The ASF licenses this file%0A * to you under the Apache License, Version 2.0 (the%0A * %22License%22); you may not use this file except in compliance%0A * with the License.  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,%0A * software distributed under the License is distributed on an%0A * %22AS IS%22 BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY%0A * KIND, either express or implied.  See the License for the%0A * specific language governing permissions and limitations%0A * under the License.%0A * %0A */%0A%0A%0Aimport java.io.DataInput;%0Aimport java.io.DataOutput;%0Aimport java.io.IOException;%0Aimport java.util.ArrayList;%0Aimport java.util.List;%0A%0A/**%0A * Serialize a list of byte%5B%5D objects.%0A * This may be more appropriate inside FBUtilities.%0A * @author tzlatanov%0A *%0A */%0Apublic class ByteArrayListSerializer%0A%7B%0A    public static void serialize(List%3Cbyte%5B%5D%3E bitmasks, DataOutput dos)%0A    %7B%0A        try%0A        %7B%0A            if (bitmasks == null)%0A            %7B%0A                dos.writeInt(-1);%0A            %7D%0A            else%0A            %7B%0A                dos.writeInt(bitmasks.size());%0A                for (byte%5B%5D bitmask: bitmasks)%0A                %7B%0A                    FBUtilities.writeByteArray(bitmask, dos);%0A                %7D%0A            %7D%0A        %7D%0A        catch (IOException e)%0A        %7B%0A            throw new RuntimeException(e);%0A        %7D%0A    %7D%0A%0A    public static List%3Cbyte%5B%5D%3E deserialize(DataInput dis) throws IOException%0A    %7B%0A        int size = dis.readInt();%0A%0A        if (-1 == size) return null;%0A%0A        List%3Cbyte%5B%5D%3E bitmasks = new ArrayList%3Cbyte%5B%5D%3E(size);%0A%0A        for (int i=0; i %3C size; i++)%0A        %7B%0A            int length = dis.readInt();%0A            if (length %3C 0)%0A            %7B%0A                throw new IOException(%22Corrupt (negative) value length encountered%22);%0A            %7D%0A            byte%5B%5D value = new byte%5Blength%5D;%0A            if (length %3E 0)%0A            %7B%0A                dis.readFully(value);%0A            %7D%0A            bitmasks.add(value);%0A        %7D%0A%0A        return bitmasks;%0A    %7D%0A%7D%0A

add missing ByteArrayListSerializer class