package com.lumaserv.bgp.protocol.attribute; import lombok.Getter; import lombok.Setter; import com.lumaserv.bgp.protocol.AFI; import com.lumaserv.bgp.protocol.SAFI; import java.nio.ByteBuffer; @Getter @Setter public class MPUnreachableNLRIAttribute implements PathAttribute { AFI afi; SAFI safi; int nlriLen; public MPUnreachableNLRIAttribute(byte typeCode, byte[] data) { afi = AFI.fromInteger((data[0] << 8) | data[1]); safi = SAFI.fromInteger(data[2]); nlriLen = data.length - 3; } public byte getTypeCode() { return 15; } public void build(ByteBuffer b) { // FIXME } public String toString() { return "AFI:" + afi + " SAFI:" + safi + " NLRIs:" + nlriLen; } }