Skip to content

Commit 30d8fe2

Browse files
Rename a property for consistency.
1 parent cc2d431 commit 30d8fe2

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/NHibernate/Impl/AbstractSessionImpl.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public abstract partial class AbstractSessionImpl : ISessionImplementor
3535
/// <summary>Get the current NHibernate transaction.</summary>
3636
public ITransaction Transaction => ConnectionManager.Transaction;
3737

38-
protected bool TransactionCoordinatorShared { get; }
38+
protected bool IsTransactionCoordinatorShared { get; }
3939

4040
public ITransactionContext TransactionContext
4141
{
@@ -63,7 +63,7 @@ protected internal AbstractSessionImpl(ISessionFactoryImplementor factory, ISess
6363
if (options is ISharedSessionCreationOptions sharedOptions && sharedOptions.IsTransactionCoordinatorShared)
6464
{
6565
// NH specific implementation: need to port Hibernate transaction management.
66-
TransactionCoordinatorShared = true;
66+
IsTransactionCoordinatorShared = true;
6767
if (options.UserSuppliedConnection != null)
6868
throw new SessionException("Cannot simultaneously share transaction context and specify connection");
6969
var connectionManager = sharedOptions.ConnectionManager;
@@ -426,7 +426,7 @@ protected internal void SetClosed()
426426

427427
protected DbConnection CloseConnectionManager()
428428
{
429-
if (!TransactionCoordinatorShared)
429+
if (!IsTransactionCoordinatorShared)
430430
return ConnectionManager.Close();
431431
ConnectionManager.RemoveDependentSession(this);
432432
return null;
@@ -532,7 +532,7 @@ public ITransaction BeginTransaction()
532532
{
533533
using (BeginProcess())
534534
{
535-
if (TransactionCoordinatorShared)
535+
if (IsTransactionCoordinatorShared)
536536
{
537537
// Todo : should seriously consider not allowing a txn to begin from a child session
538538
// can always route the request to the root session...
@@ -552,7 +552,7 @@ public ITransaction BeginTransaction(IsolationLevel isolationLevel)
552552
{
553553
using (BeginProcess())
554554
{
555-
if (TransactionCoordinatorShared)
555+
if (IsTransactionCoordinatorShared)
556556
{
557557
// Todo : should seriously consider not allowing a txn to begin from a child session
558558
// can always route the request to the root session...

src/NHibernate/Impl/SessionImpl.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ void ISerializable.GetObjectData(SerializationInfo info, StreamingContext contex
121121
{
122122
throw new InvalidOperationException("Cannot serialize a Session while connected");
123123
}
124-
if (TransactionCoordinatorShared)
124+
if (IsTransactionCoordinatorShared)
125125
{
126126
throw new InvalidOperationException("Cannot serialize a Session sharing its transaction coordinator");
127127
}

0 commit comments

Comments
 (0)