/// <summary> /// Gets or sets the <see cref="System.Byte"/> at the specified index. /// </summary> /// <value></value> /// <returns></returns> public byte this[uint index] { get { return(MemoryDispatch.Read8((uint)(_address + index))); } set { MemoryDispatch.Write8((uint)(_address + index), value); } }
/// <summary> /// Reads the specified index. /// </summary> /// <param name="index">The index.</param> /// <param name="count">The count.</param> /// <returns></returns> public uint Read32(uint index, byte count) { uint offset = _address + index; uint value = 0; if (count == 1) { return(MemoryDispatch.Read8(offset)); } while (count > 0) { value = (value >> 8) | MemoryDispatch.Read8(offset); count--; offset++; } return(value); }
/// <summary> /// Reads the specified index. /// </summary> /// <param name="index">The index.</param> /// <returns></returns> public byte Read8(uint index) { return(MemoryDispatch.Read8((uint)(_address + index))); }