You've already forked linux-packaging-mono
Imported Upstream version 4.6.0.125
Former-commit-id: a2155e9bd80020e49e72e86c44da02a8ac0e57a4
This commit is contained in:
parent
a569aebcfd
commit
e79aa3c0ed
@ -0,0 +1,83 @@
|
||||
//---------------------------------------------------------------------
|
||||
// <copyright file="ObjectResult.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// </copyright>
|
||||
//
|
||||
// @owner [....]
|
||||
// @backupowner [....]
|
||||
//---------------------------------------------------------------------
|
||||
|
||||
namespace System.Data.Objects
|
||||
{
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.ComponentModel;
|
||||
|
||||
/// <summary>
|
||||
/// This class implements IEnumerable and IDisposable. Instance of this class
|
||||
/// is returned from ObjectQuery.Execute method.
|
||||
/// </summary>
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1710:IdentifiersShouldHaveCorrectSuffix")]
|
||||
public abstract class ObjectResult : IEnumerable, IDisposable, IListSource
|
||||
{
|
||||
internal ObjectResult()
|
||||
{
|
||||
}
|
||||
|
||||
IEnumerator IEnumerable.GetEnumerator()
|
||||
{
|
||||
return this.GetEnumeratorInternal();
|
||||
}
|
||||
|
||||
// ----------------------
|
||||
// IListSource Properties
|
||||
// ----------------------
|
||||
/// <summary>
|
||||
/// IListSource.ContainsListCollection implementation. Always returns false.
|
||||
/// </summary>
|
||||
bool IListSource.ContainsListCollection
|
||||
{
|
||||
get
|
||||
{
|
||||
return false; // this means that the IList we return is the one which contains our actual data, it is not a collection
|
||||
}
|
||||
}
|
||||
|
||||
// ----------------------
|
||||
// IListSource method
|
||||
// ----------------------
|
||||
/// <summary>
|
||||
/// IListSource.GetList implementation
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// IList interface over the data to bind
|
||||
/// </returns>
|
||||
IList IListSource.GetList()
|
||||
{
|
||||
return this.GetIListSourceListInternal();
|
||||
}
|
||||
|
||||
public abstract Type ElementType
|
||||
{
|
||||
get;
|
||||
}
|
||||
|
||||
public abstract void Dispose();
|
||||
|
||||
/// <summary>
|
||||
/// Get the next result set of a stored procedure.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// An ObjectResult that enumerates the values of the next result set. null, if there are no more, or if the
|
||||
/// the ObjectResult is not the result of a stored procedure call.
|
||||
/// </returns>
|
||||
public ObjectResult<TElement> GetNextResult<TElement>()
|
||||
{
|
||||
return this.GetNextResultInternal<TElement>();
|
||||
}
|
||||
|
||||
internal abstract IEnumerator GetEnumeratorInternal();
|
||||
internal abstract IList GetIListSourceListInternal();
|
||||
internal abstract ObjectResult<TElement> GetNextResultInternal<TElement>();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user