C# Class FSSHTTPandWOPIInspector.Parsers.BaseStructure

Afficher le fichier Open project: OfficeDev/Office-Inspectors-for-Fiddler

Méthodes publiques

Méthode Description
AddNumberForTreeNode ( TreeNode treenode, int index ) : TreeNode

Add a number attribute for treenode

AddserialNumForFSSHTTPBTreeNode ( TreeNode treenode, int &index ) : TreeNode

Add a serial number only for treenodes which are FSSHTTPB structures

ArrayObjectToNode ( object obj, object parentobj, FieldInfo Info, int &startIndex, int &offset ) : TreeNode

Convert object array to TreeNode

ArrayObjectToNode ( object obj, string name ) : TreeNode

Convert object array to TreeNode

ContainsStreamObjectHeader ( ushort headerType ) : bool

specify whether stream contains Stream Object Header

ContainsStreamObjectStart32BitHeader ( ushort headerType ) : bool

specify whether stream contains Stream Object Start 32Bit Header

GetBigEnidan ( int byteNumber ) : long

read bytes from stream to long in big enidan.

GetBits ( byte b, int index, int length ) : byte

Read bits value from byte

GetBits ( int b, int index, int length ) : uint

Read bits value from byte

GetBits ( long b, int index, int length ) : ulong

Read bits value from byte

GetBits ( short b, int index, int length ) : ushort

Read bits value from byte

GetExtendedGUIDBytesLen ( int byteOffset ) : int

Get the length of the ExtenedGUID

GetSerialNumberBytesLen ( int byteOffset ) : int

Get the length of the SerialNumber

ObjectToTreeNode ( object obj, int &startIndex, int &offset ) : TreeNode

Add the object to TreeNode and calculate the byte number it consumed

ObjectToTreeNode ( object obj, string ropNameforBinaryStrucutre ) : TreeNode

Convert object to TreeNode

Parse ( Stream s ) : void

Parse stream to specific message

PreReadDataElementPackageType ( ) : long

Get DataElementPackage Type

ReadCompactUnsigned64bitIntegerValue ( int byteOffset ) : long

Read CompactUnsigned64bitInteger from stream

ReadINT64 ( ) : long

Read an long value from stream

RemoveAnySpecifiedTreeNode ( TreeNode treenode ) : TreeNode

Remove subNode which node text contains "specified"

RemoveDefaultValueTreeNode ( TreeNode &node, string specifiedText ) : void

Remove subNode which contains defaut value(for optinal element)

SimpleTypeObjectToNode ( object obj, object parentobj, FieldInfo Info, int &startIndex, int &offset ) : TreeNode

Convert simple type object to TreeNode

SimpleTypeObjectToNode ( object obj, string name ) : TreeNode

Convert simple type object to TreeNode

ToString ( ) : string

Override the ToString method to return empty.

Méthodes protégées

Méthode Description
CurrentByte ( ) : byte

Get the current byte of stream

Read3Bytes ( ) : int

Read an three bytes value as uint from stream

Read5Bytes ( ) : long

Read an five bytes value as ulong from stream

Read6Bytes ( ) : long

Read an six bytes value as ulong from stream

Read7Bytes ( ) : long

Read an seven bytes value as ulong from stream

ReadBoolean ( ) : System.Boolean

Read an Boolean value from stream

ReadByte ( ) : byte

Read a byte value from stream

ReadBytes ( int length ) : byte[]

Read bytes from stream

ReadChar ( Encoding encoding ) : char

Read character from stream

ReadGuid ( ) : System.Guid

Read a GUID value from stream

ReadINT16 ( ) : Int16

Read an Int16 value from stream

ReadINT32 ( ) : Int32

Read an Int32 value from stream

ReadString ( Encoding encoding, string terminator = "\0", int stringlength, bool reducedUnicode = false ) : string

Read string value from stream according to string terminator and Encoding method

ReadUint ( ) : uint

Read an uint value from stream

ReadUlong ( ) : ulong

Read an uLong value from stream

ReadUshort ( ) : ushort

Read an ushort value from stream

Private Methods

Méthode Description
ConvertFromBytes ( byte buffer, int bytesToConvert ) : ulong

Returns a value built from the specified number of bytes from the given buffer

