
System.Object

System.Attribute

System.AttributeUsageAttribute

System.CLSCompliantAttribute

System.ComponentModel.AmbientValueAttribute

System.ComponentModel.BindableAttribute

System.ComponentModel.BrowsableAttribute

System.ComponentModel.CategoryAttribute

System.ComponentModel.DefaultEventAttribute

System.ComponentModel.DefaultPropertyAttribute

System.ComponentModel.DefaultValueAttribute

System.ComponentModel.DescriptionAttribute

System.ComponentModel.Design.Serialization.DesignerSerializerAttribute

System.ComponentModel.Design.Serialization.RootDesignerSerializerAttribute

System.ComponentModel.DesignerAttribute

System.ComponentModel.DesignerCategoryAttribute

System.ComponentModel.DesignerSerializationVisibilityAttribute

System.ComponentModel.DesignOnlyAttribute

System.ComponentModel.DesignTimeVisibleAttribute

System.ComponentModel.EditorAttribute

System.ComponentModel.EditorBrowsableAttribute

System.ComponentModel.ImmutableObjectAttribute

System.ComponentModel.InheritanceAttribute

System.ComponentModel.InstallerTypeAttribute

System.ComponentModel.LicenseProviderAttribute

System.ComponentModel.ListBindableAttribute

System.ComponentModel.LocalizableAttribute

System.ComponentModel.MergablePropertyAttribute

System.ComponentModel.NotifyParentPropertyAttribute

System.ComponentModel.ParenthesizePropertyNameAttribute

System.ComponentModel.PropertyTabAttribute

System.ComponentModel.ProvidePropertyAttribute

System.ComponentModel.ReadOnlyAttribute

System.ComponentModel.RecommendedAsConfigurableAttribute

System.ComponentModel.RefreshPropertiesAttribute

System.ComponentModel.RunInstallerAttribute

System.ComponentModel.ToolboxItemAttribute

System.ComponentModel.ToolboxItemFilterAttribute

System.ComponentModel.TypeConverterAttribute

System.ContextStaticAttribute

System.Diagnostics.ConditionalAttribute

System.Diagnostics.DebuggableAttribute

System.Diagnostics.DebuggerHiddenAttribute

System.Diagnostics.DebuggerStepThroughAttribute

System.Drawing.ToolboxBitmapAttribute

System.EnterpriseServices.ApplicationAccessControlAttribute

System.EnterpriseServices.ApplicationActivationAttribute

System.EnterpriseServices.ApplicationIDAttribute

System.EnterpriseServices.ApplicationNameAttribute

System.EnterpriseServices.ApplicationQueuingAttribute

System.EnterpriseServices.AutoCompleteAttribute

System.EnterpriseServices.CompensatingResourceManager.ApplicationCrmEnabledAttribute

System.EnterpriseServices.ComponentAccessControlAttribute

System.EnterpriseServices.COMTIIntrinsicsAttribute

System.EnterpriseServices.ConstructionEnabledAttribute

System.EnterpriseServices.DescriptionAttribute

System.EnterpriseServices.EventClassAttribute

System.EnterpriseServices.EventTrackingEnabledAttribute

System.EnterpriseServices.ExceptionClassAttribute

System.EnterpriseServices.IISIntrinsicsAttribute

System.EnterpriseServices.InterfaceQueuingAttribute

System.EnterpriseServices.JustInTimeActivationAttribute

System.EnterpriseServices.LoadBalancingSupportedAttribute

System.EnterpriseServices.MustRunInClientContextAttribute

System.EnterpriseServices.ObjectPoolingAttribute

System.EnterpriseServices.PrivateComponentAttribute

System.EnterpriseServices.SecureMethodAttribute

System.EnterpriseServices.SecurityRoleAttribute

System.EnterpriseServices.SynchronizationAttribute

System.EnterpriseServices.TransactionAttribute

System.FlagsAttribute

System.LoaderOptimizationAttribute

System.Management.Instrumentation.IgnoreMemberAttribute

System.Management.Instrumentation.InstrumentationClassAttribute

System.Management.Instrumentation.InstrumentedAttribute

