@trudb/tru-common-lib 0.0.257 → 0.0.259

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -790,12 +790,6 @@ class TruQueryPredicateManager {
790
790
  this._propertyQueryPath = null;
791
791
  this._predicateName = '';
792
792
  this._predicateMap = {};
793
- this.setPredicate = (queryPredicate) => {
794
- if (this._predicate !== queryPredicate && this._predicateMap !== null) {
795
- this._predicate = queryPredicate;
796
- this._predicateMap[this._predicateName] = this._predicate === null ? null : this._predicate;
797
- }
798
- };
799
793
  /**
800
794
  * Returns a new query predicate.
801
795
  *
@@ -827,6 +821,7 @@ class TruQueryPredicateManager {
827
821
  * @param {string} operator - Name of the predicate operator.
828
822
  * @param {*} value - Literal value.
829
823
  */
824
+ //REMOVE AFTER TESTING!!!!
830
825
  this.set = (fieldOrPredicate, operator, value, overQuoted = false) => {
831
826
  var predicate;
832
827
  if (fieldOrPredicate.constructor === TruPredicate)
@@ -835,6 +830,16 @@ class TruQueryPredicateManager {
835
830
  predicate = this.create(fieldOrPredicate, operator, value, overQuoted);
836
831
  this.setPredicate(predicate);
837
832
  };
833
+ this.setPredicate = (queryPredicate) => {
834
+ if (this._predicate !== queryPredicate && this._predicateMap !== null) {
835
+ this._predicate = queryPredicate;
836
+ this._predicateMap[this._predicateName] = this._predicate === null ? null : this._predicate;
837
+ }
838
+ };
839
+ this.createPredicate = (fieldOrPredicate, operator, value, overQuoted = false) => {
840
+ let predicate = this.create(fieldOrPredicate, operator, value, overQuoted);
841
+ this.setPredicate(predicate);
842
+ };
838
843
  this._propertyQueryPath = propertyQueryPath;
839
844
  this._predicateName = predicateName;
840
845
  this._predicateMap = predicateMap;