/** * Adds AVP to {@link AvpSet} as UTF8String with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsUTF8String(Object parent, int avpCode, long vendorId, AvpSet set, String value) { AvpRepresentation rep = getAvpRepresentation(avpCode, vendorId); if (rep != null) { setAvpAsUTF8String(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsUTF8String(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as OctetString with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsOctetString(Object parent, int avpCode, long vendorId, AvpSet set, String value) { AvpRepresentation rep = getAvpRepresentation(avpCode, vendorId); if (rep != null) { setAvpAsOctetString(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsOctetString(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as OctetString with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsOctetString(Object parent, int avpCode, long vendorId, AvpSet set, String value) { AvpRepresentation rep = getAvpRepresentation(avpCode, vendorId); if (rep != null) { setAvpAsOctetString(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsOctetString(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Unsigned64 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsUnsigned64(Object parent, int avpCode, long vendorId, AvpSet set, long value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsUnsigned64(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsUnsigned64(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Float64 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsFloat64(Object parent, int avpCode, long vendorId, AvpSet set, double value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsFloat64(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsFloat64(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Integer32 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsInteger32(Object parent, int avpCode, long vendorId, AvpSet set, int value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsInteger32(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsInteger32(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Float64 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsFloat64(Object parent, int avpCode, long vendorId, AvpSet set, double value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsFloat64(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsFloat64(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Unsigned32 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsUnsigned32(Object parent, int avpCode, long vendorId, AvpSet set, long value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsUnsigned32(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsUnsigned32(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Integer32 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsInteger32(Object parent, int avpCode, long vendorId, AvpSet set, int value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsInteger32(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsInteger32(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Grouped with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the Vendor-Id of the AVP * @param value the value of the AVP to add */ public static AvpSet setAvpAsGrouped(Object parent, int avpCode, long vendorId, AvpSet set, DiameterAvp[] childs) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { return setAvpAsGrouped(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), childs); } else { return setAvpAsGrouped(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, childs); } }
/** * Adds AVP to {@link AvpSet} as Unsigned64 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsUnsigned64(Object parent, int avpCode, long vendorId, AvpSet set, long value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsUnsigned64(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsUnsigned64(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Grouped with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the Vendor-Id of the AVP * @param childs the value of the AVP to add */ public static AvpSet setAvpAsGrouped(Object parent, int avpCode, long vendorId, AvpSet set, DiameterAvp[] childs) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { return setAvpAsGrouped(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), childs); } else { return setAvpAsGrouped(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, childs); } }
/** * Adds AVP to {@link AvpSet} as Integer64 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsInteger64(Object parent, int avpCode, long vendorId, AvpSet set, long value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsInteger64(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsInteger64(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as raw data with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsRaw(Object parent, int avpCode, long vendorId, AvpSet set, byte[] value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsRaw(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsRaw(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as UTF8String with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsUTF8String(Object parent, int avpCode, long vendorId, AvpSet set, String value) { AvpRepresentation rep = getAvpRepresentation(avpCode, vendorId); if (rep != null) { setAvpAsUTF8String(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsUTF8String(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Unsigned32 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsUnsigned32(Object parent, int avpCode, long vendorId, AvpSet set, long value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsUnsigned32(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsUnsigned32(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Integer64 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsInteger64(Object parent, int avpCode, long vendorId, AvpSet set, long value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsInteger64(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsInteger64(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Float32 with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsFloat32(Object parent, int avpCode, long vendorId, AvpSet set, float value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsFloat32(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsFloat32(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as Time with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the Vendor-Id of the AVP * @param value the value of the AVP to add */ public static void setAvpAsTime(Object parent, int avpCode, long vendorId, AvpSet set, Date value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsTime(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsTime(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }
/** * Adds AVP to {@link AvpSet} as raw data with the given code and given Vendor-Id. * * @param parent the Message/Grouped AVP where AVP will be added to, for validation purposes. if null, no validation is performed. * @param avpCode the code of the AVP * @param vendorId the Vendor-Id of the AVP * @param set the AvpSet to add AVP * @param value the value of the AVP to add */ public static void setAvpAsRaw(Object parent, int avpCode, long vendorId, AvpSet set, byte[] value) { AvpRepresentation rep = AvpDictionary.INSTANCE.getAvp(avpCode, vendorId); if (rep != null) { setAvpAsRaw(parent, avpCode, vendorId, set, rep.isMandatory(), rep.isProtected(), value); } else { setAvpAsRaw(parent, avpCode, vendorId, set, _DEFAULT_MANDATORY, _DEFAULT_PROTECTED, value); } }