1
/* ****************************************************************************
3 * Copyright (c) Microsoft Corporation. All rights reserved.
5 * This software is subject to the Microsoft Public License (Ms-PL).
6 * A copy of the license can be found in the license.htm file included
7 * in this distribution.
9 * You must not remove this notice, or any other, from this software.
11 * ***************************************************************************/
13 namespace System
.Web
.Mvc
{
15 using System
.Collections
.Generic
;
16 using System
.Diagnostics
.CodeAnalysis
;
18 public class ActionExecutingContext
: ControllerContext
{
20 // parameterless constructor used for mocking
21 public ActionExecutingContext() {
24 [SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors",
25 Justification
= "The virtual property setters are only to support mocking frameworks, in which case this constructor shouldn't be called anyway.")]
26 public ActionExecutingContext(ControllerContext controllerContext
, ActionDescriptor actionDescriptor
, IDictionary
<string, object> actionParameters
)
27 : base(controllerContext
) {
28 if (actionDescriptor
== null) {
29 throw new ArgumentNullException("actionDescriptor");
31 if (actionParameters
== null) {
32 throw new ArgumentNullException("actionParameters");
35 ActionDescriptor
= actionDescriptor
;
36 ActionParameters
= actionParameters
;
39 public virtual ActionDescriptor ActionDescriptor
{
44 [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly",
45 Justification
= "The property setter is only here to support mocking this type and should not be called at runtime.")]
46 public virtual IDictionary
<string, object> ActionParameters
{
51 public ActionResult Result
{