Class Util


  • public final class Util
    extends Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void writeShortest​(org.opendaylight.yangtools.yang.common.Uint16 value, io.netty.buffer.ByteBuf buffer)
      Given an uint16, this method instead of writing the value in 2B field, compresses the value to lowest required byte field depending on the value.
      static void writeShortest​(org.opendaylight.yangtools.yang.common.Uint32 value, io.netty.buffer.ByteBuf buffer)
      Given an uint32, this method instead of writing the value in 4B field, compresses the value to lowest required byte field depending on the value.
    • Method Detail

      • writeShortest

        public static void writeShortest​(org.opendaylight.yangtools.yang.common.Uint16 value,
                                         io.netty.buffer.ByteBuf buffer)
        Given an uint16, this method instead of writing the value in 2B field, compresses the value to lowest required byte field depending on the value.
        Parameters:
        value - uint16 to be written
        buffer - ByteBuf where the value will be written
      • writeShortest

        public static void writeShortest​(org.opendaylight.yangtools.yang.common.Uint32 value,
                                         io.netty.buffer.ByteBuf buffer)
        Given an uint32, this method instead of writing the value in 4B field, compresses the value to lowest required byte field depending on the value.
        Parameters:
        value - uint32 to be written
        buffer - ByteBuf where the value will be written