Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / DataSet / System / Data / TypedTableBase.cs / 1305376 / TypedTableBase.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //spather //----------------------------------------------------------------------------- using System; using System.Collections.Generic; using System.Collections; using System.Linq; using System.Linq.Expressions; using System.Runtime.Serialization; namespace System.Data { ////// This is the generic base class for TypedDataSet /// [Serializable] public abstract class TypedTableBase: DataTable, IEnumerable where T : DataRow { /// /// Default constructor for generic TypedTableBase. /// Will be called by generated Typed DataSet classes and is not for public use. /// protected TypedTableBase() : base() {} ////// Constructor for the generic TypedTableBase with takes SerializationInfo and StreamingContext. /// Will be called by generated Typed DataSet classes and /// is not for public use. /// /// /// SerializationInfo containing data to construct the object. /// /// /// The streaming context for the object being deserializad. /// protected TypedTableBase(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context) : base(info, context) {} ////// This property returns a enumerator of T for the TypedTable. Note, this could /// execute the underlying Linq expression. /// ////// IEnumerable of T. /// public IEnumeratorGetEnumerator() { return this.Rows.Cast ().GetEnumerator(); } IEnumerator IEnumerable.GetEnumerator() { return GetEnumerator(); } /// /// Casts an EnumerableDataTable_TSource into EnumerableDataTable_TResult /// public EnumerableRowCollectionCast () { EnumerableRowCollection erc = new EnumerableRowCollection ((DataTable)this); return erc.Cast (); } } } // 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
- PhysicalOps.cs
- RowBinding.cs
- ManageRequest.cs
- FormsAuthentication.cs
- XamlStream.cs
- TextInfo.cs
- BrowsableAttribute.cs
- XamlRtfConverter.cs
- PropertyExpression.cs
- DeleteStoreRequest.cs
- LocationFactory.cs
- PerspectiveCamera.cs
- AlphaSortedEnumConverter.cs
- HyperLinkStyle.cs
- UserNameSecurityTokenAuthenticator.cs
- ListDictionary.cs
- codemethodreferenceexpression.cs
- XmlBindingWorker.cs
- updateconfighost.cs
- sapiproxy.cs
- _AutoWebProxyScriptEngine.cs
- RowsCopiedEventArgs.cs
- LogReserveAndAppendState.cs
- SudsWriter.cs
- ProcessHost.cs
- AuthenticateEventArgs.cs
- AdapterUtil.cs
- AlternateViewCollection.cs
- TcpHostedTransportConfiguration.cs
- EndpointDispatcherTable.cs
- ArrayListCollectionBase.cs
- Predicate.cs
- SetterTriggerConditionValueConverter.cs
- XPathScanner.cs
- CodeAccessPermission.cs
- PageThemeCodeDomTreeGenerator.cs
- HttpContext.cs
- JulianCalendar.cs
- DocumentXPathNavigator.cs
- ReadOnlyPropertyMetadata.cs
- DataGridViewCellValueEventArgs.cs
- FixedDSBuilder.cs
- ObjectConverter.cs
- StatusStrip.cs
- TempFiles.cs
- HtmlTableCellCollection.cs
- XMLSchema.cs
- PrefixQName.cs
- GenericEnumConverter.cs
- TypeUtils.cs
- RoleGroup.cs
- MenuStrip.cs
- DirectionalLight.cs
- DataSourceXmlSubItemAttribute.cs
- Update.cs
- BrowserInteropHelper.cs
- FrameworkObject.cs
- AsymmetricAlgorithm.cs
- ReferencedCategoriesDocument.cs
- IgnoreDataMemberAttribute.cs
- ParallelActivityDesigner.cs
- SqlCacheDependencySection.cs
- CellTreeNode.cs
- GZipDecoder.cs
- M3DUtil.cs
- DataObject.cs
- BufferedReadStream.cs
- ObjectViewQueryResultData.cs
- SuppressMergeCheckAttribute.cs
- DirectoryLocalQuery.cs
- SerializerDescriptor.cs
- HttpChannelHelpers.cs
- SuppressMergeCheckAttribute.cs
- FontNameEditor.cs
- SiteMapNode.cs
- TreeViewHitTestInfo.cs
- BufferModeSettings.cs
- XPathSelfQuery.cs
- StaticExtension.cs
- DataDesignUtil.cs
- ManualResetEvent.cs
- KeyValuePair.cs
- XmlObjectSerializerWriteContext.cs
- DbConnectionHelper.cs
- LOSFormatter.cs
- MetadataItem_Static.cs
- OptionalColumn.cs
- UnitControl.cs
- ProcessHostMapPath.cs
- QilParameter.cs
- SqlInternalConnectionSmi.cs
- MethodExecutor.cs
- List.cs
- OneOfElement.cs
- PartitionResolver.cs
- ClientSponsor.cs
- DbgCompiler.cs
- DataTableMapping.cs
- DataObjectAttribute.cs
- ManagementClass.cs