Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / clr / src / BCL / System / Runtime / Serialization / SerializationAttributes.cs / 1305376 / SerializationAttributes.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Class: OptionallySerializableAttribute ** ** ** Purpose: Various Attributes for Serialization ** ** ============================================================*/ namespace System.Runtime.Serialization { using System; using System.Diagnostics.Contracts; using System.Reflection; [AttributeUsage(AttributeTargets.Field, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OptionalFieldAttribute : Attribute { int versionAdded = 1; public OptionalFieldAttribute() { } public int VersionAdded { get { return this.versionAdded; } set { if (value < 1) throw new ArgumentException(Environment.GetResourceString("Serialization_OptionalFieldVersionValue")); Contract.EndContractBlock(); this.versionAdded = value; } } } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnSerializingAttribute : Attribute { } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnSerializedAttribute : Attribute { } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnDeserializingAttribute : Attribute { } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnDeserializedAttribute : Attribute { } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Class: OptionallySerializableAttribute ** ** ** Purpose: Various Attributes for Serialization ** ** ============================================================*/ namespace System.Runtime.Serialization { using System; using System.Diagnostics.Contracts; using System.Reflection; [AttributeUsage(AttributeTargets.Field, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OptionalFieldAttribute : Attribute { int versionAdded = 1; public OptionalFieldAttribute() { } public int VersionAdded { get { return this.versionAdded; } set { if (value < 1) throw new ArgumentException(Environment.GetResourceString("Serialization_OptionalFieldVersionValue")); Contract.EndContractBlock(); this.versionAdded = value; } } } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnSerializingAttribute : Attribute { } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnSerializedAttribute : Attribute { } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnDeserializingAttribute : Attribute { } [AttributeUsage(AttributeTargets.Method, Inherited=false)] [System.Runtime.InteropServices.ComVisible(true)] public sealed class OnDeserializedAttribute : Attribute { } } // 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
- SynchronizationLockException.cs
- SudsWriter.cs
- BrowserCapabilitiesCompiler.cs
- CellTreeNode.cs
- AmbiguousMatchException.cs
- SqlCacheDependencyDatabaseCollection.cs
- QilReference.cs
- ButtonChrome.cs
- MetadataArtifactLoader.cs
- ConfigurationSchemaErrors.cs
- _FixedSizeReader.cs
- RecognitionResult.cs
- AsyncCodeActivityContext.cs
- UnsafeNetInfoNativeMethods.cs
- TextSimpleMarkerProperties.cs
- QueryAccessibilityHelpEvent.cs
- ThumbButtonInfo.cs
- ParenthesizePropertyNameAttribute.cs
- DeflateEmulationStream.cs
- CacheHelper.cs
- SafeHandles.cs
- figurelength.cs
- CodeVariableReferenceExpression.cs
- TextDecoration.cs
- WmiEventSink.cs
- UseAttributeSetsAction.cs
- UserNameServiceElement.cs
- SignatureDescription.cs
- Blend.cs
- FormViewPageEventArgs.cs
- Int32Collection.cs
- StringTraceRecord.cs
- PageWrapper.cs
- PartialCachingControl.cs
- WebPartsPersonalizationAuthorization.cs
- ProfileEventArgs.cs
- DetailsViewRow.cs
- SqlExpressionNullability.cs
- HtmlProps.cs
- FixedPageStructure.cs
- MachineKeySection.cs
- Brushes.cs
- CollectionViewGroupRoot.cs
- ExpressionBindingCollection.cs
- IOException.cs
- IntegerValidator.cs
- IdentityReference.cs
- KeysConverter.cs
- SimpleHandlerBuildProvider.cs
- ServiceElementCollection.cs
- PreviewPageInfo.cs
- Line.cs
- GeneralTransform3DTo2D.cs
- DataGridTextBox.cs
- QueueSurrogate.cs
- Vector3DKeyFrameCollection.cs
- SoapServerMessage.cs
- ValidatorCompatibilityHelper.cs
- Attributes.cs
- LiteralLink.cs
- SettingsPropertyNotFoundException.cs
- CompilationLock.cs
- WriteableOnDemandStream.cs
- CallSite.cs
- OLEDB_Enum.cs
- DocumentPageView.cs
- Delegate.cs
- HelloOperationAsyncResult.cs
- ExpressionBindings.cs
- ExpressionBuilderContext.cs
- SoapEnumAttribute.cs
- ToolStripControlHost.cs
- EntityViewContainer.cs
- CallbackHandler.cs
- WmpBitmapEncoder.cs
- ZipPackage.cs
- BaseResourcesBuildProvider.cs
- ContractMethodInfo.cs
- SelectionItemPattern.cs
- EmptyReadOnlyDictionaryInternal.cs
- PopupRoot.cs
- RegexCode.cs
- ConstNode.cs
- WindowInteropHelper.cs
- XmlUtf8RawTextWriter.cs
- JoinCqlBlock.cs
- TextDecorationLocationValidation.cs
- HuffmanTree.cs
- RegistryPermission.cs
- HotCommands.cs
- DateTime.cs
- MailHeaderInfo.cs
- DynamicDataResources.Designer.cs
- WSSecurityOneDotZeroSendSecurityHeader.cs
- UrlMapping.cs
- assertwrapper.cs
- DataAdapter.cs
- ReservationNotFoundException.cs
- SettingsBase.cs
- SimpleHandlerFactory.cs