System.Windows.Forms.FileByteProvider.WriteCollection.Contains(long)

Here are the examples of the csharp api class System.Windows.Forms.FileByteProvider.WriteCollection.Contains(long) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

2 Examples 7

1. Example

Project: MapleShark
Source File: FileByteProvider.cs
public byte ReadByte(long index)
		{
			if(_writes.Contains(index))
				return _writes[index];

			if(_fileStream.Position != index)
				_fileStream.Position = index;

			byte res = (byte)_fileStream.ReadByte();
			return res;
		}

2. Example

Project: MapleShark
Source File: FileByteProvider.cs
public void WriteByte(long index, byte value)
		{
			if(_writes.Contains(index))
				_writes[index] = value;
			else
				_writes.Add(index, value);

			OnChanged(EventArgs.Empty);
		}