use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.pcep.sync.optimizations.rev200720.Stateful1Builder in project bgpcep by opendaylight.
the class SyncOptimizationsCapabilityTlvParser method parseFlags.
@Override
protected void parseFlags(final StatefulBuilder sb, final ByteBuf buffer) {
final BitArray flags = BitArray.valueOf(buffer, FLAGS_F_LENGTH);
sb.setLspUpdateCapability(flags.get(U_FLAG_OFFSET));
if (flags.get(I_FLAG_OFFSET)) {
sb.addAugmentation(new Stateful1Builder().setInitiation(Boolean.TRUE).build());
}
final org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.pcep.sync.optimizations.rev200720.Stateful1Builder syncOptBuilder = new org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.controller.pcep.sync.optimizations.rev200720.Stateful1Builder();
if (flags.get(S_FLAG_OFFSET)) {
syncOptBuilder.setIncludeDbVersion(Boolean.TRUE);
}
if (flags.get(T_FLAG_OFFSET)) {
syncOptBuilder.setTriggeredResync(Boolean.TRUE);
}
if (flags.get(D_FLAG_OFFSET)) {
syncOptBuilder.setDeltaLspSyncCapability(Boolean.TRUE);
}
if (flags.get(F_FLAG_OFFSET)) {
syncOptBuilder.setTriggeredInitialSync(Boolean.TRUE);
}
sb.addAugmentation(syncOptBuilder.build());
}
Aggregations