Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / untmp / whidbey / QFE / ndp / fx / src / xsp / System / Web / Hosting / ProcessHostFactoryHelper.cs / 3 / ProcessHostFactoryHelper.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Web.Hosting {
using System;
using System.Collections;
using System.Configuration;
using System.Runtime.InteropServices;
using System.Security.Permissions;
using System.Web;
using System.Web.Configuration;
using System.Web.Util;
[ComImport, Guid("02fd465d-5c5d-4b7e-95b6-82faa031b74a"), InterfaceTypeAttribute(ComInterfaceType.InterfaceIsIUnknown)]
[AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)]
[AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)]
public interface IProcessHostFactoryHelper {
#if FEATURE_PAL // FEATURE_PAL does not enable COM
[return: MarshalAs(UnmanagedType.Error)]
#else // FEATURE_PAL
[return: MarshalAs(UnmanagedType.Interface)]
#endif // FEATURE_PAL
Object GetProcessHost(IProcessHostSupportFunctions functions);
}
[AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)]
public sealed class ProcessHostFactoryHelper : MarshalByRefObject, IProcessHostFactoryHelper {
[AspNetHostingPermission(SecurityAction.Demand, Level=AspNetHostingPermissionLevel.Minimal)]
public ProcessHostFactoryHelper() {
}
[SecurityPermissionAttribute(SecurityAction.LinkDemand, Flags=SecurityPermissionFlag.Infrastructure)]
public override Object InitializeLifetimeService() {
return null; // never expire lease
}
public Object GetProcessHost(IProcessHostSupportFunctions functions) {
try {
return ProcessHost.GetProcessHost(functions);
}
catch(Exception e) {
Misc.ReportUnhandledException(e, new string[] {SR.GetString(SR.Cant_Create_Process_Host)});
throw;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ExceptionUtil.cs
- ModelItemCollection.cs
- PartialCachingControl.cs
- ToolBarTray.cs
- ValidationHelper.cs
- SoapFault.cs
- unsafeIndexingFilterStream.cs
- VisualBrush.cs
- CipherData.cs
- DataGridViewCellCancelEventArgs.cs
- SHA512Managed.cs
- SkinBuilder.cs
- GeometryConverter.cs
- FtpWebResponse.cs
- Cursor.cs
- TrackBar.cs
- HtmlControl.cs
- FirstMatchCodeGroup.cs
- XmlWriter.cs
- PersonalizationProvider.cs
- WebResourceAttribute.cs
- _LazyAsyncResult.cs
- RTLAwareMessageBox.cs
- WebBrowsableAttribute.cs
- EnumValidator.cs
- SchemaMapping.cs
- XmlComment.cs
- CodeSnippetTypeMember.cs
- OutputScope.cs
- Material.cs
- ToolStripStatusLabel.cs
- AsyncStreamReader.cs
- HttpProfileBase.cs
- TextEditorParagraphs.cs
- SpellerError.cs
- WindowsAuthenticationEventArgs.cs
- DeferredElementTreeState.cs
- XmlSchemaFacet.cs
- SessionIDManager.cs
- Material.cs
- BulletedListEventArgs.cs
- CompositeControl.cs
- UIElementHelper.cs
- WebSysDisplayNameAttribute.cs
- PolyLineSegment.cs
- SmtpReplyReaderFactory.cs
- TableStyle.cs
- ForeignConstraint.cs
- ProcessModuleCollection.cs
- BooleanKeyFrameCollection.cs
- ExpressionBindings.cs
- AudioBase.cs
- VirtualizedItemPattern.cs
- CurrentChangedEventManager.cs
- DataControlFieldCell.cs
- EntityClassGenerator.cs
- Timer.cs
- DataKeyCollection.cs
- Literal.cs
- ItemCheckEvent.cs
- DropDownList.cs
- HtmlElementEventArgs.cs
- ObjectDataSourceEventArgs.cs
- ExtensionWindow.cs
- IconEditor.cs
- OperatorExpressions.cs
- RawStylusSystemGestureInputReport.cs
- WebPartConnectionsConnectVerb.cs
- TypeSystemProvider.cs
- unsafenativemethodstextservices.cs
- ObjectQuery.cs
- XPathNavigatorReader.cs
- XmlSerializerFactory.cs
- TableAutomationPeer.cs
- EntityProviderServices.cs
- Animatable.cs
- Identity.cs
- PreviewKeyDownEventArgs.cs
- SQLMembershipProvider.cs
- AddingNewEventArgs.cs
- DataListItem.cs
- TreeViewCancelEvent.cs
- StorageMappingItemLoader.cs
- ISAPIWorkerRequest.cs
- XPathDocumentIterator.cs
- FocusTracker.cs
- TextContainerHelper.cs
- basenumberconverter.cs
- CommonRemoteMemoryBlock.cs
- Rules.cs
- LinkedResource.cs
- ColorAnimationBase.cs
- XmlLoader.cs
- TerminateSequence.cs
- PtsHost.cs
- ExpressionBuilderContext.cs
- PersonalizationState.cs
- SendKeys.cs
- DataSpaceManager.cs
- ServiceOperationUIEditor.cs