System.Management.Instrumentation.ManagedNameAttribute

System.MTAThreadAttribute

System.NonSerializedAttribute

System.ObsoleteAttribute

System.ParamArrayAttribute

System.Reflection.AssemblyAlgorithmIdAttribute

System.Reflection.AssemblyCompanyAttribute

System.Reflection.AssemblyConfigurationAttribute

System.Reflection.AssemblyCopyrightAttribute

System.Reflection.AssemblyCultureAttribute

System.Reflection.AssemblyDefaultAliasAttribute

System.Reflection.AssemblyDelaySignAttribute

System.Reflection.AssemblyDescriptionAttribute

System.Reflection.AssemblyFileVersionAttribute

System.Reflection.AssemblyFlagsAttribute

System.Reflection.AssemblyInformationalVersionAttribute

System.Reflection.AssemblyKeyFileAttribute

System.Reflection.AssemblyKeyNameAttribute

System.Reflection.AssemblyProductAttribute

System.Reflection.AssemblyTitleAttribute

System.Reflection.AssemblyTrademarkAttribute

System.Reflection.AssemblyVersionAttribute

System.Reflection.DefaultMemberAttribute

System.Resources.NeutralResourcesLanguageAttribute

System.Resources.SatelliteContractVersionAttribute

System.Runtime.CompilerServices.AccessedThroughPropertyAttribute

System.Runtime.CompilerServices.CompilationRelaxationsAttribute

System.Runtime.CompilerServices.CompilerGlobalScopeAttribute

System.Runtime.CompilerServices.CustomConstantAttribute

System.Runtime.CompilerServices.DecimalConstantAttribute

System.Runtime.CompilerServices.DiscardableAttribute

System.Runtime.CompilerServices.IndexerNameAttribute

System.Runtime.CompilerServices.MethodImplAttribute

System.Runtime.CompilerServices.RequiredAttributeAttribute

System.Runtime.InteropServices.AutomationProxyAttribute

System.Runtime.InteropServices.BestFitMappingAttribute

System.Runtime.InteropServices.ClassInterfaceAttribute

System.Runtime.InteropServices.CoClassAttribute

System.Runtime.InteropServices.ComAliasNameAttribute

System.Runtime.InteropServices.ComCompatibleVersionAttribute

System.Runtime.InteropServices.ComConversionLossAttribute

System.Runtime.InteropServices.ComEventInterfaceAttribute

System.Runtime.InteropServices.ComImportAttribute

System.Runtime.InteropServices.ComRegisterFunctionAttribute

System.Runtime.InteropServices.ComSourceInterfacesAttribute

System.Runtime.InteropServices.ComUnregisterFunctionAttribute

System.Runtime.InteropServices.ComVisibleAttribute

System.Runtime.InteropServices.DispIdAttribute

System.Runtime.InteropServices.DllImportAttribute

System.Runtime.InteropServices.FieldOffsetAttribute

System.Runtime.InteropServices.GuidAttribute

System.Runtime.InteropServices.IDispatchImplAttribute

System.Runtime.InteropServices.ImportedFromTypeLibAttribute

System.Runtime.InteropServices.InAttribute

System.Runtime.InteropServices.InterfaceTypeAttribute

System.Runtime.InteropServices.LCIDConversionAttribute

System.Runtime.InteropServices.MarshalAsAttribute

System.Runtime.InteropServices.OptionalAttribute

System.Runtime.InteropServices.OutAttribute

System.Runtime.InteropServices.PreserveSigAttribute

System.Runtime.InteropServices.PrimaryInteropAssemblyAttribute

System.Runtime.InteropServices.ProgIdAttribute

System.Runtime.InteropServices.StructLayoutAttribute

System.Runtime.InteropServices.TypeLibFuncAttribute

System.Runtime.InteropServices.TypeLibTypeAttribute

System.Runtime.InteropServices.TypeLibVarAttribute

System.Runtime.InteropServices.TypeLibVersionAttribute

System.Runtime.Remoting.Messaging.OneWayAttribute

System.Runtime.Remoting.Metadata.SoapAttribute

System.Runtime.Remoting.Proxies.ProxyAttribute

