Skip to content

Commit dbc5d97

Browse files
committed
Fix indents
1 parent 8cd649c commit dbc5d97

File tree

9 files changed

+43
-43
lines changed

9 files changed

+43
-43
lines changed

src/NHibernate/Criterion/Example.cs

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,8 @@ public override String ToString()
267267
private bool IsPropertyIncluded(object value, String name, IType type)
268268
{
269269
return !_excludedProperties.Contains(name) &&
270-
!type.IsAssociationType &&
271-
_selector.Include(value, name, type);
270+
!type.IsAssociationType &&
271+
_selector.Include(value, name, type);
272272
}
273273

274274
private object[] GetPropertyValues(IEntityPersister persister, ICriteria criteria, ICriteriaQuery criteriaQuery)
@@ -310,7 +310,7 @@ public override SqlString ToSqlString(ICriteria criteria, ICriteriaQuery criteri
310310
String propertyName = propertyNames[i];
311311

312312
bool isPropertyIncluded = i != meta.VersionProperty &&
313-
IsPropertyIncluded(propertyValue, propertyName, propertyTypes[i]);
313+
IsPropertyIncluded(propertyValue, propertyName, propertyTypes[i]);
314314
if (isPropertyIncluded)
315315
{
316316
if (propertyTypes[i].IsComponentType)
@@ -476,19 +476,19 @@ protected void AppendPropertyCondition(
476476
}
477477

478478
ICriterion crit = propertyValue != null
479-
? GetNotNullPropertyCriterion(propertyValue, propertyName)
480-
: new NullExpression(propertyName);
479+
? GetNotNullPropertyCriterion(propertyValue, propertyName)
480+
: new NullExpression(propertyName);
481481
builder.Add(crit.ToSqlString(criteria, cq, enabledFilters));
482482
}
483483

484484
protected virtual ICriterion GetNotNullPropertyCriterion(object propertyValue, string propertyName)
485485
{
486486
bool isString = propertyValue is string;
487487
return (_isLikeEnabled && isString)
488-
? (ICriterion)
489-
new LikeExpression(propertyName, propertyValue.ToString(), _matchMode, escapeCharacter,
490-
_isIgnoreCaseEnabled)
491-
: new SimpleExpression(propertyName, propertyValue, " = ", _isIgnoreCaseEnabled && isString);
488+
? (ICriterion)
489+
new LikeExpression(propertyName, propertyValue.ToString(), _matchMode, escapeCharacter,
490+
_isIgnoreCaseEnabled)
491+
: new SimpleExpression(propertyName, propertyValue, " = ", _isIgnoreCaseEnabled && isString);
492492
}
493493

494494
protected void AppendComponentCondition(

src/NHibernate/Criterion/SqlFunctionProjection.cs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public override bool IsGrouped
5252
}
5353

5454
public override SqlString ToGroupSqlString(ICriteria criteria, ICriteriaQuery criteriaQuery,
55-
IDictionary<string, IFilter> enabledFilters)
55+
IDictionary<string, IFilter> enabledFilters)
5656
{
5757
SqlStringBuilder buf = new SqlStringBuilder();
5858
foreach (IProjection projection in args)
@@ -70,19 +70,19 @@ public override SqlString ToGroupSqlString(ICriteria criteria, ICriteriaQuery cr
7070
}
7171

7272
public override SqlString ToSqlString(ICriteria criteria, int position, ICriteriaQuery criteriaQuery,
73-
IDictionary<string, IFilter> enabledFilters)
73+
IDictionary<string, IFilter> enabledFilters)
7474
{
7575
ISQLFunction sqlFunction = GetFunction(criteriaQuery);
7676

7777
var arguments = new ArrayList();
78-
for (int i = 0; i < args.Length; i++)
79-
{
80-
SqlString projectArg = GetProjectionArgument(criteriaQuery, criteria, args[i], 0, enabledFilters); // The loc parameter is unused.
81-
arguments.Add(projectArg);
82-
}
78+
for (int i = 0; i < args.Length; i++)
79+
{
80+
SqlString projectArg = GetProjectionArgument(criteriaQuery, criteria, args[i], 0, enabledFilters); // The loc parameter is unused.
81+
arguments.Add(projectArg);
82+
}
8383

84-
SqlStringBuilder sb = new SqlStringBuilder();
85-
sb.Add(sqlFunction.Render(arguments, criteriaQuery.Factory));
84+
SqlStringBuilder sb = new SqlStringBuilder();
85+
sb.Add(sqlFunction.Render(arguments, criteriaQuery.Factory));
8686
sb.Add(" as ");
8787
sb.Add(GetColumnAliases(position)[0]);
8888
return sb.ToSqlString();
@@ -98,14 +98,14 @@ private ISQLFunction GetFunction(ICriteriaQuery criteriaQuery)
9898
if (dialectFunction == null)
9999
{
100100
throw new HibernateException("Current dialect " + criteriaQuery.Factory.Dialect + " doesn't support the function: "
101-
+ functionName);
101+
+ functionName);
102102
}
103103
return dialectFunction;
104104
}
105105

