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
- CancellableEnumerable.cs
- JsonStringDataContract.cs
- UniqueCodeIdentifierScope.cs
- ListenerServiceInstallComponent.cs
- ToolStripMenuItem.cs
- PropertyMapper.cs
- Rect.cs
- CustomLineCap.cs
- Bold.cs
- NamedPermissionSet.cs
- DrawingVisualDrawingContext.cs
- BitmapCodecInfo.cs
- InvokePattern.cs
- RestHandler.cs
- LinkedResourceCollection.cs
- EarlyBoundInfo.cs
- JavaScriptSerializer.cs
- HelpInfo.cs
- XD.cs
- DesignerSerializationManager.cs
- Opcode.cs
- WebPartEditVerb.cs
- DirectoryObjectSecurity.cs
- TaskScheduler.cs
- Figure.cs
- AssemblyCollection.cs
- xmlNames.cs
- XmlC14NWriter.cs
- Selection.cs
- PathGeometry.cs
- RouteCollection.cs
- XmlQueryStaticData.cs
- Matrix.cs
- TripleDESCryptoServiceProvider.cs
- Binding.cs
- CredentialSelector.cs
- StyleCollectionEditor.cs
- HtmlMeta.cs
- SerializationException.cs
- JsonSerializer.cs
- __FastResourceComparer.cs
- ToolStripItemImageRenderEventArgs.cs
- ReferencedType.cs
- PolicyException.cs
- BitmapImage.cs
- CacheVirtualItemsEvent.cs
- TextServicesManager.cs
- BitmapInitialize.cs
- ServerProtocol.cs
- Activator.cs
- InstanceKeyView.cs
- SliderAutomationPeer.cs
- EventArgs.cs
- HybridDictionary.cs
- BehaviorService.cs
- MappedMetaModel.cs
- IdleTimeoutMonitor.cs
- DataViewListener.cs
- SmtpSpecifiedPickupDirectoryElement.cs
- FontStretches.cs
- PageBuildProvider.cs
- SerialReceived.cs
- ComboBox.cs
- unsafenativemethodstextservices.cs
- UIPropertyMetadata.cs
- TextEditorSelection.cs
- MimeMapping.cs
- ProtocolsConfigurationEntry.cs
- SynchronizedInputPattern.cs
- OleDbWrapper.cs
- QilInvokeEarlyBound.cs
- MemoryStream.cs
- WindowsRebar.cs
- Deflater.cs
- SingleAnimation.cs
- DateTimeOffsetConverter.cs
- DataException.cs
- SqlWebEventProvider.cs
- SafeProcessHandle.cs
- FullTrustAssemblyCollection.cs
- Transform.cs
- TextProviderWrapper.cs
- TemplateBamlRecordReader.cs
- DataGridSortCommandEventArgs.cs
- XPathNode.cs
- VisualCollection.cs
- CacheModeValueSerializer.cs
- PageWrapper.cs
- XmlILStorageConverter.cs
- BindingsSection.cs
- DropShadowEffect.cs
- SqlTypeSystemProvider.cs
- DateRangeEvent.cs
- JournalNavigationScope.cs
- SqlTriggerAttribute.cs
- DynamicPropertyHolder.cs
- TableCell.cs
- BaseParaClient.cs
- ISessionStateStore.cs
- Executor.cs