private static void InternalWriteString(MsgSubStorageWriter writer, TnefPropertyTag propertyTag, string value)
        {
            MsgSubStorageWriter.WriterBuffer valueBuffer = writer.ValueBuffer;
            int unicodeByteCount = Util.GetUnicodeByteCount(value);

            byte[] array = valueBuffer.PreallocateBuffer(unicodeByteCount);
            int    num   = Util.StringToUnicodeBytes(value, array);

            writer.Storage.WriteBytesToStream(Util.PropertyStreamName(propertyTag), array, num);
            MsgStoragePropertyData.WriteStream(writer.PropertiesWriter, propertyTag, num);
        }
        private static void InternalWriteStringArray(MsgSubStorageWriter writer, TnefPropertyTag propertyTag, string[] arrayValue)
        {
            MsgSubStorageWriter.WriterBuffer lengthsBuffer = writer.LengthsBuffer;
            for (int num = 0; num != arrayValue.Length; num++)
            {
                MsgSubStorageWriter.WriterBuffer valueBuffer = writer.ValueBuffer;
                int    unicodeByteCount = Util.GetUnicodeByteCount(arrayValue[num]);
                byte[] array            = valueBuffer.PreallocateBuffer(unicodeByteCount);
                int    num2             = Util.StringToUnicodeBytes(arrayValue[num], array);
                lengthsBuffer.Writer.Write(num2);
                writer.Storage.WriteBytesToStream(Util.PropertyStreamName(propertyTag, num), array, num2);
            }
            int length = lengthsBuffer.GetLength();

            byte[] buffer = lengthsBuffer.GetBuffer();
            writer.Storage.WriteBytesToStream(Util.PropertyStreamName(propertyTag), buffer, length);
            MsgStoragePropertyData.WriteStream(writer.PropertiesWriter, propertyTag, length);
        }