Search in sources :

Example 6 with MappingCodecRegistrator

use of org.onosproject.mapping.MappingCodecRegistrator in project onos by opennetworkinglab.

the class MappingValueCodecTest method setUp.

/**
 * Sets up for each test.
 * Creates a context and fetches the mapping value codec.
 */
@Before
public void setUp() {
    CodecManager manager = new CodecManager();
    registrator = new MappingCodecRegistrator();
    registrator.codecService = manager;
    registrator.activate();
    context = new MappingCodecContextAdapter(registrator.codecService);
    valueCodec = context.codec(MappingValue.class);
    assertThat(valueCodec, notNullValue());
}
Also used : MappingCodecRegistrator(org.onosproject.mapping.MappingCodecRegistrator) CodecManager(org.onosproject.codec.impl.CodecManager) DefaultMappingValue(org.onosproject.mapping.DefaultMappingValue) MappingValue(org.onosproject.mapping.MappingValue) Before(org.junit.Before)

Example 7 with MappingCodecRegistrator

use of org.onosproject.mapping.MappingCodecRegistrator in project onos by opennetworkinglab.

the class MappingEntryCodecTest method setUp.

/**
 * Sets up for each test.
 * Creates a context and fetches the mapping entry codec.
 */
@Before
public void setUp() {
    CodecManager manager = new CodecManager();
    registrator = new MappingCodecRegistrator();
    registrator.codecService = manager;
    registrator.activate();
    context = new MappingCodecContextAdapter(registrator.codecService);
    entryCodec = context.codec(MappingEntry.class);
    assertThat(entryCodec, notNullValue());
}
Also used : MappingEntry(org.onosproject.mapping.MappingEntry) DefaultMappingEntry(org.onosproject.mapping.DefaultMappingEntry) MappingCodecRegistrator(org.onosproject.mapping.MappingCodecRegistrator) CodecManager(org.onosproject.codec.impl.CodecManager) Before(org.junit.Before)

Example 8 with MappingCodecRegistrator

use of org.onosproject.mapping.MappingCodecRegistrator in project onos by opennetworkinglab.

the class MappingTreatmentCodecTest method setUp.

/**
 * Sets up for each test.
 * Creates a context and fetches the mapping action codec.
 */
@Before
public void setUp() {
    CodecManager manager = new CodecManager();
    registrator = new MappingCodecRegistrator();
    registrator.codecService = manager;
    registrator.activate();
    context = new MappingCodecContextAdapter(registrator.codecService);
    treatmentCodec = context.codec(MappingTreatment.class);
    assertThat(treatmentCodec, notNullValue());
}
Also used : MappingCodecRegistrator(org.onosproject.mapping.MappingCodecRegistrator) CodecManager(org.onosproject.codec.impl.CodecManager) MappingTreatment(org.onosproject.mapping.MappingTreatment) DefaultMappingTreatment(org.onosproject.mapping.DefaultMappingTreatment) Before(org.junit.Before)

Aggregations

MappingCodecRegistrator (org.onosproject.mapping.MappingCodecRegistrator)8 Before (org.junit.Before)7 CodecManager (org.onosproject.codec.impl.CodecManager)7 LispAppDataAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispAppDataAddressCodec)1 LispAsAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispAsAddressCodec)1 LispGcAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispGcAddressCodec)1 LispListAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispListAddressCodec)1 LispMulticastAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispMulticastAddressCodec)1 LispNatAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispNatAddressCodec)1 LispNonceAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispNonceAddressCodec)1 LispSegmentAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispSegmentAddressCodec)1 LispSrcDstAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispSrcDstAddressCodec)1 LispTeAddressCodec (org.onosproject.drivers.lisp.extensions.codec.LispTeAddressCodec)1 LispTeRecordCodec (org.onosproject.drivers.lisp.extensions.codec.LispTeRecordCodec)1 DefaultMappingEntry (org.onosproject.mapping.DefaultMappingEntry)1 DefaultMappingKey (org.onosproject.mapping.DefaultMappingKey)1 DefaultMappingTreatment (org.onosproject.mapping.DefaultMappingTreatment)1 DefaultMappingValue (org.onosproject.mapping.DefaultMappingValue)1 MappingEntry (org.onosproject.mapping.MappingEntry)1 MappingKey (org.onosproject.mapping.MappingKey)1