private SafeAlpcMessageAttributesBuffer(int total_length) : base(total_length, false) { BufferUtils.ZeroBuffer(this); _resources = new DisposableList(); }
internal static SafeBuffer AddNulTerminatedUnicodeString(this DisposableList list, string str) { return(AddBytes(list, Encoding.Unicode.GetBytes(str + "\0"))); }
internal static SafeBuffer AddList <T>(this DisposableList list, IEnumerable <T> values) where T : new() { return(values.ToArray().ToBuffer()); }
internal static SafeStructureInOutBuffer <T> AddStructureRef <T>(this DisposableList list, T value) where T : struct { return(list.AddResource(new SafeStructureInOutBuffer <T>(value))); }