Code:
/ DotNET / DotNET / 8.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
- DataControlPagerLinkButton.cs
- TileModeValidation.cs
- ComponentChangedEvent.cs
- Duration.cs
- XamlGridLengthSerializer.cs
- ReturnType.cs
- DataGridViewColumn.cs
- URLMembershipCondition.cs
- PaperSource.cs
- RSACryptoServiceProvider.cs
- XPathAxisIterator.cs
- ArgumentNullException.cs
- InvariantComparer.cs
- SystemResourceHost.cs
- AtomEntry.cs
- LayoutManager.cs
- GeneralTransform.cs
- WindowsTab.cs
- EntityParameterCollection.cs
- SqlNodeAnnotations.cs
- XPathMultyIterator.cs
- SudsParser.cs
- OpacityConverter.cs
- CodeSnippetTypeMember.cs
- COAUTHINFO.cs
- ListControl.cs
- FunctionMappingTranslator.cs
- RelationshipManager.cs
- DesignTableCollection.cs
- EncodingTable.cs
- ModelItemExtensions.cs
- DataPagerFieldCollection.cs
- KoreanLunisolarCalendar.cs
- ThrowHelper.cs
- NativeObjectSecurity.cs
- SmtpSection.cs
- DesignerActionItemCollection.cs
- PreviewKeyDownEventArgs.cs
- SqlEnums.cs
- PkcsUtils.cs
- TraceShell.cs
- SafeHandles.cs
- SerTrace.cs
- NodeFunctions.cs
- httpstaticobjectscollection.cs
- Serializer.cs
- _ContextAwareResult.cs
- ItemAutomationPeer.cs
- XmlILConstructAnalyzer.cs
- DesignTimeTemplateParser.cs
- CodeBlockBuilder.cs
- CapabilitiesState.cs
- RegisterInfo.cs
- GAC.cs
- Int32AnimationUsingKeyFrames.cs
- CreateUserErrorEventArgs.cs
- BackgroundWorker.cs
- DataListItemEventArgs.cs
- TextViewBase.cs
- AtomParser.cs
- SafeBitVector32.cs
- ObjectCloneHelper.cs
- BaseProcessor.cs
- DocumentXmlWriter.cs
- ReliableSession.cs
- BaseDataBoundControl.cs
- Memoizer.cs
- CollectionView.cs
- XmlText.cs
- OutKeywords.cs
- CreateUserErrorEventArgs.cs
- MDIClient.cs
- CannotUnloadAppDomainException.cs
- MatrixTransform3D.cs
- NonBatchDirectoryCompiler.cs
- TemplatedMailWebEventProvider.cs
- ScrollBarAutomationPeer.cs
- FormsAuthenticationCredentials.cs
- EntityDataSourceDataSelectionPanel.cs
- ConfigurationSectionGroupCollection.cs
- NavigatorOutput.cs
- IdentitySection.cs
- ChannelBinding.cs
- AsynchronousChannelMergeEnumerator.cs
- TCPListener.cs
- GeneralTransform3DCollection.cs
- ProcessManager.cs
- DeferredSelectedIndexReference.cs
- FlowLayout.cs
- XpsFixedDocumentReaderWriter.cs
- SQLInt64Storage.cs
- HandleCollector.cs
- MSAANativeProvider.cs
- InputElement.cs
- SoapConverter.cs
- DescendentsWalkerBase.cs
- FullTrustAssemblyCollection.cs
- DesignTimeTemplateParser.cs
- DBAsyncResult.cs
- LoginView.cs