Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / xsp / System / Web / Configuration / IISMapPath.cs / 1 / IISMapPath.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System.Configuration; using System.Collections; using System.Globalization; using System.Xml; using System.Text; using System.Web.Util; using System.Web.UI; using System.IO; using System.Web.Hosting; // // Abstracts the difference between Metabase and SitesSection IConfigMapPath. // static internal class IISMapPath { static internal IConfigMapPath GetInstance() { // IIS 7 bits on <= IIS 6.x: use the metabase if (ServerConfig.UseMetabase) { return (IConfigMapPath) MetabaseServerConfig.GetInstance(); } ProcessHost host = ProcessHost.DefaultHost; IProcessHostSupportFunctions functions = null; if (null != host) { functions = host.SupportFunctions; } if (functions == null) { functions = HostingEnvironment.SupportFunctions; } return new ProcessHostMapPath(functions); } // A site name might be an id if it is a number. static internal bool IsSiteId(string siteName) { if (string.IsNullOrEmpty(siteName)) return false; for (int i = 0; i < siteName.Length; i++) { if (!Char.IsDigit(siteName[i])) { return false; } } return true; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System.Configuration; using System.Collections; using System.Globalization; using System.Xml; using System.Text; using System.Web.Util; using System.Web.UI; using System.IO; using System.Web.Hosting; // // Abstracts the difference between Metabase and SitesSection IConfigMapPath. // static internal class IISMapPath { static internal IConfigMapPath GetInstance() { // IIS 7 bits on <= IIS 6.x: use the metabase if (ServerConfig.UseMetabase) { return (IConfigMapPath) MetabaseServerConfig.GetInstance(); } ProcessHost host = ProcessHost.DefaultHost; IProcessHostSupportFunctions functions = null; if (null != host) { functions = host.SupportFunctions; } if (functions == null) { functions = HostingEnvironment.SupportFunctions; } return new ProcessHostMapPath(functions); } // A site name might be an id if it is a number. static internal bool IsSiteId(string siteName) { if (string.IsNullOrEmpty(siteName)) return false; for (int i = 0; i < siteName.Length; i++) { if (!Char.IsDigit(siteName[i])) { return false; } } return true; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ServiceHostingEnvironment.cs
- Freezable.cs
- CustomAttribute.cs
- EditableTreeList.cs
- ObjectListComponentEditor.cs
- InputProcessorProfiles.cs
- CatalogPartCollection.cs
- WsatServiceCertificate.cs
- IncrementalHitTester.cs
- ModelUIElement3D.cs
- LinkTarget.cs
- TabPage.cs
- DecoratedNameAttribute.cs
- ValidatedMobileControlConverter.cs
- CharacterHit.cs
- DashStyles.cs
- AsyncDataRequest.cs
- EntityDataSourceChangingEventArgs.cs
- FontInfo.cs
- IdnElement.cs
- Tracking.cs
- SqlDeflator.cs
- _FtpControlStream.cs
- NativeMethods.cs
- CallTemplateAction.cs
- ArraySubsetEnumerator.cs
- X509ChainPolicy.cs
- TypeRefElement.cs
- CacheMemory.cs
- XmlBaseWriter.cs
- AnnotationResourceChangedEventArgs.cs
- ImageList.cs
- userdatakeys.cs
- _AutoWebProxyScriptHelper.cs
- FontNamesConverter.cs
- TypedRowGenerator.cs
- GregorianCalendar.cs
- DataControlFieldCollection.cs
- PointCollection.cs
- InteropBitmapSource.cs
- GridEntryCollection.cs
- JapaneseCalendar.cs
- DeferredTextReference.cs
- SqlDataSourceView.cs
- DocumentViewerConstants.cs
- DockPanel.cs
- entityreference_tresulttype.cs
- SchemaTypeEmitter.cs
- SHA256Managed.cs
- DataConnectionHelper.cs
- DirectoryInfo.cs
- SqlRewriteScalarSubqueries.cs
- Point.cs
- HtmlLinkAdapter.cs
- HttpHandlerActionCollection.cs
- RSAPKCS1KeyExchangeFormatter.cs
- StringSource.cs
- ContentValidator.cs
- HtmlInputReset.cs
- autovalidator.cs
- DrawingBrush.cs
- MouseGestureValueSerializer.cs
- Exceptions.cs
- UDPClient.cs
- QueryTaskGroupState.cs
- DictionaryContent.cs
- KeyValueInternalCollection.cs
- OpenFileDialog.cs
- InvalidPropValue.cs
- Monitor.cs
- MD5.cs
- CodeActivityMetadata.cs
- TextRangeEdit.cs
- FormClosedEvent.cs
- ApplicationHost.cs
- GridView.cs
- SpanIndex.cs
- WebPartEditorApplyVerb.cs
- SslStreamSecurityBindingElement.cs
- IListConverters.cs
- TreeNodeEventArgs.cs
- FullTrustAssembliesSection.cs
- ServiceSecurityContext.cs
- StylusPointProperty.cs
- ConfigPathUtility.cs
- DeploymentSection.cs
- Rotation3D.cs
- IdentityReference.cs
- EntityDataSourceStatementEditorForm.cs
- FirstMatchCodeGroup.cs
- XmlElementCollection.cs
- TextEditor.cs
- BamlTreeNode.cs
- ConsoleCancelEventArgs.cs
- PrivilegeNotHeldException.cs
- CatalogZone.cs
- EntityDataSourceChangingEventArgs.cs
- NetCodeGroup.cs
- HybridDictionary.cs
- MeasureData.cs