From 2c84a9a15801413ec76ec071ca57dcb3fe9bcc4e Mon Sep 17 00:00:00 2001 From: Ray Milkey Date: Wed, 5 Sep 2018 17:40:39 -0700 Subject: [PATCH] Remove deprecated fit() API Change-Id: I693389c0c40c0c6fc4d8fabf78307c9acc84b247 --- .../org/onlab/util/ImmutableByteSequence.java | 22 ------------------- 1 file changed, 22 deletions(-) diff --git a/utils/misc/src/main/java/org/onlab/util/ImmutableByteSequence.java b/utils/misc/src/main/java/org/onlab/util/ImmutableByteSequence.java index fea71a7219..cdd3691950 100644 --- a/utils/misc/src/main/java/org/onlab/util/ImmutableByteSequence.java +++ b/utils/misc/src/main/java/org/onlab/util/ImmutableByteSequence.java @@ -414,28 +414,6 @@ public final class ImmutableByteSequence { return doFit(this, bitWidth); } - /** - * Trims or expands the given byte sequence so to fit a given bit-width. - * When trimming, the operations is deemed to be safe only if the trimmed - * bits are zero, i.e. it is safe to trim only when {@code bitWidth > - * msbIndex()}, otherwise an exception will be thrown. When expanding, the - * sequence will be padded with zeros. The returned byte sequence will have - * minimum size to contain the given bit-width. - * - * @param original a byte sequence - * @param bitWidth a non-zero positive integer - * @return a new byte sequence - * @throws ByteSequenceTrimException if the byte sequence cannot be fitted - * @deprecated in ONOS 1.13, use {@link ImmutableByteSequence#fit(int)} - * instead. - */ - @Deprecated - public static ImmutableByteSequence fit(ImmutableByteSequence original, - int bitWidth) - throws ByteSequenceTrimException { - return doFit(original, bitWidth); - } - private static ImmutableByteSequence doFit(ImmutableByteSequence original, int bitWidth) throws ByteSequenceTrimException {