Class MessageUtil


  • public final class MessageUtil
    extends Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void formatMessage​(int type, io.netty.buffer.ByteBuf body, io.netty.buffer.ByteBuf buffer)
      Adds header to message value.
      static org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.multiprotocol.rev180329.update.attributes.MpReachNlri getMpReachNlri​(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev200120.path.attributes.Attributes attrs)
      Finds MP-REACH-NLRI in Update message attributes.
      static org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.multiprotocol.rev180329.update.attributes.MpUnreachNlri getMpUnreachNlri​(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev200120.path.attributes.Attributes attrs)
      Finds MP-UNREACH-NLRI in Update message attributes.
      static boolean isAnyNlriPresent​(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev200120.Update message)
      Check for NLRI attribute in Update message.
    • Method Detail

      • formatMessage

        public static void formatMessage​(int type,
                                         io.netty.buffer.ByteBuf body,
                                         io.netty.buffer.ByteBuf buffer)
        Adds header to message value.
        Parameters:
        type - of the message
        body - message body
        buffer - ByteBuf where the message will be copied with its header
      • isAnyNlriPresent

        public static boolean isAnyNlriPresent​(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev200120.Update message)
        Check for NLRI attribute in Update message.
        Parameters:
        message - Update message
        Returns:
        true if any prefix or MP-REACH-NLRI attribute is present, false otherwise
      • getMpReachNlri

        public static org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.multiprotocol.rev180329.update.attributes.MpReachNlri getMpReachNlri​(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev200120.path.attributes.Attributes attrs)
        Finds MP-REACH-NLRI in Update message attributes.
        Parameters:
        attrs - Update message attributes
        Returns:
        MP-REACH-NLRI if present in the attributes, null otherwise
      • getMpUnreachNlri

        public static org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.multiprotocol.rev180329.update.attributes.MpUnreachNlri getMpUnreachNlri​(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev200120.path.attributes.Attributes attrs)
        Finds MP-UNREACH-NLRI in Update message attributes.
        Parameters:
        attrs - Update message attributes
        Returns:
        MP-UNREACH-NLRI if present in the attributes, null otherwise