106106
private static SqlString GetProjectionArgument(ICriteriaQuery criteriaQuery, ICriteria criteria,
107-
IProjection projection, int loc,
108-
IDictionary<string, IFilter> enabledFilters)
107+
IProjection projection, int loc,
108+
IDictionary<string, IFilter> enabledFilters)
109109
{
110110
SqlString sql = projection.ToSqlString(criteria, loc, criteriaQuery, enabledFilters);
111111
return StringHelper.RemoveAsAliasesFromSql(sql);

src/NHibernate/Hql/Classic/QueryTranslator.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ private static string GenerateSuffix(int count)
104104
private static bool IsUnsafe(ICollectionPersister collectionPersister)
105105
{
106106
return collectionPersister.CollectionType is BagType
107-
|| collectionPersister.CollectionType is IdentifierBagType;
107+
|| collectionPersister.CollectionType is IdentifierBagType;
108108
}
109109

110110
public void Add(string name, ICollectionPersister collectionPersister, string ownerName)
@@ -532,9 +532,9 @@ internal string GetRole(string name)
532532
internal bool IsName(string name)
533533
{
534534
return aliasNames.ContainsKey(name) ||
535-
typeMap.ContainsKey(name) ||
536-
collections.ContainsKey(name) ||
537-
(superQuery != null && superQuery.IsName(name));
535+
typeMap.ContainsKey(name) ||
536+
collections.ContainsKey(name) ||
537+
(superQuery != null && superQuery.IsName(name));
538538
}
539539

540540
public IPropertyMapping GetPropertyMapping(string name)
@@ -1499,7 +1499,7 @@ private static string[][] GenerateColumnNames(IType[] types, ISessionFactoryImpl
14991499
}
15001500

15011501
protected override object GetResultColumnOrRow(object[] row, IResultTransformer resultTransformer, IDataReader rs,
1502-
ISessionImplementor session)
1502+
ISessionImplementor session)
15031503
{
15041504
IType[] _returnTypes = ReturnTypes;
15051505
row = ToResultRow(row);

src/NHibernate/Hql/QuerySplitter.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -93,8 +93,8 @@ public static string[] ConcreteQueries(string query, ISessionFactoryImplementor
9393
// TODO H3.2 Different behavior
9494
// NHb: This block is not an exactly port from H3.2 but a port from previous implementation of QueryTranslator
9595
if (((last != null && beforeClassTokens.Contains(last)) &&
96-
(next == null || !notAfterClassTokens.Contains(next))) ||
97-
PathExpressionParser.EntityClass.Equals(last))
96+
(next == null || !notAfterClassTokens.Contains(next))) ||
97+
PathExpressionParser.EntityClass.Equals(last))
9898
{
9999
System.Type clazz = helper.GetImportedClass(token);
100100
if (clazz != null)
@@ -125,7 +125,7 @@ public static string[] ConcreteQueries(string query, ISessionFactoryImplementor
125125
private static bool IsPossiblyClassName(string last, string next)
126126
{
127127
return PathExpressionParser.EntityClass.Equals(last) ||
128-
(beforeClassTokens.Contains(last) && !notAfterClassTokens.Contains(next));
128+
(beforeClassTokens.Contains(last) && !notAfterClassTokens.Contains(next));
129129
}
130130
}
131131
}

src/NHibernate/Impl/MultipleQueriesCacheAssembler.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ public void BeforeAssemble(object cached, ISessionImplementor session) {}
7373
#endregion
7474