Method Details

AddNumberForTreeNode() public static méthode

Add a number attribute for treenode
public static AddNumberForTreeNode ( TreeNode treenode, int index ) : TreeNode
treenode System.Windows.Forms.TreeNode treenode which used to add number
index int the number
Résultat System.Windows.Forms.TreeNode

AddserialNumForFSSHTTPBTreeNode() public static méthode

Add a serial number only for treenodes which are FSSHTTPB structures
public static AddserialNumForFSSHTTPBTreeNode ( TreeNode treenode, int &index ) : TreeNode
treenode System.Windows.Forms.TreeNode treenode which used to add serial number
index int the serial number
Résultat System.Windows.Forms.TreeNode

ArrayObjectToNode() public static méthode

Convert object array to TreeNode
public static ArrayObjectToNode ( object obj, object parentobj, FieldInfo Info, int &startIndex, int &offset ) : TreeNode
obj object The object which need to convert
parentobj object The parent object of the object which need to convert
Info System.Reflection.FieldInfo The field Info of the object in parent object
startIndex int The start index of this object in message stream
offset int The offset of this object
Résultat System.Windows.Forms.TreeNode

ArrayObjectToNode() public static méthode

Convert object array to TreeNode
public static ArrayObjectToNode ( object obj, string name ) : TreeNode
obj object The object which need to convert
name string The name of the node
Résultat System.Windows.Forms.TreeNode

ContainsStreamObjectHeader() public méthode

specify whether stream contains Stream Object Header
public ContainsStreamObjectHeader ( ushort headerType ) : bool
headerType ushort a ushort indicate the type of the stream object header
Résultat bool

ContainsStreamObjectStart32BitHeader() public méthode

specify whether stream contains Stream Object Start 32Bit Header
public ContainsStreamObjectStart32BitHeader ( ushort headerType ) : bool
headerType ushort a ushort indicate the type of the 32 bit stream object header
Résultat bool

CurrentByte() protected méthode

Get the current byte of stream
protected CurrentByte ( ) : byte
Résultat byte

GetBigEnidan() public méthode

read bytes from stream to long in big enidan.
public GetBigEnidan ( int byteNumber ) : long
byteNumber int byte number need to read
Résultat long

GetBits() public méthode

Read bits value from byte
public GetBits ( byte b, int index, int length ) : byte
b byte The byte.
index int The bit index to read
length int The bit length to read
Résultat byte

GetBits() public méthode

Read bits value from byte
public GetBits ( int b, int index, int length ) : uint
b int The int value used to get bit.
index int The bit index to read
length int The bit length to read
Résultat uint

GetBits() public méthode

Read bits value from byte
public GetBits ( long b, int index, int length ) : ulong
b long The long value used to get bit.
index int The bit index to read
length int The bit length to read
Résultat ulong

GetBits() public méthode

Read bits value from byte
public GetBits ( short b, int index, int length ) : ushort
b short The short value used to get bit.
index int The bit index to read
length int The bit length to read
Résultat ushort

GetExtendedGUIDBytesLen() public méthode

Get the length of the ExtenedGUID
public GetExtendedGUIDBytesLen ( int byteOffset ) : int
byteOffset int the offset from the current position of the stream
Résultat int

GetSerialNumberBytesLen() public méthode

Get the length of the SerialNumber
public GetSerialNumberBytesLen ( int byteOffset ) : int
byteOffset int the offset from the current position of the stream
Résultat int

ObjectToTreeNode() public static méthode

Add the object to TreeNode and calculate the byte number it consumed
public static ObjectToTreeNode ( object obj, int &startIndex, int &offset ) : TreeNode
obj object The object need to display in TreeView
startIndex int The start position of the object in HexView
offset int The byte number consumed by the object
Résultat System.Windows.Forms.TreeNode

ObjectToTreeNode() public static méthode

Convert object to TreeNode
public static ObjectToTreeNode ( object obj, string ropNameforBinaryStrucutre ) : TreeNode
obj object The object need to convet
ropNameforBinaryStrucutre string The object need to convet
Résultat System.Windows.Forms.TreeNode

Parse() public méthode

Parse stream to specific message
public Parse ( Stream s ) : void
s Stream Stream to parse
Résultat void

