code: public IFilterTerm buildFilter(IAssetType assetType, V1Instance instance) {
          FilterBuilder builder = new FilterBuilder(assetType, instance);
  
          internalModifyFilter(builder);
          internalModifyState(builder);
          return builder.root.hasTerm() ? builder.root : null;
      }
docs: Create representation one filter term on a query.
  
  @param assetType information about Asset type.
  @param instance The type this filter belongs to.
  @return created {@code IFilterTerm}.