7575
public IList GetResultFromQueryCache(ISessionImplementor session, QueryParameters queryParameters,
76-
ISet<string> querySpaces, IQueryCache queryCache, QueryKey key)
76+
ISet<string> querySpaces, IQueryCache queryCache, QueryKey key)
7777
{
7878
if (!queryParameters.ForceCacheRefresh)
7979
{

src/NHibernate/Loader/Custom/Sql/SQLQueryReturnProcessor.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ public IList GenerateCustomReturns(bool queryHadAliases)
333333
{
334334
collectionAliases =
335335
new GeneratedCollectionAliases(collectionPropertyResultMaps[alias], alias2CollectionPersister[alias],
336-
alias2CollectionSuffix[alias]);
336+
alias2CollectionSuffix[alias]);
337337
if (isEntityElements)
338338
{
339339
elementEntityAliases =
@@ -352,7 +352,7 @@ public IList GenerateCustomReturns(bool queryHadAliases)
352352
}
353353
CollectionReturn customReturn =
354354
new CollectionReturn(alias, rtn.OwnerEntityName, rtn.OwnerProperty, collectionAliases, elementEntityAliases,
355-
rtn.LockMode);
355+
rtn.LockMode);
356356
customReturns.Add(customReturn);
357357
customReturnsByAlias[rtn.Alias] = customReturn;
358358
}
@@ -389,7 +389,7 @@ public IList GenerateCustomReturns(bool queryHadAliases)
389389
}
390390
customReturn =
391391
new CollectionFetchReturn(alias, ownerCustomReturn, rtn.OwnerProperty, collectionAliases, elementEntityAliases,
392-
rtn.LockMode);
392+
rtn.LockMode);
393393
}
394394
else
395395
{

src/NHibernate/Type/CollectionType.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ public virtual object InstantiateResult(object original)
329329
}
330330

331331
public override object Replace(object original, object target, ISessionImplementor session, object owner,
332-
IDictionary copyCache)
332+
IDictionary copyCache)
333333
{
334334
if (original == null)
335335
{
@@ -342,8 +342,8 @@ public override object Replace(object original, object target, ISessionImplement
342342
}
343343

344344
object result = target == null || target == original
345-
? InstantiateResult(original)
346-
: target;
345+
? InstantiateResult(original)
346+
: target;
347347

348348
//for arrays, replaceElements() may return a different reference, since
349349
//the array length might not match
@@ -362,7 +362,7 @@ public override object Replace(object original, object target, ISessionImplement
362362
}
363363

364364
public virtual object ReplaceElements(object original, object target, object owner, IDictionary copyCache,
365-
ISessionImplementor session)
365+
ISessionImplementor session)
366366
{
367367
// TODO: does not work for EntityMode.DOM4J yet!
368368
object result = target;
@@ -453,7 +453,7 @@ public override bool IsDirty(object old, object current, bool[] checkable, ISess
453453
}
454454

455455
public override bool IsModified(object oldHydratedState, object currentState, bool[] checkable,
456-
ISessionImplementor session)
456+
ISessionImplementor session)
457457
{
458458
return false;
459459
}
@@ -586,9 +586,9 @@ public virtual bool Contains(object collection, object childObject, ISessionImpl
586586

587587
if (element.IsProxy())
588588
{
589-
INHibernateProxy proxy = element as INHibernateProxy;
590-
591-
ILazyInitializer li = proxy.HibernateLazyInitializer;
589+
INHibernateProxy proxy = element as INHibernateProxy;
590+
591+
ILazyInitializer li = proxy.HibernateLazyInitializer;
592592
if (!li.IsUninitialized)
593593
element = li.GetImplementation();
594594
}

src/NHibernate/Util/StringHelper.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -629,7 +629,7 @@ private static string GenerateAliasRoot(string description)
629629
{
630630
return result;
631631
}
632-
return "alias_" + result;
632+
return "alias_" + result;
633633
}
634634

635635
public static string MoveAndToBeginning(string filter)

src/NHibernate/Util/WeakHashtable.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public override bool Equals(object obj)
4242
}
4343

4444
return hashCode == that.hashCode &&
45-
Equals(target, that.Target);
45+
Equals(target, that.Target);
4646
}
4747

4848
public override int GetHashCode()

0 commit comments

Comments
 (0)