Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / CompMod / System / ComponentModel / AttributeProviderAttribute.cs / 1 / AttributeProviderAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.ComponentModel { using System; using System.Security.Permissions; ////// /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes")] [AttributeUsage(AttributeTargets.Property)] public class AttributeProviderAttribute : Attribute { private string _typeName; private string _propertyName; ////// /// Creates a new AttributeProviderAttribute object. /// public AttributeProviderAttribute(string typeName) { if (typeName == null) { throw new ArgumentNullException("typeName"); } _typeName = typeName; } ////// /// Creates a new AttributeProviderAttribute object. /// public AttributeProviderAttribute(string typeName, string propertyName) { if (typeName == null) { throw new ArgumentNullException("typeName"); } if (propertyName == null) { throw new ArgumentNullException("propertyName"); } _typeName = typeName; _propertyName = propertyName; } ////// /// Creates a new AttributeProviderAttribute object. /// public AttributeProviderAttribute(Type type) { if (type == null) { throw new ArgumentNullException("type"); } _typeName = type.AssemblyQualifiedName; } ////// /// The TypeName property returns the assembly qualified type name /// passed into the constructor. /// public string TypeName { get { return _typeName; } } ////// /// The TypeName property returns the property name that will be used to query attributes from. /// public string PropertyName { get { return _propertyName; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.ComponentModel { using System; using System.Security.Permissions; ////// /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance", "CA1813:AvoidUnsealedAttributes")] [AttributeUsage(AttributeTargets.Property)] public class AttributeProviderAttribute : Attribute { private string _typeName; private string _propertyName; ////// /// Creates a new AttributeProviderAttribute object. /// public AttributeProviderAttribute(string typeName) { if (typeName == null) { throw new ArgumentNullException("typeName"); } _typeName = typeName; } ////// /// Creates a new AttributeProviderAttribute object. /// public AttributeProviderAttribute(string typeName, string propertyName) { if (typeName == null) { throw new ArgumentNullException("typeName"); } if (propertyName == null) { throw new ArgumentNullException("propertyName"); } _typeName = typeName; _propertyName = propertyName; } ////// /// Creates a new AttributeProviderAttribute object. /// public AttributeProviderAttribute(Type type) { if (type == null) { throw new ArgumentNullException("type"); } _typeName = type.AssemblyQualifiedName; } ////// /// The TypeName property returns the assembly qualified type name /// passed into the constructor. /// public string TypeName { get { return _typeName; } } ////// /// The TypeName property returns the property name that will be used to query attributes from. /// public string PropertyName { get { return _propertyName; } } } } // 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
- DocumentOrderQuery.cs
- ObjectNotFoundException.cs
- ClientFormsIdentity.cs
- WindowPatternIdentifiers.cs
- ProfileSettings.cs
- FixedFlowMap.cs
- ProfileModule.cs
- CommandTreeTypeHelper.cs
- DateTimeParse.cs
- RadioButton.cs
- CodeChecksumPragma.cs
- StringValueConverter.cs
- UpdateProgress.cs
- DataSpaceManager.cs
- Tracer.cs
- HGlobalSafeHandle.cs
- NoneExcludedImageIndexConverter.cs
- SinglePageViewer.cs
- Visual3D.cs
- ExtensibleSyndicationObject.cs
- ProxyWebPartManager.cs
- FilterException.cs
- DataServiceProcessingPipeline.cs
- ProfileService.cs
- CardSpaceShim.cs
- ObjectCloneHelper.cs
- Metadata.cs
- TypeToken.cs
- SqlConnectionManager.cs
- PartitionResolver.cs
- StyleCollection.cs
- Process.cs
- Geometry.cs
- SqlTopReducer.cs
- ConfigurationManagerHelperFactory.cs
- Int32Storage.cs
- X500Name.cs
- LinkedList.cs
- MobileUserControlDesigner.cs
- Command.cs
- BaseResourcesBuildProvider.cs
- XmlName.cs
- ImageListStreamer.cs
- WorkflowTraceTransfer.cs
- DefaultHttpHandler.cs
- TableCell.cs
- Registry.cs
- DataReceivedEventArgs.cs
- FixedHyperLink.cs
- FloaterParaClient.cs
- activationcontext.cs
- SqlMetaData.cs
- DesignerTransactionCloseEvent.cs
- Touch.cs
- Run.cs
- ParentQuery.cs
- PolyQuadraticBezierSegment.cs
- EntityProviderFactory.cs
- ZipIOCentralDirectoryFileHeader.cs
- OneOfTypeConst.cs
- NoPersistScope.cs
- BitStack.cs
- MatrixConverter.cs
- InvalidPrinterException.cs
- XmlWriterTraceListener.cs
- Substitution.cs
- DynamicValidator.cs
- ConvertTextFrag.cs
- SqlGenericUtil.cs
- CollectionChangedEventManager.cs
- ProgressBarHighlightConverter.cs
- RegexWorker.cs
- ScriptingAuthenticationServiceSection.cs
- FlowDocumentReaderAutomationPeer.cs
- SymbolType.cs
- CodeTypeReferenceExpression.cs
- DataSourceBooleanViewSchemaConverter.cs
- ExceptionHandler.cs
- EntryPointNotFoundException.cs
- ThreadStateException.cs
- AnonymousIdentificationSection.cs
- DecoderExceptionFallback.cs
- ReliableRequestSessionChannel.cs
- MULTI_QI.cs
- AssemblyAttributes.cs
- XmlWrappingReader.cs
- IERequestCache.cs
- DataGridTextBoxColumn.cs
- X509Extension.cs
- UserUseLicenseDictionaryLoader.cs
- Timeline.cs
- AdornerDecorator.cs
- PrintDialog.cs
- XmlBoundElement.cs
- SslStream.cs
- TextEncodedRawTextWriter.cs
- PageRouteHandler.cs
- Listener.cs
- SerialPinChanges.cs
- TextServicesPropertyRanges.cs