System.Security.AllowPartiallyTrustedCallersAttribute

System.Security.Permissions.SecurityAttribute

System.Security.SuppressUnmanagedCodeSecurityAttribute

System.Security.UnverifiableCodeAttribute

System.SerializableAttribute

System.STAThreadAttribute

System.ThreadStaticAttribute

System.Web.Services.Configuration.XmlFormatExtensionAttribute

System.Web.Services.Configuration.XmlFormatExtensionPointAttribute

System.Web.Services.Configuration.XmlFormatExtensionPrefixAttribute

System.Web.Services.Protocols.HttpMethodAttribute

System.Web.Services.Protocols.MatchAttribute

System.Web.Services.Protocols.SoapDocumentMethodAttribute

System.Web.Services.Protocols.SoapDocumentServiceAttribute

System.Web.Services.Protocols.SoapExtensionAttribute

System.Web.Services.Protocols.SoapHeaderAttribute

System.Web.Services.Protocols.SoapRpcMethodAttribute

System.Web.Services.Protocols.SoapRpcServiceAttribute

System.Web.Services.WebMethodAttribute

System.Web.Services.WebServiceAttribute

System.Web.Services.WebServiceBindingAttribute

System.Web.UI.ConstructorNeedsTagAttribute

System.Web.UI.ControlBuilderAttribute

System.Web.UI.DataBindingHandlerAttribute

System.Web.UI.ParseChildrenAttribute

System.Web.UI.PartialCachingAttribute

System.Web.UI.PersistChildrenAttribute

System.Web.UI.PersistenceModeAttribute

System.Web.UI.TagPrefixAttribute

System.Web.UI.TemplateContainerAttribute

System.Web.UI.ToolboxDataAttribute

System.Web.UI.ValidationPropertyAttribute

System.Xml.Serialization.SoapAttributeAttribute

System.Xml.Serialization.SoapElementAttribute

System.Xml.Serialization.SoapEnumAttribute

System.Xml.Serialization.SoapIgnoreAttribute

System.Xml.Serialization.SoapIncludeAttribute

System.Xml.Serialization.SoapTypeAttribute

System.Xml.Serialization.XmlAnyAttributeAttribute

System.Xml.Serialization.XmlAnyElementAttribute

System.Xml.Serialization.XmlArrayAttribute

System.Xml.Serialization.XmlArrayItemAttribute

System.Xml.Serialization.XmlAttributeAttribute

System.Xml.Serialization.XmlChoiceIdentifierAttribute

System.Xml.Serialization.XmlElementAttribute

System.Xml.Serialization.XmlEnumAttribute

System.Xml.Serialization.XmlIgnoreAttribute

System.Xml.Serialization.XmlIncludeAttribute

System.Xml.Serialization.XmlNamespaceDeclarationsAttribute

System.Xml.Serialization.XmlRootAttribute

System.Xml.Serialization.XmlTextAttribute

System.Xml.Serialization.XmlTypeAttribute
最近做一个项目,需要将一些界面输入的有一定结构规律的信息保存起来,然后下次需要时候可以调入到对应的界面位置上使用。(其实这个是很多应用都会碰到的)。结构和UI的对应关系可能会经常变动的,而且结构中需要填写的内容不是所有都必须的,直接用关系型数据库来保存似乎不是太好的方案。首先想到就是用XML文件来保存这些信息了,而界面之间的信息显示是有关联的,可以说需要一个缓冲来记录这些信息,想到的就是定义一个类来记录和操作这些信息。这自然遇到一个问题,如何保持类和XML数据的同步呢?
生成的XML文件需要给其它业务来做处理,格式上有一定的规范,对于类来说,信息都保存在字段或者属性那里的,并没有区别,但XML中可能有些信息是Attribute,有些又是Element的。如何灵活地处理这些关系呢?用与XML相关的属性来定义这些字段和类就可以了。
AttributeUsage这个类定义了LayoutAttribute的一些基本信息,例如这里定义了LayoutAttribute适用于字段,类,并且允许重复定义的。
在应用中,可以利用反射机制,将这些定义的信息获取,从而判断应该在界面上如何处理了。