Search in sources :

Example 1 with PcrptMessage

use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.PcrptMessage in project bgpcep by opendaylight.

the class Stateful07TopologySessionListener method onMessage.

@Override
protected synchronized boolean onMessage(final MessageContext ctx, final Message message) {
    if (message instanceof PcerrMessage) {
        return handleErrorMessage((PcerrMessage) message);
    }
    if (!(message instanceof PcrptMessage)) {
        return true;
    }
    this.listenerState.updateLastReceivedRptMsg();
    final org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev171025.pcrpt.message.PcrptMessage rpt = ((PcrptMessage) message).getPcrptMessage();
    for (final Reports report : rpt.getReports()) {
        if (!manageNextReport(report, ctx)) {
            return false;
        }
    }
    return false;
}
Also used : PcrptMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev171025.PcrptMessage) PcerrMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev131005.PcerrMessage) Reports(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev171025.pcrpt.message.pcrpt.message.Reports) StatefulTlv1(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev171025.StatefulTlv1)

Example 2 with PcrptMessage

use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.PcrptMessage in project bgpcep by opendaylight.

the class PCEPTopologySessionListener method onMessage.

@Override
protected synchronized boolean onMessage(final MessageContext ctx, final Message message) {
    if (message instanceof PcerrMessage) {
        return handleErrorMessage((PcerrMessage) message);
    }
    if (message instanceof Pcreq) {
        LOG.info("PcReq detected. Start Request Message handler");
        return handlePcreqMessage(((Pcreq) message).getPcreqMessage());
    }
    if (!(message instanceof PcrptMessage)) {
        return true;
    }
    listenerState.updateLastReceivedRptMsg();
    final org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.pcrpt.message.PcrptMessage rpt = ((PcrptMessage) message).getPcrptMessage();
    for (final Reports report : rpt.getReports()) {
        if (!manageNextReport(report, ctx)) {
            return false;
        }
    }
    return false;
}
Also used : PcrptMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.PcrptMessage) PcerrMessage(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.PcerrMessage) Reports(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.pcrpt.message.pcrpt.message.Reports) Pcreq(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.message.rev181109.Pcreq)

Aggregations

PcrptMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev171025.PcrptMessage)1 StatefulTlv1 (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev171025.StatefulTlv1)1 Reports (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev171025.pcrpt.message.pcrpt.message.Reports)1 PcrptMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.PcrptMessage)1 Reports (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.ietf.stateful.rev200720.pcrpt.message.pcrpt.message.Reports)1 Pcreq (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.message.rev181109.Pcreq)1 PcerrMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev131005.PcerrMessage)1 PcerrMessage (org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.PcerrMessage)1