@@ -28,8 +28,8 @@ public interface INestedFilter : IFilter
2828 [ JsonProperty ( "path" ) ]
2929 PropertyPathMarker Path { get ; set ; }
3030
31- [ JsonProperty ( "_scope " ) ]
32- string Scope { get ; set ; }
31+ [ JsonProperty ( "join " ) ]
32+ bool ? Join { get ; set ; }
3333 }
3434
3535 public class NestedFilter : PlainFilter , INestedFilter
@@ -43,7 +43,7 @@ protected internal override void WrapInContainer(IFilterContainer container)
4343 public IFilterContainer Filter { get ; set ; }
4444 public IQueryContainer Query { get ; set ; }
4545 public PropertyPathMarker Path { get ; set ; }
46- public string Scope { get ; set ; }
46+ public bool ? Join { get ; set ; }
4747 }
4848
4949 public class NestedFilterDescriptor < T > : FilterBase , INestedFilter where T : class
@@ -56,7 +56,7 @@ public class NestedFilterDescriptor<T> : FilterBase, INestedFilter where T : cla
5656
5757 PropertyPathMarker INestedFilter . Path { get ; set ; }
5858
59- string INestedFilter . Scope { get ; set ; }
59+ bool ? INestedFilter . Join { get ; set ; }
6060
6161 bool IFilter . IsConditionless
6262 {
@@ -73,6 +73,7 @@ public NestedFilterDescriptor<T> Filter(Func<FilterDescriptor<T>, FilterContaine
7373 ( ( INestedFilter ) this ) . Filter = filterSelector ( q ) ;
7474 return this ;
7575 }
76+
7677 public NestedFilterDescriptor < T > Query ( Func < QueryDescriptor < T > , QueryContainer > querySelector )
7778 {
7879 var q = new QueryDescriptor < T > ( ) ;
@@ -85,19 +86,22 @@ public NestedFilterDescriptor<T> Score(NestedScore score)
8586 ( ( INestedFilter ) this ) . Score = score ;
8687 return this ;
8788 }
89+
8890 public NestedFilterDescriptor < T > Path ( string path )
8991 {
9092 ( ( INestedFilter ) this ) . Path = path ;
9193 return this ;
9294 }
93- public NestedFilterDescriptor < T > Path ( Expression < Func < T , object > > objectPath )
95+
96+ public NestedFilterDescriptor < T > Join ( bool join = true )
9497 {
95- ( ( INestedFilter ) this ) . Path = objectPath ;
98+ ( ( INestedFilter ) this ) . Join = join ;
9699 return this ;
97100 }
98- public NestedFilterDescriptor < T > Scope ( string scope )
101+
102+ public NestedFilterDescriptor < T > Path ( Expression < Func < T , object > > objectPath )
99103 {
100- ( ( INestedFilter ) this ) . Scope = scope ;
104+ ( ( INestedFilter ) this ) . Path = objectPath ;
101105 return this ;
102106 }
103107 }
0 commit comments