Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Designer / WinForms / System / WinForms / Design / DesignBinding.cs / 1 / DesignBinding.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms.Design { using System; using System.ComponentModel; using System.Drawing.Design; using System.Globalization; [ Editor("System.Windows.Forms.Design.DesignBindingEditor, " + AssemblyRef.SystemDesign,typeof(UITypeEditor)) ] internal class DesignBinding { private object dataSource; private string dataMember; public static DesignBinding Null = new DesignBinding(null, null); public DesignBinding(object dataSource, string dataMember) { this.dataSource = dataSource; this.dataMember = dataMember; } public bool IsNull { get { return (dataSource == null); } } public object DataSource { get { return dataSource; } } public string DataMember { get { return dataMember; } } public string DataField { get { if (String.IsNullOrEmpty(dataMember)) { return String.Empty; } int lastDot = dataMember.LastIndexOf("."); if (lastDot == -1) { return dataMember; } else { return dataMember.Substring(lastDot+1); } } } public bool Equals(object dataSource, string dataMember) { return (dataSource == this.dataSource && String.Equals(dataMember, this.dataMember, StringComparison.OrdinalIgnoreCase)); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TryExpression.cs
- SystemWebSectionGroup.cs
- BrowserCapabilitiesCompiler.cs
- CertificateElement.cs
- MenuItemBindingCollection.cs
- XmlSchemaComplexContentExtension.cs
- Attribute.cs
- SecurityContextSecurityTokenParameters.cs
- CacheChildrenQuery.cs
- Missing.cs
- UnsettableComboBox.cs
- RightsDocument.cs
- WebScriptClientGenerator.cs
- CompilationSection.cs
- lengthconverter.cs
- Array.cs
- SecurityHeaderLayout.cs
- WebColorConverter.cs
- HtmlControl.cs
- XmlComplianceUtil.cs
- Dump.cs
- SoapFault.cs
- ToolStripItem.cs
- TrackingParameters.cs
- Environment.cs
- NameValueSectionHandler.cs
- HttpModuleActionCollection.cs
- XamlTemplateSerializer.cs
- QilGenerator.cs
- GetIsBrowserClientRequest.cs
- QilXmlReader.cs
- RelatedImageListAttribute.cs
- MSHTMLHostUtil.cs
- ConnectionPointCookie.cs
- HttpConfigurationContext.cs
- AppDomainShutdownMonitor.cs
- CollectionType.cs
- versioninfo.cs
- Soap12ProtocolImporter.cs
- Parameter.cs
- DataGridCaption.cs
- StreamWriter.cs
- PartialList.cs
- FixedSOMTableCell.cs
- FieldBuilder.cs
- CapabilitiesAssignment.cs
- TreeWalkHelper.cs
- DataViewSettingCollection.cs
- PriorityQueue.cs
- ThreadStaticAttribute.cs
- Fault.cs
- SiteMapHierarchicalDataSourceView.cs
- ExceptionUtil.cs
- CustomValidator.cs
- TableCellCollection.cs
- rsa.cs
- recordstatefactory.cs
- AlphabeticalEnumConverter.cs
- DrawingBrush.cs
- SecurityDocument.cs
- ContentPathSegment.cs
- ProfileSection.cs
- RegistryConfigurationProvider.cs
- TreeNodeMouseHoverEvent.cs
- OleDbConnectionPoolGroupProviderInfo.cs
- DrawingBrush.cs
- ProbeRequestResponseAsyncResult.cs
- WindowsListViewGroupSubsetLink.cs
- DataRelation.cs
- BaseParser.cs
- Setter.cs
- ScriptModule.cs
- KerberosReceiverSecurityToken.cs
- Size.cs
- XamlGridLengthSerializer.cs
- CodeTypeDeclarationCollection.cs
- HostedTransportConfigurationManager.cs
- AssemblyNameProxy.cs
- ImageMetadata.cs
- ClientData.cs
- Block.cs
- SafeViewOfFileHandle.cs
- SiteMembershipCondition.cs
- Processor.cs
- SQLConvert.cs
- XmlSerializerFactory.cs
- TextFormatterImp.cs
- AnnotationComponentManager.cs
- DesignerLoader.cs
- ClusterRegistryConfigurationProvider.cs
- ping.cs
- ChtmlSelectionListAdapter.cs
- CodeNamespace.cs
- HttpCachePolicyElement.cs
- DataGridBoolColumn.cs
- PathFigureCollectionConverter.cs
- JavaScriptObjectDeserializer.cs
- SharedStatics.cs
- AmbientLight.cs
- AggregateNode.cs