/// <summary> /// Processes a received confirmed request /// </summary> /// <param name="source">The address of the device that sent the request</param> /// <param name="message">The confirmed request header</param> /// <param name="segment">The buffer segment containing the request content</param> public void ProcessConfirmedRequest(Address source, ConfirmedRequestMessage message, BufferSegment segment) { }
/// <summary> /// Sends the very first segment in the request /// </summary> private void _sendInitialRequestSegment() { if (_request.Length > _device.MaxAppgramLength) throw new Exception("Segmentation not supported... yet"); _sequenceNumber = 0; _windowStart = 0; _windowSize = MaxWindowSize; ConfirmedRequestMessage message = new ConfirmedRequestMessage(); message.Segmented = false; message.MoreFollows = false; message.SegmentedResponseAccepted = true; message.MaxSegmentsAccepted = int.MaxValue; message.MaxAppgramLengthAccepted = (int)_device.MaxAppgramLength; // TODO: retrieve from local device? message.InvokeId = _invokeId; message.SequenceNumber = (byte)_windowStart; message.ProposedWindowSize = (byte)_windowSize; message.ServiceChoice = _serviceChoice; _host.SendRaw(_device.Address, true, message, new BufferSegment(_request, 0, _request.Length)); _transitionTo(ClientState.AwaitConfirmation); }