private InsertOrIgnoreOperation ReadInsertOrIgnoreOperation(BinaryReader reader) { IData key = KeyPersist.Read(reader); IData record = RecordPersist.Read(reader); return(new InsertOrIgnoreOperation(key, record)); }
private ReplaceOperation ReadReplaceOperation(BinaryReader reader) { IData key = KeyPersist.Read(reader); IData record = RecordPersist.Read(reader); return(new ReplaceOperation(key, record)); }
private TryGetOperation ReadTryGetOperation(BinaryReader reader) { IData key = KeyPersist.Read(reader); IData record = reader.ReadBoolean() ? RecordPersist.Read(reader) : null; return(new TryGetOperation(key, record)); }
private LastRowCommand ReadLastRowCommand(BinaryReader reader) { bool hasValue = (reader.ReadBoolean()); IData key = hasValue ? KeyPersist.Read(reader) : null; IData rec = hasValue ? RecordPersist.Read(reader) : null; return(new LastRowCommand(hasValue ? (KeyValuePair <IData, IData>?) new KeyValuePair <IData, IData>(key, rec) : null)); }
private LastRowOperation ReadLastRowOperation(BinaryReader reader) { bool hasValues = (reader.ReadBoolean()); IData key = hasValues ? KeyPersist.Read(reader) : null; IData rec = hasValues ? RecordPersist.Read(reader) : null; return(new LastRowOperation(new KeyValuePair <IData, IData>(key, rec))); }
private FindBeforeCommand ReadFindBeforeCommand(BinaryReader reader) { IData Key = KeyPersist.Read(reader); bool hasValue = (reader.ReadBoolean()); IData key = hasValue ? KeyPersist.Read(reader) : null; IData rec = hasValue ? RecordPersist.Read(reader) : null; return(new FindBeforeCommand(Key, hasValue ? (KeyValuePair <IData, IData>?) new KeyValuePair <IData, IData>(key, rec) : null)); }
private FindBeforeOperation ReadFindBeforeOperation(BinaryReader reader) { IData from = KeyPersist.Read(reader); bool hasValues = (reader.ReadBoolean()); IData key = hasValues ? KeyPersist.Read(reader) : null; IData rec = hasValues ? RecordPersist.Read(reader) : null; return(new FindBeforeOperation(from, new KeyValuePair <IData, IData>(key, rec))); }
private List <KeyValuePair <IData, IData> > DeserializeList(BinaryReader reader) { int count = reader.ReadInt32(); List <KeyValuePair <IData, IData> > list = new List <KeyValuePair <IData, IData> >(count); for (int i = 0; i < count; i++) { IData key = KeyPersist.Read(reader); IData rec = RecordPersist.Read(reader); list.Add(new KeyValuePair <IData, IData>(key, rec)); } return(list); }
private TryGetCommand ReadTryGetCommand(BinaryReader reader) { return(new TryGetCommand(KeyPersist.Read(reader), reader.ReadBoolean() ? RecordPersist.Read(reader) : null)); }
private InsertOrIgnoreCommand ReadInsertOrIgnoreCommand(BinaryReader reader) { return(new InsertOrIgnoreCommand(KeyPersist.Read(reader), RecordPersist.Read(reader))); }
private ReplaceCommand ReadReplaceCommand(BinaryReader reader) { return(new ReplaceCommand(KeyPersist.Read(reader), RecordPersist.Read(reader))); }