本文整理汇总了C#中ILittleEndianOutput.Write方法的典型用法代码示例。如果您正苦于以下问题:C# ILittleEndianOutput.Write方法的具体用法?C# ILittleEndianOutput.Write怎么用?C# ILittleEndianOutput.Write使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ILittleEndianOutput
的用法示例。
在下文中一共展示了ILittleEndianOutput.Write方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Serialize
public void Serialize(ILittleEndianOutput out1)
{
out1.WriteInt(fSD);
out1.WriteInt(passwordVerifier);
StringUtil.WriteUnicodeString(out1, title);
out1.Write(securityDescriptor);
}
示例2: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
out1.WriteShort(rt);
out1.WriteShort(grbitFrt);
out1.WriteShort(iObjectKind);
// 6 bytes unused
out1.Write(reserved);
}
示例3: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
out1.WriteShort(rt);
out1.WriteShort(grbitFrt);
out1.Write(unused);
out1.WriteInt(cts);
out1.WriteShort(rgchDefListStyle.Length);
out1.WriteShort(rgchDefPivotStyle.Length);
StringUtil.PutUnicodeLE(rgchDefListStyle, out1);
StringUtil.PutUnicodeLE(rgchDefPivotStyle, out1);
}
示例4: Serialize
/**
* spit the record out AS IS. no interpretation or identification
*/
public override void Serialize(ILittleEndianOutput out1)
{
out1.Write(_rawData);
}
示例5: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
out1.Write(field_1_data);
}
示例6: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
String username = Username;
bool is16bit = StringUtil.HasMultibyte(username);
out1.WriteShort(username.Length);
out1.WriteByte(is16bit ? 0x01 : 0x00);
if (is16bit)
{
StringUtil.PutUnicodeLE(username, out1);
}
else
{
StringUtil.PutCompressedUnicode(username, out1);
}
int encodedByteCount = 3 + username.Length * (is16bit ? 2 : 1);
int paddingSize = DATA_SIZE - encodedByteCount;
out1.Write(PADDING, 0, paddingSize);
}
示例7: PutCompressedUnicode
public static void PutCompressedUnicode(String input, ILittleEndianOutput out1)
{
byte[] bytes = ISO_8859_1.GetBytes(input);
out1.Write(bytes);
}
示例8: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
int formulaSize = field_2_refPtg == null ? field_2_unknownFormulaData.Length : field_2_refPtg.Size;
int idOffset = GetStreamIDOffset(formulaSize);
int dataSize = GetDataSize(idOffset);
out1.WriteShort(sid);
out1.WriteShort(dataSize);
out1.WriteShort(idOffset);
out1.WriteShort(formulaSize);
out1.WriteInt(field_1_unknown_int);
int pos = 12;
if (field_2_refPtg == null)
{
out1.Write(field_2_unknownFormulaData);
}
else
{
field_2_refPtg.Write(out1);
}
pos += formulaSize;
int stringLen;
if (field_4_ole_classname == null)
{
// don't write 0x03, stringLen, flag, text
stringLen = 0;
}
else
{
out1.WriteByte(0x03);
pos += 1;
stringLen = field_4_ole_classname.Length;
out1.WriteShort(stringLen);
pos += 2;
if (stringLen > 0)
{
out1.WriteByte(field_3_unicode_flag ? 0x01 : 0x00);
pos += 1;
if (field_3_unicode_flag)
{
StringUtil.PutUnicodeLE(field_4_ole_classname, out1);
pos += stringLen * 2;
}
else
{
StringUtil.PutCompressedUnicode(field_4_ole_classname, out1);
pos += stringLen;
}
}
}
// pad to next 2-byte boundary (requires 0 or 1 bytes)
switch (idOffset - (pos - 6 ))
{ // 6 for 3 shorts: sid, dataSize, idOffset
case 1:
out1.WriteByte(field_4_unknownByte == null ? 0x00 : (int)Convert.ToByte(field_4_unknownByte, CultureInfo.InvariantCulture));
pos++;
break;
case 0:
break;
default:
throw new InvalidOperationException("Bad padding calculation (" + idOffset + ", " + pos + ")");
}
if (field_5_stream_id != null)
{
out1.WriteInt(Convert.ToInt32(field_5_stream_id, CultureInfo.InvariantCulture));
pos += 4;
}
out1.Write(field_6_unknown);
}
示例9: Serialize
public void Serialize(ILittleEndianOutput out1)
{
out1.WriteShort(recordType);
out1.WriteShort(grbitFrt);
out1.Write(reserved);
}
示例10: SerializeTokens
public void SerializeTokens(ILittleEndianOutput out1)
{
out1.Write(_byteEncoding, 0, _encodedTokenLen);
}
示例11: SerializeArrayConstantData
public void SerializeArrayConstantData(ILittleEndianOutput out1)
{
int len = _byteEncoding.Length - _encodedTokenLen;
out1.Write(_byteEncoding, _encodedTokenLen, len);
}
示例12: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
out1.WriteShort(_encryptionType);
out1.WriteShort(_encryptionInfo);
out1.WriteShort(_minorVersionNo);
out1.Write(_docId);
out1.Write(_saltData);
out1.Write(_saltHash);
}
示例13: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
futureHeader.Serialize(out1);
out1.WriteShort(isf_sharedFeatureType);
out1.WriteByte(reserved);
out1.WriteInt((int)cbHdrData);
out1.Write(rgbHdrData);
}
示例14: WriteTail
private static void WriteTail(byte[] tail, ILittleEndianOutput out1)
{
out1.Write(tail);
}
示例15: Serialize
public override void Serialize(ILittleEndianOutput out1)
{
out1.WriteShort(rt);
out1.WriteShort(grbitFrt);
out1.Write(unused);
}