1. Added an Order property to IRouteTemplateProvider, ReflectedAttributeRouteModel,
AttributeRouteInfo, AttributeRouteLinkGenerationEntry and AttributeRouteMatchingEntry.
2. Changed the implementation of AttributeRoute to take the order into account when routing
incomming requests and generating links.
3. Ensured a stable ordering of route entries with the same order and precedence for route
matching and link generation based on the template text.
4. Added tests to validate that the precedence gets respected in route matching and link generation.
5. Added tests to validate that the order gets respected in route matching and link generation.
6. Added tests to validate that the order gets respected over the precedence for route matching
and link generation.
7. Added tests to validate that routes with the same order and precedence expose a stable ordering
for route matching and link generation.
1. Unsealed the Http*Attributes so that they can be extended and customized.
2. Added the same constructors as HttpGet to the rest of the Http*Attributes.
3. Added unit tests to validate the implementations for the IActionHttpMethodProvider.
4. Added functional tests to cover extra attribute routing scenarios like a test for an
action with an HttpDeleteAttribute on it and action with AcceptVerbsAttribute and an
action with a custom HttpMergeAttribute implemented.
1. Added a new AttributeRouteInfo class to store all the information for
actions that are attribute routed.
2. Added a new ReflectedAttributeRouteModel class to store all the information
related to attribute routes in the ReflectedApplicationModel.
3. Refactored ReflectedControllerModel and ReflectedActionModel to use ReflectedAttributeRouteModel
instead of just the attribute route template.
4. Refactored ReflectedActionDescriptorProvider to use AttributeRouteInfo and ReflectedAttributeRouteModel
instead of just the route template.
5. Added a CombineReflectedAttributeRouteModel method in ReflectedAttributeRouteModel that handles
combining two ReflectedAttributeRouteModel instances.
6. Removed the AttributeRouteTemplate class and moved the methods for combining attribute routes to the
ReflectedAttributeRouteModel class.
7. Added unit tests for ReflectedActionModel and ReflectedControllerModel that
cover the usage of AttributeRouteInfo.
8. Added unit tests for CombineReflectedAttributeRouteModel.
- #847 line 1: copy XML comments from interfaces to extension methods
- lots of wording changes to be more consistent
- core text split from PR #866, where @rynowak and I hashed out the words
- to extent possible, reuse words between method descriptions
- add a few missing `<param/>` and `<typeparam/>` elements and fill in empty ones
- display more HTML elements as tags
- use `<c>true|false|null</c>` more often
- add `<remarks/>` describing behaviour of input helpers e.g. `CheckBox()`
- add `<remarks/>` explaining "renders"
- add `<remarks/>` containing example expression names
nits:
- "The expression" -> "An expression"
- make examples for `ObjectToDictionary()` and `AnonymousObjectToHtmlAttributes()` more consistent
- move `<typeparam/>` elements (that existed) after all `<param/>` elements
- explain "checked" attributes better, removing some duplicated words from the `RadioButton[For]()` descriptions
- correct `routeValues` description in `GenerateForm()` comments
-Checks for ModelType before processing.
-Ignores quotes in ByteArrayModelBinder.
-Unit,functional Tests.
-ModelStateError is set when Covert.FromBase64String(value) throws.
- Support other kinds of references when compiling razor views
- Cache application references since they can't change throughout the lifetime
of the running application
* This allows for injection of the property in cshtml files wthout running
in to compilation errors
* Make IUrlHelper a default injected service
Fixes#816
- extend the "test" target in our build to use new k-xml-docs-test.shade command
Example output with one syntax error and one invalid reference:
```
info: Target xml-docs-test
warn: Invalid documentation syntax in src\Microsoft.AspNet.Mvc.Core\bin\debug\net45\Microsoft.AspNet.Mvc.Core.xml
warn: 3170: <!-- Badly formed XML comment ignored for member "T:Microsoft.AspNet.Mvc.Rendering.HtmlHelper" -->
warn: 3203: If the object is already an <see cref="!:IDictionaries<string, object>"/> instance, then it is
```
it into exception thrown
All values in Exception.Data need to be serializable which is not true for
the diagnostics. Removing this property since we can't pass it through.
* Update CompilationFailedException to include path of file being compiled
* Pass in path being compiled to Rolsyn.
* Adding doc comments for compilation pieces
Fixes#869
- correct XML comment typo introduced in `HtmlHelper` in 56d66c090e (bad merge)
- fix missed `null` requirement for `@Html.RadioButtonFor()` and remove buried `null` check
- add back `Environment.Newline` to `@Html.TextArea()` (was dropped though comment wasn't)
- don't call other extension methods
- #847 line 7
- remove extension methods that do nothing but pass through to the interface method
- weren't exactly ambiguous (interface method wins) but were useless
- #874 lines 3, 4, and 6
- correct `Value()` to treat a `null` expression name the same as `string.Empty`
- add missing `[NotNull]` attributes in `EditorExtensions` and for `GenerateIdFromName()`
- consistently pass `null` for default expression names to the helpers
- for example, from extension methods
- add test cases using `null` for expression name
nits:
- correct summary XML comment for `HtmlHelper` class
- use named parameters and prefer interface (not extension) methods in changed calls
- use `string.Empty` instead of `""` in a few tests
- fix problems at least with Roslyn compiler and VS IntelliSense or the Object Browser
- `<see langref="keyword"/>` generates nothing
- `<example>` at top level (outside `<summary>`) generates nothing
- curly braces don't become angle brackets outside `<see cref="reference"/>` references
- yeah, a point @yishaigalatzer asked about in a previous PR
- `<see href="reference"/>` is not valid
- correct some invalid use of angle brackets and remove useless empty elements
- correct unresolved XML comment references; generally, add namespace prefix
Symptoms for some of the above issues included
- generated XML comments such as `<!-- Badly formed XML comment ... -->`, usually indicating an unclosed element
- generated XML attributes such as `cref="!:..."`, indicating a broken reference
- in a couple of cases we had `<typeparamref cref="TOption"/>`; attribute should be `"name"`
Few wording changes beyond
- `"opening </form> tag"` -> `"<form> start tag"`
- `"closing </form> tag"` -> `"</form> end tag"`
Also correct two typos in `HtmlHelper`
Will create a unit test to ensure XML syntax doesn't degrade going forward. Separate PR.
- for now, check using `dir -r *.xml | sls '!'`
RazorTextWriter represents the result of rendering a page as a sequence of
strings rather than a concatenated string. This avoids building up large
strings in memory.
https://roslyn.codeplex.com/workitem/246 affects usage of code with the
latest build of Roslyn with Moq v4.2. The workaround involves ensuring a
closure is created. Updating affected tests to make ToString() calls on
local variables to create these closures.
- see line 2 of #874
- focus on `TextBox[For]()` and `ValidationSummary()`
related fixes included here:
- `TextArea[For]()` documentation incorrectly indicated their `htmlAttributes` parameters were dictionaries
- handle `htmlAttributes` parameters more consistently; create a dictionary only when necessary
- fixes#566 and part of #847
- allows compositions such as `@Html.Label("property", Html.Id("property"))`
and `@Html.Raw(Html.DisplayText("property"))` (this one is not recommended)
- adjust XML comments to match
- add missing XML comments to `HtmlHelperValueExtensions`
- nit: `TInnerModel` -> `TModelItem`
- increase XML comment consistency for changed methods
- generally make wording more consistent e.g. how we use words such as
"returns"
- use `<see langref="string|true|false|null"/>` more