Class PetaPocoDataContext
Inheritance
System.Object
PetaPocoDataContext
Assembly: DotNetNuke.dll
Syntax
public class PetaPocoDataContext : object, IDataContext
Constructors
|
Improve this Doc
View Source
PetaPocoDataContext()
Declaration
public PetaPocoDataContext()
|
Improve this Doc
View Source
PetaPocoDataContext(String, String, Dictionary<Type, IMapper>)
Declaration
public PetaPocoDataContext(string connectionStringName, string tablePrefix, Dictionary<Type, IMapper> mappers)
Parameters
Type |
Name |
Description |
System.String |
connectionStringName |
|
System.String |
tablePrefix |
|
Dictionary<Type, IMapper> |
mappers |
|
|
Improve this Doc
View Source
PetaPocoDataContext(String, String)
Declaration
public PetaPocoDataContext(string connectionStringName, string tablePrefix)
Parameters
Type |
Name |
Description |
System.String |
connectionStringName |
|
System.String |
tablePrefix |
|
|
Improve this Doc
View Source
PetaPocoDataContext(String)
Declaration
public PetaPocoDataContext(string connectionStringName)
Parameters
Type |
Name |
Description |
System.String |
connectionStringName |
|
Properties
|
Improve this Doc
View Source
EnableAutoSelect
Declaration
public bool EnableAutoSelect { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
FluentMappers
Declaration
public Dictionary<Type, IMapper> FluentMappers { get; }
Property Value
Type |
Description |
Dictionary<Type, IMapper> |
|
|
Improve this Doc
View Source
TablePrefix
Declaration
public string TablePrefix { get; }
Property Value
Type |
Description |
System.String |
|
Methods
|
Improve this Doc
View Source
BeginTransaction()
Declaration
public void BeginTransaction()
|
Improve this Doc
View Source
Commit()
Declaration
|
Improve this Doc
View Source
Dispose()
Declaration
|
Improve this Doc
View Source
Execute(CommandType, String, Object[])
Declaration
public void Execute(CommandType type, string sql, params object[] args)
Parameters
Type |
Name |
Description |
CommandType |
type |
|
System.String |
sql |
|
System.Object[] |
args |
|
|
Improve this Doc
View Source
ExecuteQuery<T>(CommandType, String, Object[])
Declaration
public IEnumerable<T> ExecuteQuery<T>(CommandType type, string sql, params object[] args)
Parameters
Type |
Name |
Description |
CommandType |
type |
|
System.String |
sql |
|
System.Object[] |
args |
|
Returns
Type |
Description |
IEnumerable<T> |
|
Type Parameters
|
Improve this Doc
View Source
ExecuteScalar<T>(CommandType, String, Object[])
Declaration
public T ExecuteScalar<T>(CommandType type, string sql, params object[] args)
Parameters
Type |
Name |
Description |
CommandType |
type |
|
System.String |
sql |
|
System.Object[] |
args |
|
Returns
Type Parameters
|
Improve this Doc
View Source
ExecuteSingleOrDefault<T>(CommandType, String, Object[])
Declaration
public T ExecuteSingleOrDefault<T>(CommandType type, string sql, params object[] args)
Parameters
Type |
Name |
Description |
CommandType |
type |
|
System.String |
sql |
|
System.Object[] |
args |
|
Returns
Type Parameters
|
Improve this Doc
View Source
GetRepository<T>()
Declaration
public IRepository<T> GetRepository<T>()
where T : class
Returns
Type Parameters
|
Improve this Doc
View Source
RollbackTransaction()
Declaration
public void RollbackTransaction()
Implements
IDisposable
Extension Methods