File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -34,18 +34,21 @@ export class ListWatch<T extends KubernetesObject> implements ObjectCache<T>, In
3434 private readonly watch : Watch ;
3535 private readonly listFn : ListPromise < T > ;
3636 private readonly labelSelector ?: string ;
37+ private readonly fieldSelector ?: string ;
3738
3839 public constructor (
3940 path : string ,
4041 watch : Watch ,
4142 listFn : ListPromise < T > ,
4243 autoStart : boolean = true ,
4344 labelSelector ?: string ,
45+ fieldSelector ?: string ,
4446 ) {
4547 this . path = path ;
4648 this . watch = watch ;
4749 this . listFn = listFn ;
4850 this . labelSelector = labelSelector ;
51+ this . fieldSelector = fieldSelector ;
4952
5053 this . callbackCache [ ADD ] = [ ] ;
5154 this . callbackCache [ UPDATE ] = [ ] ;
@@ -172,10 +175,14 @@ export class ListWatch<T extends KubernetesObject> implements ObjectCache<T>, In
172175 } as {
173176 resourceVersion : string | undefined ;
174177 labelSelector : string | undefined ;
178+ fieldSelector : string | undefined ;
175179 } ;
176180 if ( this . labelSelector !== undefined ) {
177181 queryParams . labelSelector = ObjectSerializer . serialize ( this . labelSelector , 'string' ) ;
178182 }
183+ if ( this . fieldSelector !== undefined ) {
184+ queryParams . fieldSelector = ObjectSerializer . serialize ( this . fieldSelector , 'string' ) ;
185+ }
179186 this . request = await this . watch . watch (
180187 this . path ,
181188 queryParams ,
You can’t perform that action at this time.
0 commit comments