Castle.MonoRail.Framework.Controller.InternalSend C# (CSharp) Method

InternalSend() protected method

Performs the specified action, which means:
1. Define the default view name
2. Run the before filters
3. Select the method related to the action name and invoke it
4. On error, execute the rescues if available
5. Run the after filters
6. Invoke the view engine
protected InternalSend ( string action, IDictionary actionArgs ) : void
action string Action name
actionArgs IDictionary Action arguments
return void
		protected virtual void InternalSend(string action, IDictionary actionArgs)
		{
			// If a redirect was sent there's no point in
			// wasting processor cycles
			
			if (Response.WasRedirected) return;
			
			if (logger.IsDebugEnabled)
			{
				logger.DebugFormat("InternalSend for action '{0}'", action);
			}

			bool checkWhetherClientHasDisconnected = ShouldCheckWhetherClientHasDisconnected;

			// Nothing to do if the peer disconnected
			if (checkWhetherClientHasDisconnected && !IsClientConnected) return;

			IControllerLifecycleExecutor executor =
				(IControllerLifecycleExecutor) context.Items[ControllerLifecycleExecutor.ExecutorEntry];

			if (!executor.SelectAction(action, Name, actionArgs))
			{
				executor.PerformErrorHandling();

				executor.Dispose();
				
				return;
			}
			
			executor.ProcessSelectedAction(actionArgs);
		}