changed API ID order, added xICIC support, added config fields for adm and bearer requests
diff --git a/src/main/java/org.onosproject.xran/codecs/pdu/XICICConfig.java b/src/main/java/org.onosproject.xran/codecs/pdu/XICICConfig.java
index f02d36a..6efe465 100644
--- a/src/main/java/org.onosproject.xran/codecs/pdu/XICICConfig.java
+++ b/src/main/java/org.onosproject.xran/codecs/pdu/XICICConfig.java
@@ -12,9 +12,12 @@
import org.openmuc.jasn1.ber.BerTag;
import org.openmuc.jasn1.ber.types.BerBitString;
import org.openmuc.jasn1.ber.types.BerInteger;
+import org.openmuc.jasn1.ber.types.string.BerUTF8String;
+
import java.io.IOException;
import java.io.InputStream;
import java.io.Serializable;
+import java.io.UnsupportedEncodingException;
public class XICICConfig implements Serializable {
@@ -446,5 +449,26 @@
sb.append("}");
}
+ public static XrancPdu constructPacket(RRMConfig config) {
+ XrancPduBody body = new XrancPduBody();
+ body.setRRMConfig(config);
+
+ BerUTF8String ver = null;
+ try {
+ ver = new BerUTF8String("3");
+ } catch (UnsupportedEncodingException e) {
+ e.printStackTrace();
+ }
+
+ XrancApiID apiID = new XrancApiID(23);
+ XrancPduHdr hdr = new XrancPduHdr();
+ hdr.setVer(ver);
+ hdr.setApiId(apiID);
+
+ XrancPdu pdu = new XrancPdu();
+ pdu.setHdr(hdr);
+ pdu.setBody(body);
+ return pdu;
+ }
}