Search in sources :

Example 1 with ReportedRoute

use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.pcreq.message.pcreq.message.requests.segment.computation.p2p.ReportedRoute in project bgpcep by opendaylight.

the class StatefulPCRequestMessageParser method serializeP2P.

@Override
protected void serializeP2P(final ByteBuf buffer, final P2p p2p) {
    serializeObject(p2p.getEndpointsObj(), buffer);
    serializeVendorInformationObjects(p2p.getVendorInformationObject(), buffer);
    if (p2p.getReportedRoute() != null) {
        final ReportedRoute rr = p2p.getReportedRoute();
        if (rr != null) {
            serializeObject(rr.getRro(), buffer);
            serializeObject(rr.getReoptimizationBandwidth(), buffer);
        }
    }
    serializeObject(p2p.getLoadBalancing(), buffer);
    if (p2p.augmentation(P2p1.class) != null) {
        final P2p1 aug = p2p.augmentation(P2p1.class);
        serializeObject(aug.getLsp(), buffer);
    }
    serializeObject(p2p.getLspa(), buffer);
    serializeObject(p2p.getBandwidth(), buffer);
    for (final Metrics m : p2p.nonnullMetrics()) {
        serializeObject(m.getMetric(), buffer);
    }
    serializeObject(p2p.getIro(), buffer);
    serializeObject(p2p.getRro(), buffer);
    serializeObject(p2p.getXro(), buffer);
    serializeObject(p2p.getOf(), buffer);
    serializeObject(p2p.getClassType(), buffer);
}
Also used : Metrics(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.lsp.attributes.Metrics) P2p1(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.P2p1) ReportedRoute(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.pcreq.message.pcreq.message.requests.segment.computation.p2p.ReportedRoute)

Example 2 with ReportedRoute

use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.pcreq.message.pcreq.message.requests.segment.computation.p2p.ReportedRoute in project bgpcep by opendaylight.

the class PCEPRequestMessageParser method serializeP2P.

protected void serializeP2P(final ByteBuf buffer, final P2p p2p) {
    serializeObject(p2p.getEndpointsObj(), buffer);
    serializeVendorInformationObjects(p2p.getVendorInformationObject(), buffer);
    if (p2p.getReportedRoute() != null) {
        final ReportedRoute rr = p2p.getReportedRoute();
        if (rr != null) {
            serializeObject(rr.getRro(), buffer);
            serializeObject(rr.getReoptimizationBandwidth(), buffer);
        }
    }
    serializeObject(p2p.getLoadBalancing(), buffer);
    serializeObject(p2p.getLspa(), buffer);
    serializeObject(p2p.getBandwidth(), buffer);
    for (final Metrics m : p2p.nonnullMetrics()) {
        serializeObject(m.getMetric(), buffer);
    }
    serializeObject(p2p.getIro(), buffer);
    serializeObject(p2p.getRro(), buffer);
    serializeObject(p2p.getXro(), buffer);
    serializeObject(p2p.getOf(), buffer);
    serializeObject(p2p.getClassType(), buffer);
}
Also used : Metrics(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.lsp.attributes.Metrics) ReportedRoute(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.pcreq.message.pcreq.message.requests.segment.computation.p2p.ReportedRoute)

Aggregations

Metrics (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.lsp.attributes.Metrics)2 ReportedRoute (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.pcreq.message.pcreq.message.requests.segment.computation.p2p.ReportedRoute)2 P2p1 (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.P2p1)1