PreReadDataElementPackageType() public méthode

Get DataElementPackage Type
public PreReadDataElementPackageType ( ) : long
Résultat long

Read3Bytes() protected méthode

Read an three bytes value as uint from stream
protected Read3Bytes ( ) : int
Résultat int

Read5Bytes() protected méthode

Read an five bytes value as ulong from stream
protected Read5Bytes ( ) : long
Résultat long

Read6Bytes() protected méthode

Read an six bytes value as ulong from stream
protected Read6Bytes ( ) : long
Résultat long

Read7Bytes() protected méthode

Read an seven bytes value as ulong from stream
protected Read7Bytes ( ) : long
Résultat long

ReadBoolean() protected méthode

Read an Boolean value from stream
protected ReadBoolean ( ) : System.Boolean
Résultat System.Boolean

ReadByte() protected méthode

Read a byte value from stream
protected ReadByte ( ) : byte
Résultat byte

ReadBytes() protected méthode

Read bytes from stream
protected ReadBytes ( int length ) : byte[]
length int The byte length to read
Résultat byte[]

ReadChar() protected méthode

Read character from stream
protected ReadChar ( Encoding encoding ) : char
encoding System.Text.Encoding The text encoding
Résultat char

ReadCompactUnsigned64bitIntegerValue() public méthode

Read CompactUnsigned64bitInteger from stream
public ReadCompactUnsigned64bitIntegerValue ( int byteOffset ) : long
byteOffset int the offset from the current position of the stream
Résultat long

ReadGuid() protected méthode

Read a GUID value from stream
protected ReadGuid ( ) : System.Guid
Résultat System.Guid

ReadINT16() protected méthode

Read an Int16 value from stream
protected ReadINT16 ( ) : Int16
Résultat System.Int16

ReadINT32() protected méthode

Read an Int32 value from stream
protected ReadINT32 ( ) : Int32
Résultat System.Int32

ReadINT64() public méthode

Read an long value from stream
public ReadINT64 ( ) : long
Résultat long

ReadString() protected méthode

Read string value from stream according to string terminator and Encoding method
protected ReadString ( Encoding encoding, string terminator = "\0", int stringlength, bool reducedUnicode = false ) : string
encoding System.Text.Encoding The character Encoding
terminator string The string terminator
stringlength int
reducedUnicode bool True means reduced Unicode character string. The terminating null character is one zero byte.
Résultat string

ReadUint() protected méthode

Read an uint value from stream
protected ReadUint ( ) : uint
Résultat uint

ReadUlong() protected méthode

Read an uLong value from stream
protected ReadUlong ( ) : ulong
Résultat ulong

ReadUshort() protected méthode

Read an ushort value from stream
protected ReadUshort ( ) : ushort
Résultat ushort

RemoveAnySpecifiedTreeNode() public static méthode

Remove subNode which node text contains "specified"
public static RemoveAnySpecifiedTreeNode ( TreeNode treenode ) : TreeNode
treenode System.Windows.Forms.TreeNode The tree node used to remove sub node
Résultat System.Windows.Forms.TreeNode

RemoveDefaultValueTreeNode() public static méthode

Remove subNode which contains defaut value(for optinal element)
public static RemoveDefaultValueTreeNode ( TreeNode &node, string specifiedText ) : void
node System.Windows.Forms.TreeNode The tree node used to remove sub node
specifiedText string the specified text
Résultat void

SimpleTypeObjectToNode() public static méthode

Convert simple type object to TreeNode
public static SimpleTypeObjectToNode ( object obj, object parentobj, FieldInfo Info, int &startIndex, int &offset ) : TreeNode
obj object The object which need to convert
parentobj object The parent object of the object which need to convert
Info System.Reflection.FieldInfo The field Info of the object in parent object
startIndex int The start index of this object in message stream
offset int The offset of this object
Résultat System.Windows.Forms.TreeNode

SimpleTypeObjectToNode() public static méthode

Convert simple type object to TreeNode
public static SimpleTypeObjectToNode ( object obj, string name ) : TreeNode
obj object The object which need to convert
name string The name of the child node
Résultat System.Windows.Forms.TreeNode

ToString() public méthode

Override the ToString method to return empty.
public ToString ( ) : string
Résultat string