void ProcessDecodedChars() { char value; while (Parent.GetCurrentCharacterAndAdvance(out value)) { Buffer.Append(value); } var decodeMoreChars = Parent.DecodeMoreData(); decodeMoreChars.RegisterOnComplete(OnDecodeComplete); }
public void ProcessDecodedChars() { char value; while (Parent.GetCurrentCharacter(out value)) { if (Position >= (InitialPosition + Count)) { Result.Complete(Count); return; } Parent.ReadNextCharacter(); Buffer[Position] = value; Position += 1; } var decodeMoreChars = Parent.DecodeMoreData(); decodeMoreChars.RegisterOnComplete(OnDecodeComplete); }
public void ProcessDecodedChars() { if (Parent.ReadDecodedCharactersUntilSentinel(Buffer, '\n')) { if ((Buffer.Length > 0) && (Buffer[Buffer.Length - 1] == '\r')) { Buffer.Remove(Buffer.Length - 1, 1); } if (Parent.EndOfStream) { Parent._ExtraLine = true; } var resultString = Buffer.DisposeAndGetContents(); Result.Complete(resultString); } else { var decodeMoreChars = Parent.DecodeMoreData(); decodeMoreChars.RegisterOnComplete(OnDecodeComplete); } }