Search in sources :

Example 1 with DefaultReferralBuilder

use of org.onosproject.lisp.msg.protocols.DefaultLispReferral.DefaultReferralBuilder in project onos by opennetworkinglab.

the class DefaultLispReferralTest method setup.

@Before
public void setup() {
    ReferralBuilder builder1 = new DefaultReferralBuilder();
    LispIpv4Address ipv4Address1 = new LispIpv4Address(IpAddress.valueOf(IP_ADDRESS1));
    referral1 = builder1.withPriority((byte) 0x01).withWeight((byte) 0x01).withMulticastPriority((byte) 0x01).withMulticastWeight((byte) 0x01).withLocalLocator(true).withRlocProbed(false).withRouted(true).withLocatorAfi(ipv4Address1).build();
    ReferralBuilder builder2 = new DefaultReferralBuilder();
    sameAsReferral1 = builder2.withPriority((byte) 0x01).withWeight((byte) 0x01).withMulticastPriority((byte) 0x01).withMulticastWeight((byte) 0x01).withLocalLocator(true).withRlocProbed(false).withRouted(true).withLocatorAfi(ipv4Address1).build();
    ReferralBuilder builder3 = new DefaultReferralBuilder();
    LispIpv4Address ipv4Address2 = new LispIpv4Address(IpAddress.valueOf(IP_ADDRESS2));
    referral2 = builder3.withPriority((byte) 0x02).withWeight((byte) 0x02).withMulticastPriority((byte) 0x02).withMulticastWeight((byte) 0x02).withLocalLocator(false).withRlocProbed(true).withRouted(false).withLocatorAfi(ipv4Address2).build();
}
Also used : LispIpv4Address(org.onosproject.lisp.msg.types.LispIpv4Address) ReferralBuilder(org.onosproject.lisp.msg.protocols.LispReferral.ReferralBuilder) DefaultReferralBuilder(org.onosproject.lisp.msg.protocols.DefaultLispReferral.DefaultReferralBuilder) DefaultReferralBuilder(org.onosproject.lisp.msg.protocols.DefaultLispReferral.DefaultReferralBuilder) Before(org.junit.Before)

Aggregations

Before (org.junit.Before)1 DefaultReferralBuilder (org.onosproject.lisp.msg.protocols.DefaultLispReferral.DefaultReferralBuilder)1 ReferralBuilder (org.onosproject.lisp.msg.protocols.LispReferral.ReferralBuilder)1 LispIpv4Address (org.onosproject.lisp.msg.types.LispIpv4Address)1