Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / xsp / System / Web / Hosting / ApplicationHost.cs / 1 / 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
- StylusPlugin.cs
- TextViewSelectionProcessor.cs
- FileRecordSequenceHelper.cs
- NameValueFileSectionHandler.cs
- exports.cs
- DataKey.cs
- ScrollViewer.cs
- SmiTypedGetterSetter.cs
- XamlValidatingReader.cs
- FileChangesMonitor.cs
- DataServicePagingProviderWrapper.cs
- XmlComplianceUtil.cs
- XamlPointCollectionSerializer.cs
- ToolStripLabel.cs
- JavaScriptString.cs
- PeerName.cs
- XmlNamespaceManager.cs
- InertiaRotationBehavior.cs
- DataServiceQueryContinuation.cs
- Formatter.cs
- ReachFixedPageSerializer.cs
- WindowsScrollBar.cs
- ExpressionHelper.cs
- Pen.cs
- EventItfInfo.cs
- IDQuery.cs
- CryptoConfig.cs
- NodeFunctions.cs
- SharedUtils.cs
- HttpModuleActionCollection.cs
- WebConfigurationManager.cs
- MetadataArtifactLoaderFile.cs
- CrossContextChannel.cs
- OdbcFactory.cs
- DependencyProperty.cs
- SqlConnectionStringBuilder.cs
- CodeSnippetTypeMember.cs
- BoolExpressionVisitors.cs
- HttpFormatExtensions.cs
- DbgCompiler.cs
- HitTestParameters3D.cs
- ParameterSubsegment.cs
- xml.cs
- Rect3DConverter.cs
- ColumnCollection.cs
- GB18030Encoding.cs
- TextFormatterImp.cs
- FontStyleConverter.cs
- httpapplicationstate.cs
- PrintingPermission.cs
- EventDescriptorCollection.cs
- WindowsFormsSectionHandler.cs
- MappingMetadataHelper.cs
- GcHandle.cs
- CodeGenerator.cs
- DataGridViewTextBoxColumn.cs
- EntityContainer.cs
- RuleSetDialog.Designer.cs
- SliderAutomationPeer.cs
- ParagraphResult.cs
- ErrorWebPart.cs
- XmlSchemaAttribute.cs
- NamespaceList.cs
- ModifyActivitiesPropertyDescriptor.cs
- JsonFormatWriterGenerator.cs
- SQLInt64Storage.cs
- HtmlWindow.cs
- SqlProvider.cs
- DomNameTable.cs
- ObjectListGeneralPage.cs
- BrushValueSerializer.cs
- ETagAttribute.cs
- SharedConnectionWorkflowTransactionService.cs
- DocumentViewer.cs
- HashCryptoHandle.cs
- GlyphingCache.cs
- IdnMapping.cs
- XmlSchemaDatatype.cs
- InputLanguageCollection.cs
- HyperLink.cs
- SurrogateSelector.cs
- TypeExtension.cs
- PageAsyncTask.cs
- MD5.cs
- OdbcHandle.cs
- XamlGridLengthSerializer.cs
- JsonByteArrayDataContract.cs
- ResourcePart.cs
- PeerInputChannelListener.cs
- ListItemCollection.cs
- TimeIntervalCollection.cs
- Cursor.cs
- ObjectStateEntryBaseUpdatableDataRecord.cs
- ContextStaticAttribute.cs
- ResourceExpressionBuilder.cs
- Base64Encoding.cs
- Point3DIndependentAnimationStorage.cs
- PrintingPermissionAttribute.cs
- PerspectiveCamera.cs
- TextEditorTables.cs