Class MessageUtil

java.lang.Object
org.opendaylight.protocol.bgp.parser.spi.MessageUtil

public final class MessageUtil extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
     
    static final int
     
  • Method Summary

    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.attributes.reach.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.attributes.unreach.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.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Method Details

    • 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.attributes.reach.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.attributes.unreach.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