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
- IISUnsafeMethods.cs
- CommandHelpers.cs
- documentsequencetextpointer.cs
- SRGSCompiler.cs
- Attribute.cs
- AttributeEmitter.cs
- OleDbFactory.cs
- DataMisalignedException.cs
- SingleAnimationBase.cs
- BindingExpressionUncommonField.cs
- TimelineCollection.cs
- ComponentFactoryHelpers.cs
- TextRangeEditTables.cs
- PageBuildProvider.cs
- VerificationException.cs
- Lasso.cs
- objectresult_tresulttype.cs
- ResolveNameEventArgs.cs
- AssemblyAssociatedContentFileAttribute.cs
- RemotingServices.cs
- ObjectDataSourceChooseTypePanel.cs
- BinarySerializer.cs
- RegistryPermission.cs
- BinaryObjectReader.cs
- RegionInfo.cs
- DLinqTableProvider.cs
- Point3DCollection.cs
- IdentityValidationException.cs
- JpegBitmapEncoder.cs
- HostExecutionContextManager.cs
- FacetDescriptionElement.cs
- JoinGraph.cs
- CompilerParameters.cs
- ByteStream.cs
- PolyLineSegment.cs
- ExtensionFile.cs
- FixedSOMPageElement.cs
- AxisAngleRotation3D.cs
- BaseParser.cs
- ChangeTracker.cs
- GroupByQueryOperator.cs
- xml.cs
- DropShadowBitmapEffect.cs
- HideDisabledControlAdapter.cs
- ScriptResourceAttribute.cs
- ContextProperty.cs
- WebUtil.cs
- Animatable.cs
- FixedDocumentSequencePaginator.cs
- NamespaceTable.cs
- SignalGate.cs
- ProfileParameter.cs
- SafeTokenHandle.cs
- ArrangedElement.cs
- RouteParser.cs
- ToolStripDropDownItem.cs
- QueryOperationResponseOfT.cs
- EditorAttribute.cs
- CipherData.cs
- Membership.cs
- ToolStripContentPanel.cs
- LocatorPart.cs
- AddingNewEventArgs.cs
- TemplateManager.cs
- ArgumentDesigner.xaml.cs
- CodeTypeDelegate.cs
- SchemaNotation.cs
- DataReaderContainer.cs
- Expression.DebuggerProxy.cs
- WebBrowserBase.cs
- HtmlLink.cs
- SubMenuStyle.cs
- WorkingDirectoryEditor.cs
- TypeUnloadedException.cs
- CodeIdentifier.cs
- ConfigurationException.cs
- XsltSettings.cs
- BooleanFunctions.cs
- DrawingAttributeSerializer.cs
- PasswordRecovery.cs
- SchemaElementDecl.cs
- DateTimeAutomationPeer.cs
- PerfService.cs
- ApplicationInfo.cs
- MenuAutomationPeer.cs
- Perspective.cs
- QualifiedCellIdBoolean.cs
- DrawingVisualDrawingContext.cs
- Pair.cs
- SafeFileMappingHandle.cs
- InfoCardSymmetricCrypto.cs
- WebMethodAttribute.cs
- VideoDrawing.cs
- TableRowGroupCollection.cs
- AnnotationComponentManager.cs
- WhitespaceSignificantCollectionAttribute.cs
- SudsWriter.cs
- Pens.cs
- odbcmetadatacollectionnames.cs
- CodeMemberField.cs