public Command23(CommandBuilder command) { if (command == null) { throw new ArgumentNullException("command"); } m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_SearchID = m_Command.ReadBytes(48); m_SearchResults = new RList <SearchResult>(); ushort searchResultsCount = m_Command.ReadUInt16(); for (int n = 0; n < searchResultsCount; n++) { byte[] fileHash = m_Command.ReadBytes(64); uint fileSize = m_Command.ReadUInt32(); string fileName = m_Command.ReadString(); RIndexedHashtable <string, string> metaData = new RIndexedHashtable <string, string>(); ushort metaDataCount = m_Command.ReadUInt16(); for (int m = 0; m < metaDataCount; m++) { metaData.Add(m_Command.ReadString(), m_Command.ReadString()); } m_SearchResults.Add(new SearchResult(fileHash, fileSize, fileName, metaData, m_Command.ReadString(), m_Command.ReadByte())); } }
public Command54(CommandBuilder command) { if (command == null) { throw new ArgumentNullException("command"); } m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_SourceSearchID = m_Command.ReadBytes(48); m_FileSize = m_Command.ReadUInt32(); m_FileName = m_Command.ReadString(); m_MetaData = new RIndexedHashtable <string, string>(); ushort metaDataCount = m_Command.ReadUInt16(); for (int n = 0; n < metaDataCount; n++) { m_MetaData.Add(m_Command.ReadString(), m_Command.ReadString()); } m_Comment = m_Command.ReadString(); m_Rating = m_Command.ReadByte(); m_SectorsMap = m_Command.ReadBytes(m_Command.ReadUInt16()); }
public Command71(CommandBuilder command) { if (command == null) throw new ArgumentNullException("command"); m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_FeedbackID = m_Command.ReadBytes(48); m_QueueLength = m_Command.ReadUInt32(); }
public Command78(CommandBuilder command) { if (command == null) throw new ArgumentNullException("command"); m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_DownloadID = m_Command.ReadBytes(48); m_Sector = m_Command.ReadUInt32(); }
public Command79(CommandBuilder command) { if (command == null) throw new ArgumentNullException("command"); m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_DownloadID = m_Command.ReadBytes(48); m_Sector = m_Command.ReadUInt32(); m_SectorData = m_Command.ReadBytes(m_Command.ReadUInt16()); m_SectorHashCodeResult = m_Command.ReadBytes(64); }
public Command78(CommandBuilder command) { if (command == null) { throw new ArgumentNullException("command"); } m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_DownloadID = m_Command.ReadBytes(48); m_Sector = m_Command.ReadUInt32(); }
public Command79(CommandBuilder command) { if (command == null) { throw new ArgumentNullException("command"); } m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_DownloadID = m_Command.ReadBytes(48); m_Sector = m_Command.ReadUInt32(); m_SectorData = m_Command.ReadBytes(m_Command.ReadUInt16()); m_SectorHashCodeResult = m_Command.ReadBytes(64); }
public Command53(CommandBuilder command) { if (command == null) throw new ArgumentNullException("command"); m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_SourceSearchID = m_Command.ReadBytes(48); m_FileSize = m_Command.ReadUInt32(); m_FileName = m_Command.ReadString(); m_MetaData = new RIndexedHashtable<string, string>(); ushort metaDataCount = m_Command.ReadUInt16(); for (int n = 0; n < metaDataCount; n++) m_MetaData.Add(m_Command.ReadString(), m_Command.ReadString()); m_Comment = m_Command.ReadString(); m_Rating = m_Command.ReadByte(); }
public Command23(CommandBuilder command) { if (command == null) throw new ArgumentNullException("command"); m_Command = command; m_CommandID = m_Command.ReadBytes(48); m_SenderPeerID = m_Command.ReadBytes(48); m_ReceiverPeerID = m_Command.ReadBytes(48); m_SearchID = m_Command.ReadBytes(48); m_SearchResults = new RList<SearchResult>(); ushort searchResultsCount = m_Command.ReadUInt16(); for (int n = 0; n < searchResultsCount; n++) { byte[] fileHash = m_Command.ReadBytes(64); uint fileSize = m_Command.ReadUInt32(); string fileName = m_Command.ReadString(); RIndexedHashtable<string, string> metaData = new RIndexedHashtable<string, string>(); ushort metaDataCount = m_Command.ReadUInt16(); for (int m = 0; m < metaDataCount; m++) metaData.Add(m_Command.ReadString(), m_Command.ReadString()); m_SearchResults.Add(new SearchResult(fileHash, fileSize, fileName, metaData, m_Command.ReadString(), m_Command.ReadByte())); } }