Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / CodeDOM / CodeAttributeDeclaration.cs / 1305376 / CodeAttributeDeclaration.cs
//------------------------------------------------------------------------------ //// // //----------------------------------------------------------------------------- namespace System.CodeDom { using System.Diagnostics; using System; using Microsoft.Win32; using System.Collections; using System.Runtime.InteropServices; using System.Runtime.Serialization; ///[....] // Copyright (c) Microsoft Corporation. All rights reserved. ///// [ ClassInterface(ClassInterfaceType.AutoDispatch), ComVisible(true), Serializable, ] public class CodeAttributeDeclaration { private string name; private CodeAttributeArgumentCollection arguments = new CodeAttributeArgumentCollection(); [OptionalField] private CodeTypeReference attributeType; ////// Represents a single custom attribute. /// ////// public CodeAttributeDeclaration() { } ////// Initializes a new instance of ///. /// /// public CodeAttributeDeclaration(string name) { Name = name; } ////// Initializes a new instance of ///using the specified name. /// /// public CodeAttributeDeclaration(string name, params CodeAttributeArgument[] arguments) { Name = name; Arguments.AddRange(arguments); } public CodeAttributeDeclaration(CodeTypeReference attributeType) : this ( attributeType, null) { } public CodeAttributeDeclaration(CodeTypeReference attributeType, params CodeAttributeArgument[] arguments) { this.attributeType = attributeType; if( attributeType != null) { this.name = attributeType.BaseType; } if(arguments != null) { Arguments.AddRange(arguments); } } ////// Initializes a new instance of ///using the specified /// arguments. /// /// public string Name { get { return (name == null) ? string.Empty : name; } set { name = value; attributeType = new CodeTypeReference(name); } } ////// The name of the attribute being declared. /// ////// public CodeAttributeArgumentCollection Arguments { get { return arguments; } } public CodeTypeReference AttributeType { get { return attributeType; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007./// The arguments for the attribute. /// ///
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- Asn1IntegerConverter.cs
- FileSystemEventArgs.cs
- RenderDataDrawingContext.cs
- MetadataCollection.cs
- StylusPlugin.cs
- SerializableAttribute.cs
- StreamWriter.cs
- WizardForm.cs
- SessionState.cs
- EtwTrace.cs
- ToolStrip.cs
- DefaultWorkflowLoaderService.cs
- Attributes.cs
- HtmlInputImage.cs
- MappingException.cs
- OutputWindow.cs
- PasswordBox.cs
- SimpleWebHandlerParser.cs
- odbcmetadatacolumnnames.cs
- InProcStateClientManager.cs
- XmlAnyAttributeAttribute.cs
- HtmlInputReset.cs
- UnsettableComboBox.cs
- SizeAnimation.cs
- ErrorWrapper.cs
- StorageAssociationSetMapping.cs
- SystemDiagnosticsSection.cs
- SelectedCellsCollection.cs
- ProviderSettings.cs
- CommandPlan.cs
- BasePropertyDescriptor.cs
- ListChangedEventArgs.cs
- ReversePositionQuery.cs
- Stacktrace.cs
- SelectiveScrollingGrid.cs
- Proxy.cs
- PeerContact.cs
- SuppressMergeCheckAttribute.cs
- ProfileBuildProvider.cs
- CommandEventArgs.cs
- _NtlmClient.cs
- DurableInstanceProvider.cs
- SqlDesignerDataSourceView.cs
- TerminatorSinks.cs
- ColorAnimationUsingKeyFrames.cs
- ReliabilityContractAttribute.cs
- DbDataReader.cs
- ExpressionStringBuilder.cs
- InternalBufferOverflowException.cs
- AnimatedTypeHelpers.cs
- TabItemAutomationPeer.cs
- Int16AnimationUsingKeyFrames.cs
- PropertyTabChangedEvent.cs
- AutoResetEvent.cs
- HttpDebugHandler.cs
- ActivityWithResult.cs
- CodeGotoStatement.cs
- X509CertificateStore.cs
- SubMenuStyle.cs
- OdbcFactory.cs
- _FixedSizeReader.cs
- FederatedMessageSecurityOverHttpElement.cs
- Update.cs
- Visual3D.cs
- EntityEntry.cs
- Span.cs
- TextElementCollectionHelper.cs
- RootProfilePropertySettingsCollection.cs
- EmptyStringExpandableObjectConverter.cs
- StreamingContext.cs
- ObjectDataSourceChooseTypePanel.cs
- Point.cs
- StatusStrip.cs
- RightsManagementPermission.cs
- StreamGeometry.cs
- FrameworkTextComposition.cs
- MailDefinitionBodyFileNameEditor.cs
- EventWaitHandleSecurity.cs
- Deflater.cs
- TabItemAutomationPeer.cs
- Int64AnimationUsingKeyFrames.cs
- WebPartUtil.cs
- DesignerAttribute.cs
- CompositeCollectionView.cs
- Oid.cs
- ACL.cs
- KeyBinding.cs
- XhtmlBasicSelectionListAdapter.cs
- FormattedText.cs
- FontFamilyIdentifier.cs
- HtmlTextArea.cs
- MetadataCache.cs
- SatelliteContractVersionAttribute.cs
- Border.cs
- StorageMappingItemLoader.cs
- ObjectItemNoOpAssemblyLoader.cs
- XmlAttributeOverrides.cs
- RtType.cs
- InputProcessorProfiles.cs
- GeneratedView.cs