Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / xsp / System / Web / Hosting / ApplicationHost.cs / 2 / ApplicationHost.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Hosting { using System; using System.IO; using System.Collections; using System.Globalization; using System.Runtime.InteropServices; using System.Runtime.Remoting; using System.Web; using System.Web.Configuration; using System.Web.Util; using System.Security.Permissions; ////// [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class ApplicationHost { private ApplicationHost() { } /* * Creates new app domain for hosting of ASP.NET apps with a * user defined 'host' object in it. The host is needed to make * cross-domain calls to process requests in the host's app domain */ ///[To be supplied.] ////// [SecurityPermission(SecurityAction.Demand, Unrestricted=true)] public static Object CreateApplicationHost(Type hostType, String virtualDir, String physicalDir) { #if !FEATURE_PAL // FEATURE_PAL does not require PlatformID.Win32NT if (Environment.OSVersion.Platform != PlatformID.Win32NT) throw new PlatformNotSupportedException(SR.GetString(SR.RequiresNT)); #else // !FEATURE_PAL // FEATURE_PAL #endif // !FEATURE_PAL if (!StringUtil.StringEndsWith(physicalDir, Path.DirectorySeparatorChar)) physicalDir = physicalDir + Path.DirectorySeparatorChar; ApplicationManager appManager = ApplicationManager.GetApplicationManager(); String appId = (String.Concat(virtualDir, physicalDir).GetHashCode()).ToString("x"); ObjectHandle h = appManager.CreateInstanceInNewWorkerAppDomain( hostType, appId, VirtualPath.CreateNonRelative(virtualDir), physicalDir); return h.Unwrap(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //[To be supplied.] ///// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Hosting { using System; using System.IO; using System.Collections; using System.Globalization; using System.Runtime.InteropServices; using System.Runtime.Remoting; using System.Web; using System.Web.Configuration; using System.Web.Util; using System.Security.Permissions; ////// [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class ApplicationHost { private ApplicationHost() { } /* * Creates new app domain for hosting of ASP.NET apps with a * user defined 'host' object in it. The host is needed to make * cross-domain calls to process requests in the host's app domain */ ///[To be supplied.] ////// [SecurityPermission(SecurityAction.Demand, Unrestricted=true)] public static Object CreateApplicationHost(Type hostType, String virtualDir, String physicalDir) { #if !FEATURE_PAL // FEATURE_PAL does not require PlatformID.Win32NT if (Environment.OSVersion.Platform != PlatformID.Win32NT) throw new PlatformNotSupportedException(SR.GetString(SR.RequiresNT)); #else // !FEATURE_PAL // FEATURE_PAL #endif // !FEATURE_PAL if (!StringUtil.StringEndsWith(physicalDir, Path.DirectorySeparatorChar)) physicalDir = physicalDir + Path.DirectorySeparatorChar; ApplicationManager appManager = ApplicationManager.GetApplicationManager(); String appId = (String.Concat(virtualDir, physicalDir).GetHashCode()).ToString("x"); ObjectHandle h = appManager.CreateInstanceInNewWorkerAppDomain( hostType, appId, VirtualPath.CreateNonRelative(virtualDir), physicalDir); return h.Unwrap(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.[To be supplied.] ///
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- StringHandle.cs
- FieldCollectionEditor.cs
- InitializeCorrelation.cs
- BamlResourceSerializer.cs
- DataTableReaderListener.cs
- BroadcastEventHelper.cs
- XmlDictionary.cs
- BasicAsyncResult.cs
- ButtonChrome.cs
- DnsCache.cs
- GenericIdentity.cs
- HScrollBar.cs
- AccessDataSourceView.cs
- SystemInfo.cs
- ChtmlFormAdapter.cs
- HttpBufferlessInputStream.cs
- UInt16.cs
- ProgressBarRenderer.cs
- DataStreams.cs
- CodeDomConfigurationHandler.cs
- StorageModelBuildProvider.cs
- SelfIssuedAuthRSAPKCS1SignatureDeformatter.cs
- GeneratedContractType.cs
- RequestCacheManager.cs
- RegistrationProxy.cs
- ToolStripPanelCell.cs
- TextMetrics.cs
- PeerTransportListenAddressConverter.cs
- ProgressBarHighlightConverter.cs
- Repeater.cs
- _ProxyChain.cs
- DocumentOrderQuery.cs
- DateTimeParse.cs
- AdornerHitTestResult.cs
- LongCountAggregationOperator.cs
- ConfigsHelper.cs
- DataBoundControl.cs
- DbParameterCollectionHelper.cs
- WinFormsUtils.cs
- UnsettableComboBox.cs
- PreviousTrackingServiceAttribute.cs
- HealthMonitoringSectionHelper.cs
- DataGridViewAutoSizeModeEventArgs.cs
- Function.cs
- UndoManager.cs
- DataSysAttribute.cs
- ServiceContractListItemList.cs
- IsolatedStorageFileStream.cs
- WebPartConnectVerb.cs
- StateMachineSubscriptionManager.cs
- DebugHandleTracker.cs
- ReadOnlyDictionary.cs
- ContextMenuStrip.cs
- ErrorTableItemStyle.cs
- FloaterBaseParaClient.cs
- ExtensionWindow.cs
- HttpCookieCollection.cs
- PropertyValueUIItem.cs
- MetadataArtifactLoaderXmlReaderWrapper.cs
- IteratorDescriptor.cs
- OracleBoolean.cs
- MostlySingletonList.cs
- IntellisenseTextBox.cs
- PolyQuadraticBezierSegmentFigureLogic.cs
- Item.cs
- DefaultValueAttribute.cs
- FixedSOMTableRow.cs
- XmlQueryOutput.cs
- ComboBox.cs
- CmsInterop.cs
- Keyboard.cs
- TextElementCollectionHelper.cs
- PathFigure.cs
- KnownIds.cs
- SafeHandles.cs
- MenuItemAutomationPeer.cs
- Int16Converter.cs
- BulletedListEventArgs.cs
- SqlClientWrapperSmiStream.cs
- ExpandoClass.cs
- KeyValueSerializer.cs
- Maps.cs
- HealthMonitoringSection.cs
- DataGridViewRowPrePaintEventArgs.cs
- ApplicationInfo.cs
- Size3DConverter.cs
- Stackframe.cs
- XmlBinaryWriter.cs
- XmlCDATASection.cs
- VirtualPathProvider.cs
- _RequestLifetimeSetter.cs
- DataGridClipboardCellContent.cs
- DataGrid.cs
- ConnectionPoint.cs
- XmlDataSourceNodeDescriptor.cs
- SecureConversationDriver.cs
- ErrorWrapper.cs
- ProvidersHelper.cs
- PageContent.cs
- AutomationAttributeInfo.cs