Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / MS / Internal / Resources / ContentFileHelper.cs / 2 / ContentFileHelper.cs
// Copyright (c) Microsoft Corporation, 2001 // // File: ContentFileHelper.cs // //------------------------------------------------------------------------------ using System; using System.Reflection; using System.Windows.Resources; using System.Windows.Navigation; using System.Collections.Generic; namespace MS.Internal.Resources { //// ContentFileHelper class provides helper method to get assembly // associated content files. // internal static class ContentFileHelper { internal static bool IsContentFile(string partName) { if (_contentFiles == null) { _contentFiles = GetContentFiles(BaseUriHelper.ResourceAssembly); } if (_contentFiles != null && _contentFiles.Count > 0) { if (_contentFiles.ContainsKey(partName)) { return true; } } return false; } // // Get a list of Content Files for a given Assembly. // static internal DictionaryGetContentFiles(Assembly asm) { Dictionary contentFiles = null; Attribute[] assemblyAttributes; if (asm == null) { asm = BaseUriHelper.ResourceAssembly; if (asm == null) { // If we have no entry assembly return an empty list because // we can't have any content files. return new Dictionary (); } } assemblyAttributes = Attribute.GetCustomAttributes( asm, typeof(AssemblyAssociatedContentFileAttribute)); if (assemblyAttributes != null && assemblyAttributes.Length > 0) { contentFiles = new Dictionary (assemblyAttributes.Length, StringComparer.OrdinalIgnoreCase); for (int i=0; i _contentFiles; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
![Network programming in C#, Network Programming in VB.NET, Network Programming in .NET](/images/book.jpg)
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- NativeRightsManagementAPIsStructures.cs
- StylusTip.cs
- SByteStorage.cs
- Ipv6Element.cs
- PropertySet.cs
- XPathNavigator.cs
- XmlParserContext.cs
- XmlText.cs
- ExpressionEditorSheet.cs
- XmlAnyElementAttributes.cs
- TabControlEvent.cs
- Blend.cs
- LogSwitch.cs
- HtmlInputButton.cs
- Color.cs
- XmlTextReaderImpl.cs
- MD5CryptoServiceProvider.cs
- UserControlDocumentDesigner.cs
- OdbcParameter.cs
- UnionExpr.cs
- SafeNativeMethods.cs
- XmlSerializableWriter.cs
- ControlAdapter.cs
- RegexCaptureCollection.cs
- CapabilitiesRule.cs
- XmlSerializer.cs
- AnchoredBlock.cs
- ADRole.cs
- PageThemeParser.cs
- WmlPhoneCallAdapter.cs
- PersonalizationDictionary.cs
- FrameworkContextData.cs
- HandlerFactoryWrapper.cs
- SystemTcpConnection.cs
- fixedPageContentExtractor.cs
- DetailsViewUpdateEventArgs.cs
- NativeMethods.cs
- Compensate.cs
- NullRuntimeConfig.cs
- FormViewInsertEventArgs.cs
- XmlAttributeProperties.cs
- UnicodeEncoding.cs
- ArrangedElementCollection.cs
- RenderCapability.cs
- EnterpriseServicesHelper.cs
- XmlBuffer.cs
- TokenFactoryFactory.cs
- ContourSegment.cs
- PageThemeBuildProvider.cs
- DocumentSequenceHighlightLayer.cs
- Compiler.cs
- AuthenticatingEventArgs.cs
- Selector.cs
- SqlColumnizer.cs
- EditorZone.cs
- GlyphCollection.cs
- BinaryMessageEncodingElement.cs
- TextBoxBase.cs
- XmlUtf8RawTextWriter.cs
- RMEnrollmentPage3.cs
- DataControlFieldTypeEditor.cs
- FileEnumerator.cs
- Vector3DAnimation.cs
- NativeWindow.cs
- MemoryFailPoint.cs
- JavascriptCallbackBehaviorAttribute.cs
- PersonalizationStateInfo.cs
- BinaryFormatter.cs
- XmlSchemaIdentityConstraint.cs
- XmlSchemaSequence.cs
- RegistrationServices.cs
- DrawingServices.cs
- XmlElementAttribute.cs
- Rotation3D.cs
- MouseOverProperty.cs
- Confirm.cs
- CacheMemory.cs
- DropDownButton.cs
- Color.cs
- DataColumnMappingCollection.cs
- ListItemConverter.cs
- PropertyGridView.cs
- SortedDictionary.cs
- CompareInfo.cs
- SharedPerformanceCounter.cs
- SqlDataSourceStatusEventArgs.cs
- SymmetricCryptoHandle.cs
- LightweightEntityWrapper.cs
- XsltException.cs
- WaitHandleCannotBeOpenedException.cs
- SafeSecurityHandles.cs
- TabItemWrapperAutomationPeer.cs
- OrderedDictionary.cs
- HttpWebRequestElement.cs
- MenuItemStyle.cs
- GrammarBuilderWildcard.cs
- LinkedResourceCollection.cs
- RayHitTestParameters.cs
- TreeNodeCollectionEditorDialog.cs
- XmlAnyElementAttributes.cs