설명 없음

comparer.js 588B

12345678910111213141516171819202122232425
  1. export default {
  2. greater : (a, b) => a > b,
  3. smaller : (a, b) => a < b,
  4. instanceOf : (a, b) => a instanceof b,
  5. typeof : (a, b) => typeof a === b,
  6. IsNull : (a, b) => a === null,
  7. exists : (a, b) => a,
  8. hasValue : (a, b) => (a !== void 0) && (Array.isArray(a) ? a.length !==0 : true),
  9. isArray : (a, b) => Array.isArray(a),
  10. hasProperties : (a, b) => {
  11. let res = true
  12. for(let i in a) {
  13. let found = false
  14. for(let j in b) {
  15. if(b[j] === i) {
  16. found = true
  17. break;
  18. }
  19. }
  20. res = res && found
  21. }
  22. return res
  23. }
  24. }