本文整理汇总了C#中NPOI.HSSF.Record.RecordInputStream.Read方法的典型用法代码示例。如果您正苦于以下问题:C# RecordInputStream.Read方法的具体用法?C# RecordInputStream.Read怎么用?C# RecordInputStream.Read使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类NPOI.HSSF.Record.RecordInputStream
的用法示例。
在下文中一共展示了RecordInputStream.Read方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: FtrHeader
public FtrHeader(RecordInputStream in1)
{
recordType = in1.ReadShort();
grbitFrt = in1.ReadShort();
reserved = new byte[8];
in1.Read(reserved, 0, 8);
}
示例2: OldSheetRecord
public OldSheetRecord(RecordInputStream in1)
{
field_1_position_of_BOF = in1.ReadInt();
field_2_visibility = in1.ReadUByte();
field_3_type = in1.ReadUByte();
int field_4_sheetname_length = in1.ReadUByte();
field_5_sheetname = new byte[field_4_sheetname_length];
in1.Read(field_5_sheetname, 0, field_4_sheetname_length);
}
示例3: OldStringRecord
/**
* @param in the RecordInputstream to read the record from
*/
public OldStringRecord(RecordInputStream in1)
{
sid = in1.Sid;
if (in1.Sid == biff2_sid)
{
field_1_string_len = (short)in1.ReadUByte();
}
else
{
field_1_string_len = in1.ReadShort();
}
// Can only decode properly later when you know the codepage
field_2_bytes = new byte[field_1_string_len];
in1.Read(field_2_bytes, 0, field_1_string_len);
}
示例4: OldLabelRecord
/**
* @param in the RecordInputstream to read the record from
*/
public OldLabelRecord(RecordInputStream in1)
: base(in1, in1.Sid == biff2_sid)
{
if (IsBiff2)
{
field_4_string_len = (short)in1.ReadUByte();
}
else
{
field_4_string_len = in1.ReadShort();
}
// Can only decode properly later when you know the codepage
field_5_bytes = new byte[field_4_string_len];
in1.Read(field_5_bytes, 0, field_4_string_len);
if (in1.Remaining > 0)
{
logger.Log(POILogger.INFO,
"LabelRecord data remains: " + in1.Remaining +
" : " + HexDump.ToHex(in1.ReadRemainder())
);
}
}
示例5: HyperlinkRecord
/**
* Read hyperlink from input stream
*
* @param in the stream to Read from
*/
public HyperlinkRecord(RecordInputStream in1)
{
try
{
rwFirst = in1.ReadShort();
rwLast = in1.ReadUShort();
colFirst = in1.ReadShort();
colLast = in1.ReadShort();
// 16-byte GUID
guid = new byte[16];
in1.Read(guid, 0, guid.Length);
label_opts = in1.ReadInt();
link_opts = in1.ReadInt();
if ((link_opts & HLINK_LABEL) != 0)
{
int label_len = in1.ReadInt();
label = in1.ReadUnicodeLEString(label_len);
}
if ((link_opts & HLINK_URL) != 0)
{
moniker = new byte[16];
in1.Read(moniker, 0, moniker.Length);
if (Arrays.Equals(URL_MONIKER, moniker))
{
int len = in1.ReadInt();
address = in1.ReadUnicodeLEString( (len - URL_TAIL.Length)/2); //minus the length of tail
tail = in1.ReadRemainder();
}
else if (Arrays.Equals(FILE_MONIKER, moniker))
{
file_opts = in1.ReadShort();
int len = in1.ReadInt();
byte[] path_bytes = new byte[len];
in1.Read(path_bytes, 0, path_bytes.Length);
address = Encoding.UTF8.GetString(path_bytes);
tail = in1.ReadRemainder();
}
}
else if ((link_opts & HLINK_PLACE) != 0)
{
int len = in1.ReadInt();
address = in1.ReadUnicodeLEString(len);
}
}
catch (IOException)
{
throw;
}
}