|
#region "Using directives"
using System;
using System.Data;
using System.Collections;
using System.Diagnostics;
using SmartInstitute;
#endregion
namespace SmartInstitute.DataAccessLayer
{
///<summary>
/// This class is the base Repository that exposes CRUD methods for Permission objects.
///</summary>
public interface IPermissionRepository
{
#region "Get from Many To Many Relationship Functions"
#endregion
/// <summary>
/// Deletes a row from the DataSource.
/// </summary>
/// <param name="ID">. Primary Key.</param>
/// <remarks>Deletes based on primary key(s).</remarks>
/// <returns>Returns true if operation suceeded.</returns>
bool Delete(System.Int32 ID, DateTime ChangeStamp);
/// <summary>
/// Gets All rows from the DataSource.
/// </summary>
/// <param name="start">Row number at which to start reading.</param>
/// <param name="pagelen">Number of rows to return.</param>
/// <remarks></remarks>
/// <returns>Returns a typed collection of Permission objects.</returns>
PermissionCollection GetAll( int start, int pagelen);
/// <summary>
/// Gets a page of rows from the DataSource.
/// </summary>
/// <param name="start">Row number at which to start reading.</param>
/// <param name="pageLength">Number of rows to return.</param>
/// <param name="count">Number of rows in the DataSource.</param>
/// <param name="whereClause">Specifies the condition for the rows returned by a query (Name='John Doe', Name='John Doe' AND Id='1', Name='John Doe' OR Id='1').</param>
/// <param name="orderBy">Specifies the sort criteria for the rows in the DataSource (Name ASC; BirthDay DESC, Name ASC);</param>
/// <remarks></remarks>
/// <returns>Returns a typed collection of Permission objects.</returns>
PermissionCollection GetPaged(string whereClause, string orderBy, int start, int pageLength, out int count);
/// <summary>
/// Gets rows from the datasource based on the PK_Permission index.
/// </summary>
/// <param name="start">Row number at which to start reading.</param>
/// <param name="pagelen">Number of rows to return.</param>
/// <param name="ID"></param>
/// <remarks></remarks>
/// <returns>Returns a typed collection of Permission objects.</returns>
PermissionCollection GetByID(System.Int32 ID, int start, int pagelen);
/// <summary>
/// Inserts a Permission object into the datasource using a transaction.
/// </summary>
/// <param name="entity">Permission object to insert.</param>
/// <remarks>After inserting into the datasource, the Permission object will be updated
/// to refelect any changes made by the datasource. (ie: identity columns)</remarks>
/// <returns>Returns true if operation is successful.</returns>
bool Insert(Permission entity);
/// <summary>
/// Update an existing row in the datasource.
/// </summary>
/// <param name="entity">Permission object to update.</param>
/// <remarks>After updating the datasource, the Permission object will be updated
/// to refelect any changes made by the datasource. (ie: identity columns)</remarks>
/// <returns>Returns true if operation is successful.</returns>
bool Update(Permission entity);
}//end class
} // end namespace
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.
A list of licenses authors might use can be found here