Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / SourceItem.cs / 1 / SourceItem.cs
using System; namespace System.Windows { // An item in the source context internal struct SourceItem { #region Construction // Constructor for SourceItem internal SourceItem(int startIndex, object source) { _startIndex = startIndex; _source = source; } #endregion Construction #region Operations // Gettor for StartIndex internal int StartIndex { get { return _startIndex; } } // Gettor for Source internal object Source { get { return _source; } } /* Commented out to avoid "uncalled private code" fxcop violation ////// Cleanup all the references within the data /// internal void Clear() { _startIndex = -1; _source = null; } */ ////// Is the given object equals the current /// public override bool Equals(object o) { return Equals((SourceItem)o); } ////// Is the given SourceItem equals the current /// public bool Equals(SourceItem sourceItem) { return ( sourceItem._startIndex == this._startIndex && sourceItem._source == this._source); } ////// Serves as a hash function for a particular type, suitable for use in /// hashing algorithms and data structures like a hash table /// public override int GetHashCode() { return base.GetHashCode(); } ////// Equals operator overload /// public static bool operator== (SourceItem sourceItem1, SourceItem sourceItem2) { return sourceItem1.Equals(sourceItem2); } ////// NotEquals operator overload /// public static bool operator!= (SourceItem sourceItem1, SourceItem sourceItem2) { return !sourceItem1.Equals(sourceItem2); } #endregion Operations #region Data private int _startIndex; private object _source; #endregion Data } } // 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
- Subtree.cs
- MouseOverProperty.cs
- WebExceptionStatus.cs
- ListDictionaryInternal.cs
- UInt32Converter.cs
- CalendarTable.cs
- ThemeConfigurationDialog.cs
- ExtensionElement.cs
- ExtenderControl.cs
- UrlMappingsSection.cs
- URI.cs
- GlobalizationSection.cs
- PagesChangedEventArgs.cs
- DataGridViewCellValidatingEventArgs.cs
- SemanticBasicElement.cs
- ResumeStoryboard.cs
- NativeMethods.cs
- ActivatableWorkflowsQueryResult.cs
- Attributes.cs
- ContentElement.cs
- ImportOptions.cs
- CaretElement.cs
- DataTableExtensions.cs
- ToolStripProgressBar.cs
- ListViewTableRow.cs
- WmpBitmapEncoder.cs
- XmlSchemaComplexContentRestriction.cs
- PointConverter.cs
- ApplyHostConfigurationBehavior.cs
- EntitySqlQueryState.cs
- NotifyInputEventArgs.cs
- ZoneIdentityPermission.cs
- Panel.cs
- CalendarTable.cs
- UnsignedPublishLicense.cs
- DataReceivedEventArgs.cs
- LinkedResource.cs
- PenContext.cs
- DataGridPagingPage.cs
- AxHostDesigner.cs
- SharedUtils.cs
- CopyCodeAction.cs
- FrameworkPropertyMetadata.cs
- SmiConnection.cs
- DbParameterHelper.cs
- RuleProcessor.cs
- NetworkInformationException.cs
- NetNamedPipeBindingCollectionElement.cs
- ThreadStateException.cs
- SiteMapNode.cs
- RemoteTokenFactory.cs
- TypeLoadException.cs
- CreateUserWizardAutoFormat.cs
- OdbcRowUpdatingEvent.cs
- Int32KeyFrameCollection.cs
- FactoryGenerator.cs
- SHA384.cs
- ServiceNameElement.cs
- RegisteredHiddenField.cs
- DataSourceXmlAttributeAttribute.cs
- DataBindingExpressionBuilder.cs
- ConstraintCollection.cs
- ipaddressinformationcollection.cs
- BStrWrapper.cs
- NativeObjectSecurity.cs
- StylusSystemGestureEventArgs.cs
- ExtensionSimplifierMarkupObject.cs
- DataStorage.cs
- BoundingRectTracker.cs
- Int32RectValueSerializer.cs
- DrawingServices.cs
- CheckBoxFlatAdapter.cs
- WindowsFont.cs
- SetterBaseCollection.cs
- BlurEffect.cs
- TargetException.cs
- VerticalAlignConverter.cs
- WindowClosedEventArgs.cs
- Touch.cs
- IsolatedStorage.cs
- ImageMapEventArgs.cs
- _OSSOCK.cs
- HtmlElementErrorEventArgs.cs
- SqlConnectionPoolGroupProviderInfo.cs
- CqlErrorHelper.cs
- BoundsDrawingContextWalker.cs
- DependencyPropertyDescriptor.cs
- WrappedReader.cs
- AbsoluteQuery.cs
- TypedDatasetGenerator.cs
- wmiprovider.cs
- SmtpReplyReaderFactory.cs
- ByteRangeDownloader.cs
- SamlAuthorizationDecisionClaimResource.cs
- TreeView.cs
- QuotedPrintableStream.cs
- AutoResizedEvent.cs
- QualifierSet.cs
- MemoryMappedFile.cs
- CaseExpr.cs