Move PageExecutionListener interfaces to a separate assembly.

This commit is contained in:
Pranav K 2015-02-11 10:03:32 -08:00
parent f89c716dba
commit 5ed0638402
7 changed files with 56 additions and 13 deletions

View File

@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
VisualStudioVersion = 14.0.22526.0
VisualStudioVersion = 14.0.22604.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "samples", "samples", "{DAAE4C74-D06F-4874-A166-33305D2643CE}"
EndProject
@ -54,6 +54,8 @@ Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Microsoft.AspNet.Mvc.Xml",
EndProject
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Microsoft.AspNet.Mvc.Xml.Test", "test\Microsoft.AspNet.Mvc.Xml.Test\Microsoft.AspNet.Mvc.Xml.Test.kproj", "{22019146-BDFA-442E-8C8E-345FB9644578}"
EndProject
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Microsoft.AspNet.PageExecutionInstrumentation", "src\Microsoft.AspNet.PageExecutionInstrumentation\Microsoft.AspNet.PageExecutionInstrumentation.kproj", "{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -276,6 +278,18 @@ Global
{22019146-BDFA-442E-8C8E-345FB9644578}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{22019146-BDFA-442E-8C8E-345FB9644578}.Release|x86.ActiveCfg = Release|Any CPU
{22019146-BDFA-442E-8C8E-345FB9644578}.Release|x86.Build.0 = Release|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Debug|x86.ActiveCfg = Debug|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Debug|x86.Build.0 = Debug|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Release|Any CPU.Build.0 = Release|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Release|x86.ActiveCfg = Release|Any CPU
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@ -301,5 +315,6 @@ Global
{860119ED-3DB1-424D-8D0A-30132A8A7D96} = {3BA657BF-28B1-42DA-B5B0-1C4601FCF7B1}
{9C632DF0-DC06-410B-95AE-B5423702E84F} = {32285FA4-6B46-4D6B-A840-2B13E4C8B58E}
{22019146-BDFA-442E-8C8E-345FB9644578} = {3BA657BF-28B1-42DA-B5B0-1C4601FCF7B1}
{4DA2D7C1-A7B6-4C01-B57D-89E6EA4609DE} = {32285FA4-6B46-4D6B-A840-2B13E4C8B58E}
EndGlobalSection
EndGlobal

View File

@ -8,6 +8,7 @@
"Microsoft.AspNet.Mvc.Common": { "version": "6.0.0-*", "type": "build" },
"Microsoft.AspNet.Mvc.Core": "6.0.0-*",
"Microsoft.AspNet.Mvc.Razor.Host": "6.0.0-*",
"Microsoft.AspNet.PageExecutionInstrumentation" : "1.0.0-*",
"Microsoft.CodeAnalysis.CSharp": "1.0.0-rc1-*",
"Microsoft.Framework.Runtime.Roslyn.Common": "1.0.0-*"
},

View File

@ -3,14 +3,12 @@
using System.IO;
using System.Threading.Tasks;
using Microsoft.Framework.Runtime;
namespace Microsoft.AspNet.Mvc.Razor
{
/// <summary>
/// Specifies the contracts for a <see cref="TextWriter"/> that buffers its content.
/// </summary>
[AssemblyNeutral]
public interface IBufferedTextWriter
{
/// <summary>
@ -21,13 +19,13 @@ namespace Microsoft.AspNet.Mvc.Razor
/// <summary>
/// Copies the buffered content to the <paramref name="writer"/>.
/// </summary>
/// <param name="writer">The writer to copy the contents to./param>
/// <param name="writer">The writer to copy the contents to.</param>
void CopyTo(TextWriter writer);
/// <summary>
/// Asynchronously copies the buffered content to the <paramref name="writer"/>.
/// </summary>
/// <param name="writer">The writer to copy the contents to./param>
/// <param name="writer">The writer to copy the contents to.</param>
/// <returns>A <see cref="Task"/> representing the copy operation.</returns>
Task CopyToAsync(TextWriter writer);
}

View File

@ -1,14 +1,11 @@
// Copyright (c) Microsoft Open Technologies, Inc. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using Microsoft.Framework.Runtime;
namespace Microsoft.AspNet.PageExecutionInstrumentation
{
/// <summary>
/// Specifies the contracts for a execution context that instruments web page execution.
/// </summary>
[AssemblyNeutral]
public interface IPageExecutionContext
{
/// <summary>

View File

@ -2,14 +2,12 @@
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System.IO;
using Microsoft.Framework.Runtime;
namespace Microsoft.AspNet.PageExecutionInstrumentation
{
/// <summary>
/// Specifies the contracts for a HTTP feature that provides the context to instrument a web page.
/// </summary>
[AssemblyNeutral]
public interface IPageExecutionListenerFeature
{
/// <summary>
@ -18,16 +16,15 @@ namespace Microsoft.AspNet.PageExecutionInstrumentation
/// </summary>
/// <param name="writer">The output <see cref="TextWriter"/> for the web page.</param>
/// <returns>A <see cref="TextWriter"/> that wraps <paramref name="writer"/>.</returns>
/// <remarks>
TextWriter DecorateWriter(TextWriter writer);
/// <summary>
/// Creates a <see cref="IPageExecutionContext"/> for the specified <paramref name="sourceFilePath"/>.
/// </summary>
/// <param name="sourceFilePath">The path of the <see cref="Mvc.Razor.IRazorPage"/>.</param>
/// <param name="sourceFilePath">The path of the page.</param>
/// <param name="writer">The <see cref="TextWriter"/> obtained from <see cref="DecorateWriter(TextWriter)"/>.
/// </param>
/// <returns></returns>
/// <returns>The <see cref="IPageExecutionContext"/>.</returns>
IPageExecutionContext GetContext(string sourceFilePath, TextWriter writer);
}
}

View File

@ -0,0 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="__ToolsVersion__" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">14.0</VisualStudioVersion>
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
</PropertyGroup>
<Import Project="$(VSToolsPath)\AspNet\Microsoft.Web.AspNet.Props" Condition="'$(VSToolsPath)' != ''" />
<PropertyGroup Label="Globals">
<ProjectGuid>4da2d7c1-a7b6-4c01-b57d-89e6ea4609de</ProjectGuid>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x86'" Label="Configuration">
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x86'" Label="Configuration">
</PropertyGroup>
<PropertyGroup>
<SchemaVersion>2.0</SchemaVersion>
</PropertyGroup>
<Import Project="$(VSToolsPath)\AspNet\Microsoft.Web.AspNet.targets" Condition="'$(VSToolsPath)' != ''" />
</Project>

View File

@ -0,0 +1,15 @@
{
"description": "Abstractions for page instrumentation.",
"version": "1.0.0-*",
"compilationOptions": {
"warningsAsErrors": true
},
"frameworks": {
"aspnet50": { },
"aspnetcore50": {
"dependencies": {
"System.IO": "4.0.0-beta-*"
}
}
}
}