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
- DeclarativeCatalogPart.cs
- OleDbParameterCollection.cs
- DataTableCollection.cs
- WebPartManager.cs
- ResourceSetExpression.cs
- ParserStreamGeometryContext.cs
- WSSecurityXXX2005.cs
- _CommandStream.cs
- SubclassTypeValidatorAttribute.cs
- XamlTypeMapper.cs
- Typeface.cs
- WmiPutTraceRecord.cs
- TextTreeNode.cs
- EmptyEnumerator.cs
- WindowInteropHelper.cs
- DataServiceBehavior.cs
- PropertyConverter.cs
- Version.cs
- CreateUserWizardStep.cs
- ParameterCollection.cs
- SHA512.cs
- HexParser.cs
- TypeReference.cs
- SQLBytesStorage.cs
- FontUnit.cs
- BlockUIContainer.cs
- MethodBody.cs
- returneventsaver.cs
- SeekStoryboard.cs
- AppDomainManager.cs
- DropDownHolder.cs
- SafeEventLogReadHandle.cs
- RewritingProcessor.cs
- ADConnectionHelper.cs
- GenericsNotImplementedException.cs
- RawKeyboardInputReport.cs
- SQLDouble.cs
- ExceptionNotification.cs
- PnrpPermission.cs
- BmpBitmapDecoder.cs
- EncryptionUtility.cs
- UnsafeNativeMethods.cs
- DivideByZeroException.cs
- AdapterUtil.cs
- HttpListenerRequest.cs
- DynamicPropertyReader.cs
- DependencySource.cs
- BrowserCapabilitiesCodeGenerator.cs
- SqlMethodAttribute.cs
- PermissionSetTriple.cs
- ObjectStateEntryDbUpdatableDataRecord.cs
- XmlUtilWriter.cs
- ProcessHostServerConfig.cs
- SqlSelectStatement.cs
- SqlCrossApplyToCrossJoin.cs
- MeasureData.cs
- TextEditorParagraphs.cs
- CommonXSendMessage.cs
- TraceLevelStore.cs
- EmptyQuery.cs
- OLEDB_Util.cs
- PrintDialogException.cs
- WorkflowItemsPresenter.cs
- NullRuntimeConfig.cs
- LinqDataSourceDisposeEventArgs.cs
- VSDExceptions.cs
- CalloutQueueItem.cs
- TextTabProperties.cs
- RegexCaptureCollection.cs
- DbFunctionCommandTree.cs
- MessageEncodingBindingElement.cs
- NeutralResourcesLanguageAttribute.cs
- ContextCorrelationInitializer.cs
- WebPart.cs
- ClientScriptManager.cs
- Package.cs
- KeyInstance.cs
- TransportSecurityBindingElement.cs
- Content.cs
- StylusPointProperties.cs
- HttpDigestClientCredential.cs
- DataObjectMethodAttribute.cs
- DataTableReader.cs
- LinkTarget.cs
- PackageDigitalSignatureManager.cs
- Pair.cs
- DataViewSetting.cs
- WebPartCloseVerb.cs
- SafeBitVector32.cs
- SelectionItemProviderWrapper.cs
- XmlSchemaChoice.cs
- SqlDelegatedTransaction.cs
- ScrollItemProviderWrapper.cs
- XamlUtilities.cs
- UserPreferenceChangingEventArgs.cs
- KnownTypesProvider.cs
- Int32RectConverter.cs
- QueryStatement.cs
- documentsequencetextpointer.cs
- DataTransferEventArgs.cs