Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / UI / DataBinding.cs / 1305376 / DataBinding.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.Web.UI { using System; using System.ComponentModel; using System.ComponentModel.Design; using System.Data; using System.Globalization; using System.Security.Permissions; using System.Web.Util; ////// public sealed class DataBinding { private string propertyName; private Type propertyType; private string expression; ///Enables RAD designers to create data binding expressions /// at design time. This class cannot be inherited. ////// public DataBinding(string propertyName, Type propertyType, string expression) { this.propertyName = propertyName; this.propertyType = propertyType; this.expression = expression; } ///Initializes a new instance of the ///class. /// public string Expression { get { return expression; } set { Debug.Assert((value != null) && (value.Length != 0), "Invalid expression"); expression = value; } } ///Indicates the data binding expression to be evaluated. ////// public string PropertyName { get { return propertyName; } } ///Indicates the name of the property that is to be data bound against. This /// property is read-only. ////// public Type PropertyType { get { return propertyType; } } ///Indicates the type of the data bound property. This property is /// read-only. ////// DataBinding objects are placed in a hashtable representing the collection /// of bindings on a control. There can only be one binding/property, so /// the hashcode computation should match the Equals implementation and only /// take the property name into account. /// public override int GetHashCode() { return propertyName.ToLower(CultureInfo.InvariantCulture).GetHashCode(); } ////// public override bool Equals(object obj) { if ((obj != null) && (obj is DataBinding)) { DataBinding binding = (DataBinding)obj; return StringUtil.EqualsIgnoreCase(propertyName, binding.PropertyName); } return false; } } } // 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
- WindowsBrush.cs
- RequiredFieldValidator.cs
- TreeView.cs
- _HelperAsyncResults.cs
- SourceFileBuildProvider.cs
- ScrollPattern.cs
- ActiveXHelper.cs
- SecurityCriticalDataForSet.cs
- ConnectionOrientedTransportBindingElement.cs
- OdbcHandle.cs
- Quad.cs
- XmlQualifiedName.cs
- QuotedPrintableStream.cs
- Tuple.cs
- BinHexDecoder.cs
- DefaultValueMapping.cs
- EmptyCollection.cs
- SequenceRangeCollection.cs
- PackageController.cs
- XsltContext.cs
- PathFigureCollectionConverter.cs
- XPathDocumentBuilder.cs
- CellRelation.cs
- SqlErrorCollection.cs
- ObjectStateFormatter.cs
- TimeoutException.cs
- UInt64.cs
- RIPEMD160.cs
- EntityDataSourceValidationException.cs
- TemplateNodeContextMenu.cs
- SectionUpdates.cs
- ExceptionRoutedEventArgs.cs
- AnimatedTypeHelpers.cs
- StyleHelper.cs
- XmlNode.cs
- PointLightBase.cs
- OperandQuery.cs
- TextElementAutomationPeer.cs
- EtwTrackingBehaviorElement.cs
- DispatcherObject.cs
- EventData.cs
- CollectionViewGroup.cs
- SynchronizedChannelCollection.cs
- COM2IPerPropertyBrowsingHandler.cs
- StringReader.cs
- WebBrowserDesigner.cs
- EnumValidator.cs
- SiteMapPathDesigner.cs
- DataGridViewImageCell.cs
- Expression.cs
- FormatConvertedBitmap.cs
- RegexCompilationInfo.cs
- SchemaTypeEmitter.cs
- OpenFileDialog.cs
- BinaryFormatter.cs
- ToolStripMenuItem.cs
- Debug.cs
- PenLineJoinValidation.cs
- StringUtil.cs
- AuthenticationManager.cs
- Simplifier.cs
- CategoryGridEntry.cs
- EdmComplexPropertyAttribute.cs
- FileLogRecordHeader.cs
- OutputCacheEntry.cs
- BuildProvider.cs
- WebZone.cs
- CLRBindingWorker.cs
- PointAnimationUsingKeyFrames.cs
- ExtendedPropertyCollection.cs
- IERequestCache.cs
- TimeManager.cs
- ToolStripSplitStackLayout.cs
- XmlQualifiedName.cs
- DSACryptoServiceProvider.cs
- ServiceParser.cs
- WmlLiteralTextAdapter.cs
- WebBaseEventKeyComparer.cs
- InstanceBehavior.cs
- XmlSchemaSet.cs
- AnnotationResourceCollection.cs
- SqlProviderServices.cs
- LinqExpressionNormalizer.cs
- TextReader.cs
- XmlCDATASection.cs
- ContentFilePart.cs
- BinaryCommonClasses.cs
- HtmlFormAdapter.cs
- HtmlLink.cs
- VisemeEventArgs.cs
- PageParserFilter.cs
- PolyBezierSegment.cs
- RoutingExtensionElement.cs
- WebControl.cs
- RuntimeCompatibilityAttribute.cs
- CookieParameter.cs
- ObjectManager.cs
- FlowLayout.cs
- XmlSchemaObjectTable.cs
- ConfigurationLocationCollection.cs