/// <summary> /// Converts a raw frame to PlayCounter frame. /// </summary> /// <param name="rawFrame">the raw frame.</param> /// <param name="codePage">Default code page for Ansi encoding. Pass 0 to use default system encoding code page.</param> /// s public override void Import(RawFrame rawFrame, int codePage) { /* ID = "PCNT" Counter $xx xx xx xx (xx ...) */ ImportRawFrameHeader(rawFrame); using (var reader = new FrameDataReader(rawFrame.Payload)) { Counter = reader.ReadUInt64(); } }
/// <summary> /// Import the raw content to a high level frame. /// </summary> /// <param name="rawFrame">the raw frame.</param> /// <param name="codePage">Default code page for Ansi encoding. Pass 0 to use default system encoding code page.</param> public override void Import(RawFrame rawFrame, int codePage) { /* * ID = "POPM" * Email to user <text string> $00 * Rating $xx * Counter $xx xx xx xx (xx ...) */ ImportRawFrameHeader(rawFrame); using (var reader = new FrameDataReader(rawFrame.Payload)) { Email = reader.ReadVariableString(Encoding.ASCII); Rating = reader.ReadByte(); PlayCounter = reader.ReadUInt64(); } }