Пример #1
0
            public bool IsMatch(CimInstance cimInstance)
            {
                bool flag;
                bool flag1 = this.IsMatchCore(cimInstance);

                ClientSideQuery.CimInstanceFilterBase cimInstanceFilterBase = this;
                if (this.HadMatches)
                {
                    flag = true;
                }
                else
                {
                    flag = flag1;
                }
                cimInstanceFilterBase.HadMatches = flag;
                return(flag1);
            }
Пример #2
0
 internal IEnumerable <ClientSideQuery.NotFoundError> GenerateNotFoundErrors()
 {
     if (this._filters.Count <= 1)
     {
         ClientSideQuery.CimInstanceFilterBase cimInstanceFilterBase = this._filters.SingleOrDefault <ClientSideQuery.CimInstanceFilterBase>();
         if (cimInstanceFilterBase == null)
         {
             return(Enumerable.Empty <ClientSideQuery.NotFoundError>());
         }
         else
         {
             return(cimInstanceFilterBase.GetNotFoundErrors_IfThisIsTheOnlyFilter());
         }
     }
     else
     {
         if (this._numberOfMatchingResults <= 0)
         {
             List <ClientSideQuery.CimInstanceFilterBase> cimInstanceFilterBases = this._filters;
             if (!cimInstanceFilterBases.All <ClientSideQuery.CimInstanceFilterBase>((ClientSideQuery.CimInstanceFilterBase f) => !f.ShouldReportErrorOnNoMatches_IfMultipleFilters()))
             {
                 ClientSideQuery.NotFoundError[] notFoundError = new ClientSideQuery.NotFoundError[1];
                 notFoundError[0] = new ClientSideQuery.NotFoundError();
                 return(notFoundError);
             }
             else
             {
                 return(Enumerable.Empty <ClientSideQuery.NotFoundError>());
             }
         }
         else
         {
             return(Enumerable.Empty <ClientSideQuery.NotFoundError>());
         }
     }
 }