Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / ndp / fx / src / DataEntity / System / Data / Objects / DataClasses / EdmScalarPropertyAttribute.cs / 2 / EdmScalarPropertyAttribute.cs
//---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- namespace System.Data.Objects.DataClasses { using System; ////// Attribute for scalar properties in an IEntity. /// Implied default AttributeUsage properties Inherited=True, AllowMultiple=False, /// The metadata system expects this and will only look at the first of each of these attributes, even if there are more. /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Edm")] [AttributeUsage(AttributeTargets.Property)] public sealed class EdmScalarPropertyAttribute : EdmPropertyAttribute { // Private variables corresponding to their properties. private bool _isNullable = true; private bool _entityKeyProperty; ////// Attribute for scalar properties. /// EdmScalarPropertyAttribute(EntityKeyProperty=[true|false], IsNullable=[true|false]) /// IsNullable and EntityKeyProperty cannot both be true. /// public EdmScalarPropertyAttribute() { } ////// The property is allowed to have a value of NULL. /// public bool IsNullable { get { return _isNullable; } set { _isNullable = value;} } ////// The property is a key. /// public bool EntityKeyProperty { get { return _entityKeyProperty; } set { _entityKeyProperty = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //---------------------------------------------------------------------- //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //--------------------------------------------------------------------- namespace System.Data.Objects.DataClasses { using System; ////// Attribute for scalar properties in an IEntity. /// Implied default AttributeUsage properties Inherited=True, AllowMultiple=False, /// The metadata system expects this and will only look at the first of each of these attributes, even if there are more. /// [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "Edm")] [AttributeUsage(AttributeTargets.Property)] public sealed class EdmScalarPropertyAttribute : EdmPropertyAttribute { // Private variables corresponding to their properties. private bool _isNullable = true; private bool _entityKeyProperty; ////// Attribute for scalar properties. /// EdmScalarPropertyAttribute(EntityKeyProperty=[true|false], IsNullable=[true|false]) /// IsNullable and EntityKeyProperty cannot both be true. /// public EdmScalarPropertyAttribute() { } ////// The property is allowed to have a value of NULL. /// public bool IsNullable { get { return _isNullable; } set { _isNullable = value;} } ////// The property is a key. /// public bool EntityKeyProperty { get { return _entityKeyProperty; } set { _entityKeyProperty = value; } } } } // 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
- SystemWebSectionGroup.cs
- DBAsyncResult.cs
- ResourceReferenceExpression.cs
- CustomSignedXml.cs
- Int32EqualityComparer.cs
- PropertyEmitterBase.cs
- ScrollableControl.cs
- HierarchicalDataBoundControlAdapter.cs
- FunctionUpdateCommand.cs
- _NetworkingPerfCounters.cs
- DependencyPropertyKind.cs
- FormatSelectingMessageInspector.cs
- WebPartRestoreVerb.cs
- LoadRetryHandler.cs
- TemplateEditingService.cs
- BitmapSourceSafeMILHandle.cs
- EditableTreeList.cs
- XmlSecureResolver.cs
- DiscoveryClientChannelBase.cs
- TextEffect.cs
- DecoderExceptionFallback.cs
- x509utils.cs
- TdsRecordBufferSetter.cs
- FileClassifier.cs
- AxHost.cs
- PanelStyle.cs
- DataExpression.cs
- KeyPullup.cs
- TypeConverterHelper.cs
- HttpCachePolicyElement.cs
- SmiEventStream.cs
- PanelDesigner.cs
- DbReferenceCollection.cs
- ActiveXHelper.cs
- TypefaceMap.cs
- KeyboardNavigation.cs
- ObjectDataSourceSelectingEventArgs.cs
- StyleSheet.cs
- HttpModulesSection.cs
- QuestionEventArgs.cs
- FileUpload.cs
- TableLayoutPanel.cs
- ComboBoxRenderer.cs
- TraceData.cs
- StringFormat.cs
- OutputCacheSettingsSection.cs
- ProgressBar.cs
- TableLayoutCellPaintEventArgs.cs
- xsdvalidator.cs
- ContentType.cs
- ListControl.cs
- FlowDocumentPaginator.cs
- TimelineGroup.cs
- CapabilitiesAssignment.cs
- RC2CryptoServiceProvider.cs
- DataGridViewTextBoxColumn.cs
- TreeViewDataItemAutomationPeer.cs
- ServiceModelConfigurationSection.cs
- AbsoluteQuery.cs
- NTAccount.cs
- PhoneCallDesigner.cs
- TextParentUndoUnit.cs
- Hash.cs
- PageCache.cs
- TraceRecord.cs
- ColorEditor.cs
- JapaneseCalendar.cs
- NameNode.cs
- XmlObjectSerializerWriteContextComplex.cs
- InstancePersistenceContext.cs
- DynamicEntity.cs
- WebPartTransformerCollection.cs
- SplineKeyFrames.cs
- ReflectionTypeLoadException.cs
- DataColumnCollection.cs
- AssemblyUtil.cs
- PKCS1MaskGenerationMethod.cs
- NativeMethods.cs
- TimeSpanValidator.cs
- RequestTimeoutManager.cs
- RawStylusInput.cs
- ListViewHitTestInfo.cs
- DesignerCommandSet.cs
- SplashScreenNativeMethods.cs
- ObjectDataSourceSelectingEventArgs.cs
- AdRotatorDesigner.cs
- UmAlQuraCalendar.cs
- WebPartCollection.cs
- TypeHelper.cs
- AnnotationStore.cs
- TrustExchangeException.cs
- InputLangChangeRequestEvent.cs
- MSAAWinEventWrap.cs
- ColumnResizeUndoUnit.cs
- CssClassPropertyAttribute.cs
- DefaultTextStoreTextComposition.cs
- IndexedGlyphRun.cs
- HttpContextServiceHost.cs
- PlainXmlDeserializer.cs
- AvTraceFormat.cs