@terascope/data-mate 0.57.0 → 1.0.0
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.
- package/README.md +1 -1
- package/dist/src/adapters/argument-validator/index.d.ts +1 -1
- package/dist/src/adapters/argument-validator/index.d.ts.map +1 -1
- package/dist/src/adapters/argument-validator/index.js +10 -15
- package/dist/src/adapters/argument-validator/index.js.map +1 -1
- package/dist/src/adapters/data-frame-adapter/index.d.ts +3 -3
- package/dist/src/adapters/data-frame-adapter/index.d.ts.map +1 -1
- package/dist/src/adapters/data-frame-adapter/index.js +39 -43
- package/dist/src/adapters/data-frame-adapter/index.js.map +1 -1
- package/dist/src/adapters/function-adapter/index.js +23 -25
- package/dist/src/adapters/function-adapter/index.js.map +1 -1
- package/dist/src/adapters/function-adapter/interfaces.d.ts +1 -1
- package/dist/src/adapters/function-adapter/interfaces.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/interfaces.js +1 -2
- package/dist/src/adapters/function-adapter/transformers/field/fieldColumn.d.ts +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/fieldColumn.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/fieldColumn.js +9 -13
- package/dist/src/adapters/function-adapter/transformers/field/fieldColumn.js.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/fieldRow.d.ts +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/fieldRow.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/fieldRow.js +20 -24
- package/dist/src/adapters/function-adapter/transformers/field/fieldRow.js.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/index.d.ts +4 -4
- package/dist/src/adapters/function-adapter/transformers/field/index.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/index.js +4 -20
- package/dist/src/adapters/function-adapter/transformers/field/index.js.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldColumn.d.ts +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldColumn.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldColumn.js +7 -11
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldColumn.js.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldRow.d.ts +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldRow.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldRow.js +15 -19
- package/dist/src/adapters/function-adapter/transformers/field/wholeFieldRow.js.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/index.d.ts +1 -1
- package/dist/src/adapters/function-adapter/transformers/index.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/index.js +1 -17
- package/dist/src/adapters/function-adapter/transformers/index.js.map +1 -1
- package/dist/src/adapters/function-adapter/transformers/rows.js +1 -5
- package/dist/src/adapters/function-adapter/transformers/rows.js.map +1 -1
- package/dist/src/adapters/function-adapter/utils.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/utils.js +5 -9
- package/dist/src/adapters/function-adapter/utils.js.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/fieldColumn.d.ts +1 -1
- package/dist/src/adapters/function-adapter/validators/field/fieldColumn.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/fieldColumn.js +9 -13
- package/dist/src/adapters/function-adapter/validators/field/fieldColumn.js.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/fieldRow.d.ts +1 -1
- package/dist/src/adapters/function-adapter/validators/field/fieldRow.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/fieldRow.js +17 -21
- package/dist/src/adapters/function-adapter/validators/field/fieldRow.js.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/index.d.ts +4 -4
- package/dist/src/adapters/function-adapter/validators/field/index.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/index.js +4 -20
- package/dist/src/adapters/function-adapter/validators/field/index.js.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldColumn.d.ts +1 -1
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldColumn.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldColumn.js +5 -9
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldColumn.js.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldRow.d.ts +1 -1
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldRow.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldRow.js +13 -17
- package/dist/src/adapters/function-adapter/validators/field/wholeFieldRow.js.map +1 -1
- package/dist/src/adapters/function-adapter/validators/index.d.ts +2 -2
- package/dist/src/adapters/function-adapter/validators/index.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/validators/index.js +2 -18
- package/dist/src/adapters/function-adapter/validators/index.js.map +1 -1
- package/dist/src/adapters/function-adapter/validators/rows.d.ts +1 -1
- package/dist/src/adapters/function-adapter/validators/rows.d.ts.map +1 -1
- package/dist/src/adapters/function-adapter/validators/rows.js +9 -13
- package/dist/src/adapters/function-adapter/validators/rows.js.map +1 -1
- package/dist/src/adapters/index.d.ts +3 -3
- package/dist/src/adapters/index.d.ts.map +1 -1
- package/dist/src/adapters/index.js +3 -19
- package/dist/src/adapters/index.js.map +1 -1
- package/dist/src/adapters/utils.d.ts +1 -1
- package/dist/src/adapters/utils.d.ts.map +1 -1
- package/dist/src/adapters/utils.js +3 -7
- package/dist/src/adapters/utils.js.map +1 -1
- package/dist/src/aggregation-frame/AggregationFrame.d.ts +2 -2
- package/dist/src/aggregation-frame/AggregationFrame.d.ts.map +1 -1
- package/dist/src/aggregation-frame/AggregationFrame.js +126 -99
- package/dist/src/aggregation-frame/AggregationFrame.js.map +1 -1
- package/dist/src/aggregation-frame/index.d.ts +1 -1
- package/dist/src/aggregation-frame/index.d.ts.map +1 -1
- package/dist/src/aggregation-frame/index.js +1 -17
- package/dist/src/aggregation-frame/index.js.map +1 -1
- package/dist/src/aggregation-frame/utils.d.ts +2 -2
- package/dist/src/aggregation-frame/utils.d.ts.map +1 -1
- package/dist/src/aggregation-frame/utils.js +29 -34
- package/dist/src/aggregation-frame/utils.js.map +1 -1
- package/dist/src/aggregations/field-aggregation.d.ts +1 -1
- package/dist/src/aggregations/field-aggregation.d.ts.map +1 -1
- package/dist/src/aggregations/field-aggregation.js +44 -76
- package/dist/src/aggregations/field-aggregation.js.map +1 -1
- package/dist/src/aggregations/index.d.ts +3 -3
- package/dist/src/aggregations/index.d.ts.map +1 -1
- package/dist/src/aggregations/index.js +4 -34
- package/dist/src/aggregations/index.js.map +1 -1
- package/dist/src/aggregations/interfaces.js +1 -2
- package/dist/src/aggregations/record-aggregation.d.ts +2 -2
- package/dist/src/aggregations/record-aggregation.d.ts.map +1 -1
- package/dist/src/aggregations/record-aggregation.js +50 -82
- package/dist/src/aggregations/record-aggregation.js.map +1 -1
- package/dist/src/builder/Builder.d.ts +2 -2
- package/dist/src/builder/Builder.d.ts.map +1 -1
- package/dist/src/builder/Builder.js +40 -22
- package/dist/src/builder/Builder.js.map +1 -1
- package/dist/src/builder/ListBuilder.d.ts +2 -2
- package/dist/src/builder/ListBuilder.d.ts.map +1 -1
- package/dist/src/builder/ListBuilder.js +6 -10
- package/dist/src/builder/ListBuilder.js.map +1 -1
- package/dist/src/builder/index.d.ts +4 -4
- package/dist/src/builder/index.d.ts.map +1 -1
- package/dist/src/builder/index.js +7 -23
- package/dist/src/builder/index.js.map +1 -1
- package/dist/src/builder/types/AnyBuilder.d.ts +2 -2
- package/dist/src/builder/types/AnyBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/AnyBuilder.js +6 -10
- package/dist/src/builder/types/AnyBuilder.js.map +1 -1
- package/dist/src/builder/types/BigIntBuilder.d.ts +2 -2
- package/dist/src/builder/types/BigIntBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/BigIntBuilder.js +6 -10
- package/dist/src/builder/types/BigIntBuilder.js.map +1 -1
- package/dist/src/builder/types/BooleanBuilder.d.ts +2 -2
- package/dist/src/builder/types/BooleanBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/BooleanBuilder.js +6 -10
- package/dist/src/builder/types/BooleanBuilder.js.map +1 -1
- package/dist/src/builder/types/DateBuilder.d.ts +2 -2
- package/dist/src/builder/types/DateBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/DateBuilder.js +6 -10
- package/dist/src/builder/types/DateBuilder.js.map +1 -1
- package/dist/src/builder/types/FloatBuilder.d.ts +2 -2
- package/dist/src/builder/types/FloatBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/FloatBuilder.js +6 -10
- package/dist/src/builder/types/FloatBuilder.js.map +1 -1
- package/dist/src/builder/types/GeoBoundaryBuilder.d.ts +2 -2
- package/dist/src/builder/types/GeoBoundaryBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/GeoBoundaryBuilder.js +6 -10
- package/dist/src/builder/types/GeoBoundaryBuilder.js.map +1 -1
- package/dist/src/builder/types/GeoJSONBuilder.d.ts +2 -2
- package/dist/src/builder/types/GeoJSONBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/GeoJSONBuilder.js +6 -10
- package/dist/src/builder/types/GeoJSONBuilder.js.map +1 -1
- package/dist/src/builder/types/GeoPointBuilder.d.ts +2 -2
- package/dist/src/builder/types/GeoPointBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/GeoPointBuilder.js +6 -10
- package/dist/src/builder/types/GeoPointBuilder.js.map +1 -1
- package/dist/src/builder/types/IPBuilder.d.ts +2 -2
- package/dist/src/builder/types/IPBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/IPBuilder.js +6 -10
- package/dist/src/builder/types/IPBuilder.js.map +1 -1
- package/dist/src/builder/types/IPRangeBuilder.d.ts +2 -2
- package/dist/src/builder/types/IPRangeBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/IPRangeBuilder.js +6 -10
- package/dist/src/builder/types/IPRangeBuilder.js.map +1 -1
- package/dist/src/builder/types/IntBuilder.d.ts +2 -2
- package/dist/src/builder/types/IntBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/IntBuilder.js +6 -10
- package/dist/src/builder/types/IntBuilder.js.map +1 -1
- package/dist/src/builder/types/ObjectBuilder.d.ts +2 -2
- package/dist/src/builder/types/ObjectBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/ObjectBuilder.js +6 -10
- package/dist/src/builder/types/ObjectBuilder.js.map +1 -1
- package/dist/src/builder/types/StringBuilder.d.ts +2 -2
- package/dist/src/builder/types/StringBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/StringBuilder.js +6 -10
- package/dist/src/builder/types/StringBuilder.js.map +1 -1
- package/dist/src/builder/types/TupleBuilder.d.ts +2 -2
- package/dist/src/builder/types/TupleBuilder.d.ts.map +1 -1
- package/dist/src/builder/types/TupleBuilder.js +8 -12
- package/dist/src/builder/types/TupleBuilder.js.map +1 -1
- package/dist/src/builder/types/index.d.ts +14 -14
- package/dist/src/builder/types/index.d.ts.map +1 -1
- package/dist/src/builder/types/index.js +14 -30
- package/dist/src/builder/types/index.js.map +1 -1
- package/dist/src/builder/utils.d.ts +2 -2
- package/dist/src/builder/utils.d.ts.map +1 -1
- package/dist/src/builder/utils.js +53 -58
- package/dist/src/builder/utils.js.map +1 -1
- package/dist/src/column/Column.d.ts +2 -2
- package/dist/src/column/Column.d.ts.map +1 -1
- package/dist/src/column/Column.js +37 -31
- package/dist/src/column/Column.js.map +1 -1
- package/dist/src/column/aggregations.d.ts +1 -1
- package/dist/src/column/aggregations.d.ts.map +1 -1
- package/dist/src/column/aggregations.js +25 -30
- package/dist/src/column/aggregations.js.map +1 -1
- package/dist/src/column/index.d.ts +4 -4
- package/dist/src/column/index.d.ts.map +1 -1
- package/dist/src/column/index.js +4 -20
- package/dist/src/column/index.js.map +1 -1
- package/dist/src/column/interfaces.d.ts.map +1 -1
- package/dist/src/column/interfaces.js +1 -2
- package/dist/src/column/utils.d.ts +2 -2
- package/dist/src/column/utils.d.ts.map +1 -1
- package/dist/src/column/utils.js +28 -39
- package/dist/src/column/utils.js.map +1 -1
- package/dist/src/core/ReadableData.d.ts +1 -1
- package/dist/src/core/ReadableData.d.ts.map +1 -1
- package/dist/src/core/ReadableData.js +14 -11
- package/dist/src/core/ReadableData.js.map +1 -1
- package/dist/src/core/WritableData.d.ts +1 -2
- package/dist/src/core/WritableData.d.ts.map +1 -1
- package/dist/src/core/WritableData.js +17 -16
- package/dist/src/core/WritableData.js.map +1 -1
- package/dist/src/core/config.js +21 -24
- package/dist/src/core/config.js.map +1 -1
- package/dist/src/core/index.d.ts +5 -5
- package/dist/src/core/index.d.ts.map +1 -1
- package/dist/src/core/index.js +5 -21
- package/dist/src/core/index.js.map +1 -1
- package/dist/src/core/interfaces.js +3 -6
- package/dist/src/core/interfaces.js.map +1 -1
- package/dist/src/core/utils.d.ts +1 -1
- package/dist/src/core/utils.d.ts.map +1 -1
- package/dist/src/core/utils.js +18 -28
- package/dist/src/core/utils.js.map +1 -1
- package/dist/src/data-frame/DataFrame.d.ts +5 -5
- package/dist/src/data-frame/DataFrame.d.ts.map +1 -1
- package/dist/src/data-frame/DataFrame.js +105 -98
- package/dist/src/data-frame/DataFrame.js.map +1 -1
- package/dist/src/data-frame/index.d.ts +2 -2
- package/dist/src/data-frame/index.d.ts.map +1 -1
- package/dist/src/data-frame/index.js +2 -18
- package/dist/src/data-frame/index.js.map +1 -1
- package/dist/src/data-frame/interfaces.js +1 -2
- package/dist/src/data-frame/metadata-utils.js +8 -13
- package/dist/src/data-frame/metadata-utils.js.map +1 -1
- package/dist/src/data-frame/search/buildMatcherForNode.d.ts +2 -2
- package/dist/src/data-frame/search/buildMatcherForNode.d.ts.map +1 -1
- package/dist/src/data-frame/search/buildMatcherForNode.js +33 -60
- package/dist/src/data-frame/search/buildMatcherForNode.js.map +1 -1
- package/dist/src/data-frame/search/buildSearchMatcherForQuery.d.ts +1 -1
- package/dist/src/data-frame/search/buildSearchMatcherForQuery.d.ts.map +1 -1
- package/dist/src/data-frame/search/buildSearchMatcherForQuery.js +6 -33
- package/dist/src/data-frame/search/buildSearchMatcherForQuery.js.map +1 -1
- package/dist/src/data-frame/search/date-utils.d.ts +1 -1
- package/dist/src/data-frame/search/date-utils.d.ts.map +1 -1
- package/dist/src/data-frame/search/date-utils.js +14 -25
- package/dist/src/data-frame/search/date-utils.js.map +1 -1
- package/dist/src/data-frame/search/index.d.ts +1 -1
- package/dist/src/data-frame/search/index.d.ts.map +1 -1
- package/dist/src/data-frame/search/index.js +1 -17
- package/dist/src/data-frame/search/index.js.map +1 -1
- package/dist/src/data-frame/search/interfaces.js +1 -2
- package/dist/src/data-frame/search/ip-utils.d.ts +1 -1
- package/dist/src/data-frame/search/ip-utils.d.ts.map +1 -1
- package/dist/src/data-frame/search/ip-utils.js +25 -33
- package/dist/src/data-frame/search/ip-utils.js.map +1 -1
- package/dist/src/data-frame/search/wildcards-and-regex-utils.d.ts +1 -1
- package/dist/src/data-frame/search/wildcards-and-regex-utils.d.ts.map +1 -1
- package/dist/src/data-frame/search/wildcards-and-regex-utils.js +15 -21
- package/dist/src/data-frame/search/wildcards-and-regex-utils.js.map +1 -1
- package/dist/src/data-frame/utils.d.ts +2 -2
- package/dist/src/data-frame/utils.d.ts.map +1 -1
- package/dist/src/data-frame/utils.js +20 -36
- package/dist/src/data-frame/utils.js.map +1 -1
- package/dist/src/document-matcher/index.d.ts +1 -1
- package/dist/src/document-matcher/index.d.ts.map +1 -1
- package/dist/src/document-matcher/index.js +6 -12
- package/dist/src/document-matcher/index.js.map +1 -1
- package/dist/src/document-matcher/interfaces.js +1 -2
- package/dist/src/document-matcher/logic-builder/dates.d.ts +1 -1
- package/dist/src/document-matcher/logic-builder/dates.d.ts.map +1 -1
- package/dist/src/document-matcher/logic-builder/dates.js +13 -24
- package/dist/src/document-matcher/logic-builder/dates.js.map +1 -1
- package/dist/src/document-matcher/logic-builder/index.d.ts +1 -1
- package/dist/src/document-matcher/logic-builder/index.d.ts.map +1 -1
- package/dist/src/document-matcher/logic-builder/index.js +26 -52
- package/dist/src/document-matcher/logic-builder/index.js.map +1 -1
- package/dist/src/document-matcher/logic-builder/ip.d.ts +1 -1
- package/dist/src/document-matcher/logic-builder/ip.d.ts.map +1 -1
- package/dist/src/document-matcher/logic-builder/ip.js +21 -29
- package/dist/src/document-matcher/logic-builder/ip.js.map +1 -1
- package/dist/src/document-matcher/logic-builder/string.d.ts +1 -1
- package/dist/src/document-matcher/logic-builder/string.d.ts.map +1 -1
- package/dist/src/document-matcher/logic-builder/string.js +8 -14
- package/dist/src/document-matcher/logic-builder/string.js.map +1 -1
- package/dist/src/function-configs/boolean/index.d.ts +3 -3
- package/dist/src/function-configs/boolean/index.js +7 -10
- package/dist/src/function-configs/boolean/index.js.map +1 -1
- package/dist/src/function-configs/boolean/isBoolean.d.ts +1 -1
- package/dist/src/function-configs/boolean/isBoolean.d.ts.map +1 -1
- package/dist/src/function-configs/boolean/isBoolean.js +13 -16
- package/dist/src/function-configs/boolean/isBoolean.js.map +1 -1
- package/dist/src/function-configs/boolean/isBooleanLike.d.ts +1 -1
- package/dist/src/function-configs/boolean/isBooleanLike.d.ts.map +1 -1
- package/dist/src/function-configs/boolean/isBooleanLike.js +13 -16
- package/dist/src/function-configs/boolean/isBooleanLike.js.map +1 -1
- package/dist/src/function-configs/boolean/toBoolean.d.ts +1 -1
- package/dist/src/function-configs/boolean/toBoolean.d.ts.map +1 -1
- package/dist/src/function-configs/boolean/toBoolean.js +13 -16
- package/dist/src/function-configs/boolean/toBoolean.js.map +1 -1
- package/dist/src/function-configs/date/addToDate.d.ts +1 -1
- package/dist/src/function-configs/date/addToDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/addToDate.js +32 -36
- package/dist/src/function-configs/date/addToDate.js.map +1 -1
- package/dist/src/function-configs/date/formatDate.d.ts +1 -1
- package/dist/src/function-configs/date/formatDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/formatDate.js +23 -26
- package/dist/src/function-configs/date/formatDate.js.map +1 -1
- package/dist/src/function-configs/date/getDate.d.ts +1 -1
- package/dist/src/function-configs/date/getDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/getDate.js +17 -20
- package/dist/src/function-configs/date/getDate.js.map +1 -1
- package/dist/src/function-configs/date/getHours.d.ts +1 -1
- package/dist/src/function-configs/date/getHours.d.ts.map +1 -1
- package/dist/src/function-configs/date/getHours.js +17 -20
- package/dist/src/function-configs/date/getHours.js.map +1 -1
- package/dist/src/function-configs/date/getMilliseconds.d.ts +1 -1
- package/dist/src/function-configs/date/getMilliseconds.d.ts.map +1 -1
- package/dist/src/function-configs/date/getMilliseconds.js +16 -19
- package/dist/src/function-configs/date/getMilliseconds.js.map +1 -1
- package/dist/src/function-configs/date/getMinutes.d.ts +1 -1
- package/dist/src/function-configs/date/getMinutes.d.ts.map +1 -1
- package/dist/src/function-configs/date/getMinutes.js +16 -19
- package/dist/src/function-configs/date/getMinutes.js.map +1 -1
- package/dist/src/function-configs/date/getMonth.d.ts +1 -1
- package/dist/src/function-configs/date/getMonth.d.ts.map +1 -1
- package/dist/src/function-configs/date/getMonth.js +17 -20
- package/dist/src/function-configs/date/getMonth.js.map +1 -1
- package/dist/src/function-configs/date/getSeconds.d.ts +1 -1
- package/dist/src/function-configs/date/getSeconds.d.ts.map +1 -1
- package/dist/src/function-configs/date/getSeconds.js +16 -19
- package/dist/src/function-configs/date/getSeconds.js.map +1 -1
- package/dist/src/function-configs/date/getTimeBetween.d.ts +1 -1
- package/dist/src/function-configs/date/getTimeBetween.d.ts.map +1 -1
- package/dist/src/function-configs/date/getTimeBetween.js +21 -24
- package/dist/src/function-configs/date/getTimeBetween.js.map +1 -1
- package/dist/src/function-configs/date/getTimezoneOffset.d.ts +1 -1
- package/dist/src/function-configs/date/getTimezoneOffset.d.ts.map +1 -1
- package/dist/src/function-configs/date/getTimezoneOffset.js +18 -21
- package/dist/src/function-configs/date/getTimezoneOffset.js.map +1 -1
- package/dist/src/function-configs/date/getUTCDate.d.ts +1 -1
- package/dist/src/function-configs/date/getUTCDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/getUTCDate.js +17 -20
- package/dist/src/function-configs/date/getUTCDate.js.map +1 -1
- package/dist/src/function-configs/date/getUTCHours.d.ts +1 -1
- package/dist/src/function-configs/date/getUTCHours.d.ts.map +1 -1
- package/dist/src/function-configs/date/getUTCHours.js +17 -20
- package/dist/src/function-configs/date/getUTCHours.js.map +1 -1
- package/dist/src/function-configs/date/getUTCMinutes.d.ts +1 -1
- package/dist/src/function-configs/date/getUTCMinutes.d.ts.map +1 -1
- package/dist/src/function-configs/date/getUTCMinutes.js +16 -19
- package/dist/src/function-configs/date/getUTCMinutes.js.map +1 -1
- package/dist/src/function-configs/date/getUTCMonth.d.ts +1 -1
- package/dist/src/function-configs/date/getUTCMonth.d.ts.map +1 -1
- package/dist/src/function-configs/date/getUTCMonth.js +17 -20
- package/dist/src/function-configs/date/getUTCMonth.js.map +1 -1
- package/dist/src/function-configs/date/getUTCYear.d.ts +1 -1
- package/dist/src/function-configs/date/getUTCYear.d.ts.map +1 -1
- package/dist/src/function-configs/date/getUTCYear.js +17 -20
- package/dist/src/function-configs/date/getUTCYear.js.map +1 -1
- package/dist/src/function-configs/date/getYear.d.ts +1 -1
- package/dist/src/function-configs/date/getYear.d.ts.map +1 -1
- package/dist/src/function-configs/date/getYear.js +17 -20
- package/dist/src/function-configs/date/getYear.js.map +1 -1
- package/dist/src/function-configs/date/index.d.ts +77 -77
- package/dist/src/function-configs/date/index.d.ts.map +1 -1
- package/dist/src/function-configs/date/index.js +113 -116
- package/dist/src/function-configs/date/index.js.map +1 -1
- package/dist/src/function-configs/date/isAfter.d.ts +1 -1
- package/dist/src/function-configs/date/isAfter.d.ts.map +1 -1
- package/dist/src/function-configs/date/isAfter.js +19 -22
- package/dist/src/function-configs/date/isAfter.js.map +1 -1
- package/dist/src/function-configs/date/isBefore.d.ts +1 -1
- package/dist/src/function-configs/date/isBefore.d.ts.map +1 -1
- package/dist/src/function-configs/date/isBefore.js +18 -21
- package/dist/src/function-configs/date/isBefore.js.map +1 -1
- package/dist/src/function-configs/date/isBetween.d.ts +1 -1
- package/dist/src/function-configs/date/isBetween.d.ts.map +1 -1
- package/dist/src/function-configs/date/isBetween.js +20 -23
- package/dist/src/function-configs/date/isBetween.js.map +1 -1
- package/dist/src/function-configs/date/isDate.d.ts +1 -1
- package/dist/src/function-configs/date/isDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/isDate.js +18 -24
- package/dist/src/function-configs/date/isDate.js.map +1 -1
- package/dist/src/function-configs/date/isEpoch.d.ts +1 -1
- package/dist/src/function-configs/date/isEpoch.d.ts.map +1 -1
- package/dist/src/function-configs/date/isEpoch.js +15 -18
- package/dist/src/function-configs/date/isEpoch.js.map +1 -1
- package/dist/src/function-configs/date/isEpochMillis.d.ts +1 -1
- package/dist/src/function-configs/date/isEpochMillis.d.ts.map +1 -1
- package/dist/src/function-configs/date/isEpochMillis.js +15 -18
- package/dist/src/function-configs/date/isEpochMillis.js.map +1 -1
- package/dist/src/function-configs/date/isFriday.d.ts +1 -1
- package/dist/src/function-configs/date/isFriday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isFriday.js +15 -18
- package/dist/src/function-configs/date/isFriday.js.map +1 -1
- package/dist/src/function-configs/date/isFuture.d.ts +1 -1
- package/dist/src/function-configs/date/isFuture.d.ts.map +1 -1
- package/dist/src/function-configs/date/isFuture.js +14 -17
- package/dist/src/function-configs/date/isFuture.js.map +1 -1
- package/dist/src/function-configs/date/isISO8601.d.ts +1 -1
- package/dist/src/function-configs/date/isISO8601.d.ts.map +1 -1
- package/dist/src/function-configs/date/isISO8601.js +15 -18
- package/dist/src/function-configs/date/isISO8601.js.map +1 -1
- package/dist/src/function-configs/date/isLeapYear.d.ts +1 -1
- package/dist/src/function-configs/date/isLeapYear.d.ts.map +1 -1
- package/dist/src/function-configs/date/isLeapYear.js +14 -17
- package/dist/src/function-configs/date/isLeapYear.js.map +1 -1
- package/dist/src/function-configs/date/isMonday.d.ts +1 -1
- package/dist/src/function-configs/date/isMonday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isMonday.js +14 -17
- package/dist/src/function-configs/date/isMonday.js.map +1 -1
- package/dist/src/function-configs/date/isPast.d.ts +1 -1
- package/dist/src/function-configs/date/isPast.d.ts.map +1 -1
- package/dist/src/function-configs/date/isPast.js +14 -17
- package/dist/src/function-configs/date/isPast.js.map +1 -1
- package/dist/src/function-configs/date/isSaturday.d.ts +1 -1
- package/dist/src/function-configs/date/isSaturday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isSaturday.js +14 -17
- package/dist/src/function-configs/date/isSaturday.js.map +1 -1
- package/dist/src/function-configs/date/isSunday.d.ts +1 -1
- package/dist/src/function-configs/date/isSunday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isSunday.js +14 -17
- package/dist/src/function-configs/date/isSunday.js.map +1 -1
- package/dist/src/function-configs/date/isThursday.d.ts +1 -1
- package/dist/src/function-configs/date/isThursday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isThursday.js +14 -17
- package/dist/src/function-configs/date/isThursday.js.map +1 -1
- package/dist/src/function-configs/date/isToday.d.ts +1 -1
- package/dist/src/function-configs/date/isToday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isToday.js +15 -18
- package/dist/src/function-configs/date/isToday.js.map +1 -1
- package/dist/src/function-configs/date/isTomorrow.d.ts +1 -1
- package/dist/src/function-configs/date/isTomorrow.d.ts.map +1 -1
- package/dist/src/function-configs/date/isTomorrow.js +15 -18
- package/dist/src/function-configs/date/isTomorrow.js.map +1 -1
- package/dist/src/function-configs/date/isTuesday.d.ts +1 -1
- package/dist/src/function-configs/date/isTuesday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isTuesday.js +14 -17
- package/dist/src/function-configs/date/isTuesday.js.map +1 -1
- package/dist/src/function-configs/date/isWednesday.d.ts +1 -1
- package/dist/src/function-configs/date/isWednesday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isWednesday.js +15 -18
- package/dist/src/function-configs/date/isWednesday.js.map +1 -1
- package/dist/src/function-configs/date/isWeekday.d.ts +1 -1
- package/dist/src/function-configs/date/isWeekday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isWeekday.js +16 -19
- package/dist/src/function-configs/date/isWeekday.js.map +1 -1
- package/dist/src/function-configs/date/isWeekend.d.ts +1 -1
- package/dist/src/function-configs/date/isWeekend.d.ts.map +1 -1
- package/dist/src/function-configs/date/isWeekend.js +16 -19
- package/dist/src/function-configs/date/isWeekend.js.map +1 -1
- package/dist/src/function-configs/date/isYesterday.d.ts +1 -1
- package/dist/src/function-configs/date/isYesterday.d.ts.map +1 -1
- package/dist/src/function-configs/date/isYesterday.js +16 -19
- package/dist/src/function-configs/date/isYesterday.js.map +1 -1
- package/dist/src/function-configs/date/lookupTimezone.d.ts +1 -1
- package/dist/src/function-configs/date/lookupTimezone.d.ts.map +1 -1
- package/dist/src/function-configs/date/lookupTimezone.js +25 -29
- package/dist/src/function-configs/date/lookupTimezone.js.map +1 -1
- package/dist/src/function-configs/date/setDate.d.ts +1 -1
- package/dist/src/function-configs/date/setDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/setDate.js +23 -26
- package/dist/src/function-configs/date/setDate.js.map +1 -1
- package/dist/src/function-configs/date/setHours.d.ts +1 -1
- package/dist/src/function-configs/date/setHours.d.ts.map +1 -1
- package/dist/src/function-configs/date/setHours.js +23 -26
- package/dist/src/function-configs/date/setHours.js.map +1 -1
- package/dist/src/function-configs/date/setMilliseconds.d.ts +1 -1
- package/dist/src/function-configs/date/setMilliseconds.d.ts.map +1 -1
- package/dist/src/function-configs/date/setMilliseconds.js +23 -26
- package/dist/src/function-configs/date/setMilliseconds.js.map +1 -1
- package/dist/src/function-configs/date/setMinutes.d.ts +1 -1
- package/dist/src/function-configs/date/setMinutes.d.ts.map +1 -1
- package/dist/src/function-configs/date/setMinutes.js +23 -26
- package/dist/src/function-configs/date/setMinutes.js.map +1 -1
- package/dist/src/function-configs/date/setMonth.d.ts +1 -1
- package/dist/src/function-configs/date/setMonth.d.ts.map +1 -1
- package/dist/src/function-configs/date/setMonth.js +23 -26
- package/dist/src/function-configs/date/setMonth.js.map +1 -1
- package/dist/src/function-configs/date/setSeconds.d.ts +1 -1
- package/dist/src/function-configs/date/setSeconds.d.ts.map +1 -1
- package/dist/src/function-configs/date/setSeconds.js +23 -26
- package/dist/src/function-configs/date/setSeconds.js.map +1 -1
- package/dist/src/function-configs/date/setTimezone.d.ts +1 -1
- package/dist/src/function-configs/date/setTimezone.d.ts.map +1 -1
- package/dist/src/function-configs/date/setTimezone.js +22 -25
- package/dist/src/function-configs/date/setTimezone.js.map +1 -1
- package/dist/src/function-configs/date/setYear.d.ts +1 -1
- package/dist/src/function-configs/date/setYear.d.ts.map +1 -1
- package/dist/src/function-configs/date/setYear.js +22 -25
- package/dist/src/function-configs/date/setYear.js.map +1 -1
- package/dist/src/function-configs/date/subtractFromDate.d.ts +1 -1
- package/dist/src/function-configs/date/subtractFromDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/subtractFromDate.js +30 -34
- package/dist/src/function-configs/date/subtractFromDate.js.map +1 -1
- package/dist/src/function-configs/date/timezoneToOffset.d.ts +1 -1
- package/dist/src/function-configs/date/timezoneToOffset.d.ts.map +1 -1
- package/dist/src/function-configs/date/timezoneToOffset.js +11 -14
- package/dist/src/function-configs/date/timezoneToOffset.js.map +1 -1
- package/dist/src/function-configs/date/toDailyDate.d.ts +1 -1
- package/dist/src/function-configs/date/toDailyDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/toDailyDate.js +18 -21
- package/dist/src/function-configs/date/toDailyDate.js.map +1 -1
- package/dist/src/function-configs/date/toDate.d.ts +1 -1
- package/dist/src/function-configs/date/toDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/toDate.js +29 -32
- package/dist/src/function-configs/date/toDate.js.map +1 -1
- package/dist/src/function-configs/date/toHourlyDate.d.ts +1 -1
- package/dist/src/function-configs/date/toHourlyDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/toHourlyDate.js +20 -23
- package/dist/src/function-configs/date/toHourlyDate.js.map +1 -1
- package/dist/src/function-configs/date/toMonthlyDate.d.ts +1 -1
- package/dist/src/function-configs/date/toMonthlyDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/toMonthlyDate.js +18 -21
- package/dist/src/function-configs/date/toMonthlyDate.js.map +1 -1
- package/dist/src/function-configs/date/toTimeZone.d.ts +1 -1
- package/dist/src/function-configs/date/toTimeZone.d.ts.map +1 -1
- package/dist/src/function-configs/date/toTimeZone.js +20 -23
- package/dist/src/function-configs/date/toTimeZone.js.map +1 -1
- package/dist/src/function-configs/date/toTimeZoneUsingLocation.d.ts +1 -1
- package/dist/src/function-configs/date/toTimeZoneUsingLocation.d.ts.map +1 -1
- package/dist/src/function-configs/date/toTimeZoneUsingLocation.js +20 -23
- package/dist/src/function-configs/date/toTimeZoneUsingLocation.js.map +1 -1
- package/dist/src/function-configs/date/toYearlyDate.d.ts +1 -1
- package/dist/src/function-configs/date/toYearlyDate.d.ts.map +1 -1
- package/dist/src/function-configs/date/toYearlyDate.js +18 -21
- package/dist/src/function-configs/date/toYearlyDate.js.map +1 -1
- package/dist/src/function-configs/date/utils.d.ts +1 -1
- package/dist/src/function-configs/date/utils.d.ts.map +1 -1
- package/dist/src/function-configs/date/utils.js +4 -9
- package/dist/src/function-configs/date/utils.js.map +1 -1
- package/dist/src/function-configs/geo/geoContains.d.ts +1 -1
- package/dist/src/function-configs/geo/geoContains.d.ts.map +1 -1
- package/dist/src/function-configs/geo/geoContains.js +29 -32
- package/dist/src/function-configs/geo/geoContains.js.map +1 -1
- package/dist/src/function-configs/geo/geoContainsPoint.d.ts +1 -1
- package/dist/src/function-configs/geo/geoContainsPoint.d.ts.map +1 -1
- package/dist/src/function-configs/geo/geoContainsPoint.js +25 -28
- package/dist/src/function-configs/geo/geoContainsPoint.js.map +1 -1
- package/dist/src/function-configs/geo/geoDisjoint.d.ts +1 -1
- package/dist/src/function-configs/geo/geoDisjoint.d.ts.map +1 -1
- package/dist/src/function-configs/geo/geoDisjoint.js +26 -29
- package/dist/src/function-configs/geo/geoDisjoint.js.map +1 -1
- package/dist/src/function-configs/geo/geoIntersects.d.ts +1 -1
- package/dist/src/function-configs/geo/geoIntersects.d.ts.map +1 -1
- package/dist/src/function-configs/geo/geoIntersects.js +26 -29
- package/dist/src/function-configs/geo/geoIntersects.js.map +1 -1
- package/dist/src/function-configs/geo/geoPointWithinRange.d.ts +1 -1
- package/dist/src/function-configs/geo/geoPointWithinRange.d.ts.map +1 -1
- package/dist/src/function-configs/geo/geoPointWithinRange.js +21 -24
- package/dist/src/function-configs/geo/geoPointWithinRange.js.map +1 -1
- package/dist/src/function-configs/geo/geoRelation.d.ts +1 -1
- package/dist/src/function-configs/geo/geoRelation.d.ts.map +1 -1
- package/dist/src/function-configs/geo/geoRelation.js +39 -42
- package/dist/src/function-configs/geo/geoRelation.js.map +1 -1
- package/dist/src/function-configs/geo/geoWithin.d.ts +1 -1
- package/dist/src/function-configs/geo/geoWithin.d.ts.map +1 -1
- package/dist/src/function-configs/geo/geoWithin.js +31 -34
- package/dist/src/function-configs/geo/geoWithin.js.map +1 -1
- package/dist/src/function-configs/geo/inGeoBoundingBox.d.ts +1 -1
- package/dist/src/function-configs/geo/inGeoBoundingBox.d.ts.map +1 -1
- package/dist/src/function-configs/geo/inGeoBoundingBox.js +21 -24
- package/dist/src/function-configs/geo/inGeoBoundingBox.js.map +1 -1
- package/dist/src/function-configs/geo/index.d.ts +23 -23
- package/dist/src/function-configs/geo/index.d.ts.map +1 -1
- package/dist/src/function-configs/geo/index.js +31 -34
- package/dist/src/function-configs/geo/index.js.map +1 -1
- package/dist/src/function-configs/geo/isGeoJSON.d.ts +1 -1
- package/dist/src/function-configs/geo/isGeoJSON.d.ts.map +1 -1
- package/dist/src/function-configs/geo/isGeoJSON.js +21 -24
- package/dist/src/function-configs/geo/isGeoJSON.js.map +1 -1
- package/dist/src/function-configs/geo/isGeoPoint.d.ts +1 -1
- package/dist/src/function-configs/geo/isGeoPoint.d.ts.map +1 -1
- package/dist/src/function-configs/geo/isGeoPoint.js +13 -16
- package/dist/src/function-configs/geo/isGeoPoint.js.map +1 -1
- package/dist/src/function-configs/geo/isGeoShapeMultiPolygon.d.ts +1 -1
- package/dist/src/function-configs/geo/isGeoShapeMultiPolygon.d.ts.map +1 -1
- package/dist/src/function-configs/geo/isGeoShapeMultiPolygon.js +13 -16
- package/dist/src/function-configs/geo/isGeoShapeMultiPolygon.js.map +1 -1
- package/dist/src/function-configs/geo/isGeoShapePoint.d.ts +1 -1
- package/dist/src/function-configs/geo/isGeoShapePoint.d.ts.map +1 -1
- package/dist/src/function-configs/geo/isGeoShapePoint.js +13 -16
- package/dist/src/function-configs/geo/isGeoShapePoint.js.map +1 -1
- package/dist/src/function-configs/geo/isGeoShapePolygon.d.ts +1 -1
- package/dist/src/function-configs/geo/isGeoShapePolygon.d.ts.map +1 -1
- package/dist/src/function-configs/geo/isGeoShapePolygon.js +13 -16
- package/dist/src/function-configs/geo/isGeoShapePolygon.js.map +1 -1
- package/dist/src/function-configs/geo/toGeoJSON.d.ts +1 -1
- package/dist/src/function-configs/geo/toGeoJSON.d.ts.map +1 -1
- package/dist/src/function-configs/geo/toGeoJSON.js +23 -26
- package/dist/src/function-configs/geo/toGeoJSON.js.map +1 -1
- package/dist/src/function-configs/geo/toGeoPoint.d.ts +1 -1
- package/dist/src/function-configs/geo/toGeoPoint.d.ts.map +1 -1
- package/dist/src/function-configs/geo/toGeoPoint.js +25 -29
- package/dist/src/function-configs/geo/toGeoPoint.js.map +1 -1
- package/dist/src/function-configs/index.d.ts +10 -10
- package/dist/src/function-configs/index.d.ts.map +1 -1
- package/dist/src/function-configs/index.js +10 -26
- package/dist/src/function-configs/index.js.map +1 -1
- package/dist/src/function-configs/interfaces.d.ts +1 -1
- package/dist/src/function-configs/interfaces.d.ts.map +1 -1
- package/dist/src/function-configs/interfaces.js +21 -31
- package/dist/src/function-configs/interfaces.js.map +1 -1
- package/dist/src/function-configs/ip/extractMappedIPv4.d.ts +1 -1
- package/dist/src/function-configs/ip/extractMappedIPv4.d.ts.map +1 -1
- package/dist/src/function-configs/ip/extractMappedIPv4.js +12 -15
- package/dist/src/function-configs/ip/extractMappedIPv4.js.map +1 -1
- package/dist/src/function-configs/ip/getCIDRBroadcast.d.ts +1 -1
- package/dist/src/function-configs/ip/getCIDRBroadcast.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getCIDRBroadcast.js +12 -15
- package/dist/src/function-configs/ip/getCIDRBroadcast.js.map +1 -1
- package/dist/src/function-configs/ip/getCIDRMax.d.ts +1 -1
- package/dist/src/function-configs/ip/getCIDRMax.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getCIDRMax.js +13 -16
- package/dist/src/function-configs/ip/getCIDRMax.js.map +1 -1
- package/dist/src/function-configs/ip/getCIDRMin.d.ts +1 -1
- package/dist/src/function-configs/ip/getCIDRMin.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getCIDRMin.js +13 -16
- package/dist/src/function-configs/ip/getCIDRMin.js.map +1 -1
- package/dist/src/function-configs/ip/getCIDRNetwork.d.ts +1 -1
- package/dist/src/function-configs/ip/getCIDRNetwork.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getCIDRNetwork.js +12 -15
- package/dist/src/function-configs/ip/getCIDRNetwork.js.map +1 -1
- package/dist/src/function-configs/ip/getFirstIpInCIDR.d.ts +1 -1
- package/dist/src/function-configs/ip/getFirstIpInCIDR.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getFirstIpInCIDR.js +13 -16
- package/dist/src/function-configs/ip/getFirstIpInCIDR.js.map +1 -1
- package/dist/src/function-configs/ip/getFirstUsableIPInCIDR.d.ts +1 -1
- package/dist/src/function-configs/ip/getFirstUsableIPInCIDR.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getFirstUsableIPInCIDR.js +13 -16
- package/dist/src/function-configs/ip/getFirstUsableIPInCIDR.js.map +1 -1
- package/dist/src/function-configs/ip/getLastIpInCIDR.d.ts +1 -1
- package/dist/src/function-configs/ip/getLastIpInCIDR.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getLastIpInCIDR.js +13 -16
- package/dist/src/function-configs/ip/getLastIpInCIDR.js.map +1 -1
- package/dist/src/function-configs/ip/getLastUsableIPInCIDR.d.ts +1 -1
- package/dist/src/function-configs/ip/getLastUsableIPInCIDR.d.ts.map +1 -1
- package/dist/src/function-configs/ip/getLastUsableIPInCIDR.js +13 -16
- package/dist/src/function-configs/ip/getLastUsableIPInCIDR.js.map +1 -1
- package/dist/src/function-configs/ip/inIPRange.d.ts +1 -1
- package/dist/src/function-configs/ip/inIPRange.d.ts.map +1 -1
- package/dist/src/function-configs/ip/inIPRange.js +19 -22
- package/dist/src/function-configs/ip/inIPRange.js.map +1 -1
- package/dist/src/function-configs/ip/index.d.ts +24 -24
- package/dist/src/function-configs/ip/index.d.ts.map +1 -1
- package/dist/src/function-configs/ip/index.js +43 -46
- package/dist/src/function-configs/ip/index.js.map +1 -1
- package/dist/src/function-configs/ip/intToIP.d.ts +1 -1
- package/dist/src/function-configs/ip/intToIP.d.ts.map +1 -1
- package/dist/src/function-configs/ip/intToIP.js +14 -17
- package/dist/src/function-configs/ip/intToIP.js.map +1 -1
- package/dist/src/function-configs/ip/ipToInt.d.ts +1 -1
- package/dist/src/function-configs/ip/ipToInt.d.ts.map +1 -1
- package/dist/src/function-configs/ip/ipToInt.js +12 -15
- package/dist/src/function-configs/ip/ipToInt.js.map +1 -1
- package/dist/src/function-configs/ip/isCIDR.d.ts +1 -1
- package/dist/src/function-configs/ip/isCIDR.d.ts.map +1 -1
- package/dist/src/function-configs/ip/isCIDR.js +13 -16
- package/dist/src/function-configs/ip/isCIDR.js.map +1 -1
- package/dist/src/function-configs/ip/isIP.d.ts +1 -1
- package/dist/src/function-configs/ip/isIP.d.ts.map +1 -1
- package/dist/src/function-configs/ip/isIP.js +14 -17
- package/dist/src/function-configs/ip/isIP.js.map +1 -1
- package/dist/src/function-configs/ip/isIPv4.d.ts +1 -1
- package/dist/src/function-configs/ip/isIPv4.d.ts.map +1 -1
- package/dist/src/function-configs/ip/isIPv4.js +13 -16
- package/dist/src/function-configs/ip/isIPv4.js.map +1 -1
- package/dist/src/function-configs/ip/isIPv6.d.ts +1 -1
- package/dist/src/function-configs/ip/isIPv6.d.ts.map +1 -1
- package/dist/src/function-configs/ip/isIPv6.js +14 -17
- package/dist/src/function-configs/ip/isIPv6.js.map +1 -1
- package/dist/src/function-configs/ip/isMappedIPv4.d.ts +1 -1
- package/dist/src/function-configs/ip/isMappedIPv4.d.ts.map +1 -1
- package/dist/src/function-configs/ip/isMappedIPv4.js +14 -17
- package/dist/src/function-configs/ip/isMappedIPv4.js.map +1 -1
- package/dist/src/function-configs/ip/isNonRoutableIP.d.ts +1 -1
- package/dist/src/function-configs/ip/isNonRoutableIP.d.ts.map +1 -1
- package/dist/src/function-configs/ip/isNonRoutableIP.js +14 -17
- package/dist/src/function-configs/ip/isNonRoutableIP.js.map +1 -1
- package/dist/src/function-configs/ip/isRoutableIP.d.ts +1 -1
- package/dist/src/function-configs/ip/isRoutableIP.d.ts.map +1 -1
- package/dist/src/function-configs/ip/isRoutableIP.js +14 -17
- package/dist/src/function-configs/ip/isRoutableIP.js.map +1 -1
- package/dist/src/function-configs/ip/reverseIP.d.ts +1 -1
- package/dist/src/function-configs/ip/reverseIP.d.ts.map +1 -1
- package/dist/src/function-configs/ip/reverseIP.js +12 -15
- package/dist/src/function-configs/ip/reverseIP.js.map +1 -1
- package/dist/src/function-configs/ip/toCIDR.d.ts +1 -1
- package/dist/src/function-configs/ip/toCIDR.d.ts.map +1 -1
- package/dist/src/function-configs/ip/toCIDR.js +15 -18
- package/dist/src/function-configs/ip/toCIDR.js.map +1 -1
- package/dist/src/function-configs/json/cast.d.ts +1 -1
- package/dist/src/function-configs/json/cast.d.ts.map +1 -1
- package/dist/src/function-configs/json/cast.js +27 -30
- package/dist/src/function-configs/json/cast.js.map +1 -1
- package/dist/src/function-configs/json/index.d.ts +6 -6
- package/dist/src/function-configs/json/index.d.ts.map +1 -1
- package/dist/src/function-configs/json/index.js +9 -12
- package/dist/src/function-configs/json/index.js.map +1 -1
- package/dist/src/function-configs/json/parseJSON.d.ts +1 -1
- package/dist/src/function-configs/json/parseJSON.d.ts.map +1 -1
- package/dist/src/function-configs/json/parseJSON.js +11 -14
- package/dist/src/function-configs/json/parseJSON.js.map +1 -1
- package/dist/src/function-configs/json/setDefault.d.ts +1 -1
- package/dist/src/function-configs/json/setDefault.d.ts.map +1 -1
- package/dist/src/function-configs/json/setDefault.js +13 -17
- package/dist/src/function-configs/json/setDefault.js.map +1 -1
- package/dist/src/function-configs/json/toJSON.d.ts +1 -1
- package/dist/src/function-configs/json/toJSON.d.ts.map +1 -1
- package/dist/src/function-configs/json/toJSON.js +17 -20
- package/dist/src/function-configs/json/toJSON.js.map +1 -1
- package/dist/src/function-configs/numeric/abs.d.ts +1 -1
- package/dist/src/function-configs/numeric/abs.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/abs.js +10 -13
- package/dist/src/function-configs/numeric/abs.js.map +1 -1
- package/dist/src/function-configs/numeric/acos.d.ts +1 -1
- package/dist/src/function-configs/numeric/acos.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/acos.js +11 -14
- package/dist/src/function-configs/numeric/acos.js.map +1 -1
- package/dist/src/function-configs/numeric/acosh.d.ts +1 -1
- package/dist/src/function-configs/numeric/acosh.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/acosh.js +12 -15
- package/dist/src/function-configs/numeric/acosh.js.map +1 -1
- package/dist/src/function-configs/numeric/add.d.ts +1 -1
- package/dist/src/function-configs/numeric/add.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/add.js +19 -22
- package/dist/src/function-configs/numeric/add.js.map +1 -1
- package/dist/src/function-configs/numeric/addValues.d.ts +1 -1
- package/dist/src/function-configs/numeric/addValues.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/addValues.js +24 -27
- package/dist/src/function-configs/numeric/addValues.js.map +1 -1
- package/dist/src/function-configs/numeric/asin.d.ts +1 -1
- package/dist/src/function-configs/numeric/asin.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/asin.js +10 -13
- package/dist/src/function-configs/numeric/asin.js.map +1 -1
- package/dist/src/function-configs/numeric/asinh.d.ts +1 -1
- package/dist/src/function-configs/numeric/asinh.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/asinh.js +11 -14
- package/dist/src/function-configs/numeric/asinh.js.map +1 -1
- package/dist/src/function-configs/numeric/atan.d.ts +1 -1
- package/dist/src/function-configs/numeric/atan.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/atan.js +11 -14
- package/dist/src/function-configs/numeric/atan.js.map +1 -1
- package/dist/src/function-configs/numeric/atan2.d.ts +1 -1
- package/dist/src/function-configs/numeric/atan2.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/atan2.js +15 -18
- package/dist/src/function-configs/numeric/atan2.js.map +1 -1
- package/dist/src/function-configs/numeric/atanh.d.ts +1 -1
- package/dist/src/function-configs/numeric/atanh.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/atanh.js +12 -15
- package/dist/src/function-configs/numeric/atanh.js.map +1 -1
- package/dist/src/function-configs/numeric/cbrt.d.ts +1 -1
- package/dist/src/function-configs/numeric/cbrt.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/cbrt.js +12 -15
- package/dist/src/function-configs/numeric/cbrt.js.map +1 -1
- package/dist/src/function-configs/numeric/ceil.d.ts +1 -1
- package/dist/src/function-configs/numeric/ceil.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/ceil.js +13 -16
- package/dist/src/function-configs/numeric/ceil.js.map +1 -1
- package/dist/src/function-configs/numeric/clz32.d.ts +1 -1
- package/dist/src/function-configs/numeric/clz32.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/clz32.js +13 -16
- package/dist/src/function-configs/numeric/clz32.js.map +1 -1
- package/dist/src/function-configs/numeric/cos.d.ts +1 -1
- package/dist/src/function-configs/numeric/cos.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/cos.js +13 -16
- package/dist/src/function-configs/numeric/cos.js.map +1 -1
- package/dist/src/function-configs/numeric/cosh.d.ts +1 -1
- package/dist/src/function-configs/numeric/cosh.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/cosh.js +12 -15
- package/dist/src/function-configs/numeric/cosh.js.map +1 -1
- package/dist/src/function-configs/numeric/divide.d.ts +1 -1
- package/dist/src/function-configs/numeric/divide.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/divide.js +18 -21
- package/dist/src/function-configs/numeric/divide.js.map +1 -1
- package/dist/src/function-configs/numeric/divideValues.d.ts +1 -1
- package/dist/src/function-configs/numeric/divideValues.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/divideValues.js +26 -29
- package/dist/src/function-configs/numeric/divideValues.js.map +1 -1
- package/dist/src/function-configs/numeric/exp.d.ts +1 -1
- package/dist/src/function-configs/numeric/exp.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/exp.js +12 -15
- package/dist/src/function-configs/numeric/exp.js.map +1 -1
- package/dist/src/function-configs/numeric/expm1.d.ts +1 -1
- package/dist/src/function-configs/numeric/expm1.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/expm1.js +12 -15
- package/dist/src/function-configs/numeric/expm1.js.map +1 -1
- package/dist/src/function-configs/numeric/floor.d.ts +1 -1
- package/dist/src/function-configs/numeric/floor.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/floor.js +13 -16
- package/dist/src/function-configs/numeric/floor.js.map +1 -1
- package/dist/src/function-configs/numeric/fround.d.ts +1 -1
- package/dist/src/function-configs/numeric/fround.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/fround.js +12 -15
- package/dist/src/function-configs/numeric/fround.js.map +1 -1
- package/dist/src/function-configs/numeric/hypot.d.ts +1 -1
- package/dist/src/function-configs/numeric/hypot.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/hypot.js +14 -17
- package/dist/src/function-configs/numeric/hypot.js.map +1 -1
- package/dist/src/function-configs/numeric/inNumberRange.d.ts +1 -1
- package/dist/src/function-configs/numeric/inNumberRange.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/inNumberRange.js +18 -21
- package/dist/src/function-configs/numeric/inNumberRange.js.map +1 -1
- package/dist/src/function-configs/numeric/index.d.ts +66 -66
- package/dist/src/function-configs/numeric/index.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/index.js +107 -110
- package/dist/src/function-configs/numeric/index.js.map +1 -1
- package/dist/src/function-configs/numeric/isEven.d.ts +1 -1
- package/dist/src/function-configs/numeric/isEven.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/isEven.js +9 -12
- package/dist/src/function-configs/numeric/isEven.js.map +1 -1
- package/dist/src/function-configs/numeric/isGreaterThan.d.ts +1 -1
- package/dist/src/function-configs/numeric/isGreaterThan.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/isGreaterThan.js +14 -17
- package/dist/src/function-configs/numeric/isGreaterThan.js.map +1 -1
- package/dist/src/function-configs/numeric/isGreaterThanOrEqualTo.d.ts +1 -1
- package/dist/src/function-configs/numeric/isGreaterThanOrEqualTo.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/isGreaterThanOrEqualTo.js +14 -17
- package/dist/src/function-configs/numeric/isGreaterThanOrEqualTo.js.map +1 -1
- package/dist/src/function-configs/numeric/isLessThan.d.ts +1 -1
- package/dist/src/function-configs/numeric/isLessThan.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/isLessThan.js +14 -17
- package/dist/src/function-configs/numeric/isLessThan.js.map +1 -1
- package/dist/src/function-configs/numeric/isLessThanOrEqualTo.d.ts +1 -1
- package/dist/src/function-configs/numeric/isLessThanOrEqualTo.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/isLessThanOrEqualTo.js +14 -17
- package/dist/src/function-configs/numeric/isLessThanOrEqualTo.js.map +1 -1
- package/dist/src/function-configs/numeric/isOdd.d.ts +1 -1
- package/dist/src/function-configs/numeric/isOdd.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/isOdd.js +9 -12
- package/dist/src/function-configs/numeric/isOdd.js.map +1 -1
- package/dist/src/function-configs/numeric/log.d.ts +1 -1
- package/dist/src/function-configs/numeric/log.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/log.js +13 -16
- package/dist/src/function-configs/numeric/log.js.map +1 -1
- package/dist/src/function-configs/numeric/log10.d.ts +1 -1
- package/dist/src/function-configs/numeric/log10.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/log10.js +13 -16
- package/dist/src/function-configs/numeric/log10.js.map +1 -1
- package/dist/src/function-configs/numeric/log1p.d.ts +1 -1
- package/dist/src/function-configs/numeric/log1p.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/log1p.js +14 -17
- package/dist/src/function-configs/numeric/log1p.js.map +1 -1
- package/dist/src/function-configs/numeric/log2.d.ts +1 -1
- package/dist/src/function-configs/numeric/log2.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/log2.js +13 -16
- package/dist/src/function-configs/numeric/log2.js.map +1 -1
- package/dist/src/function-configs/numeric/maxValues.d.ts +1 -1
- package/dist/src/function-configs/numeric/maxValues.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/maxValues.js +24 -27
- package/dist/src/function-configs/numeric/maxValues.js.map +1 -1
- package/dist/src/function-configs/numeric/minValues.d.ts +1 -1
- package/dist/src/function-configs/numeric/minValues.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/minValues.js +24 -27
- package/dist/src/function-configs/numeric/minValues.js.map +1 -1
- package/dist/src/function-configs/numeric/modulus.d.ts +1 -1
- package/dist/src/function-configs/numeric/modulus.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/modulus.js +19 -22
- package/dist/src/function-configs/numeric/modulus.js.map +1 -1
- package/dist/src/function-configs/numeric/multiply.d.ts +1 -1
- package/dist/src/function-configs/numeric/multiply.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/multiply.js +18 -21
- package/dist/src/function-configs/numeric/multiply.js.map +1 -1
- package/dist/src/function-configs/numeric/multiplyValues.d.ts +1 -1
- package/dist/src/function-configs/numeric/multiplyValues.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/multiplyValues.js +24 -27
- package/dist/src/function-configs/numeric/multiplyValues.js.map +1 -1
- package/dist/src/function-configs/numeric/pow.d.ts +1 -1
- package/dist/src/function-configs/numeric/pow.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/pow.js +13 -16
- package/dist/src/function-configs/numeric/pow.js.map +1 -1
- package/dist/src/function-configs/numeric/random.d.ts +1 -1
- package/dist/src/function-configs/numeric/random.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/random.js +12 -15
- package/dist/src/function-configs/numeric/random.js.map +1 -1
- package/dist/src/function-configs/numeric/round.d.ts +1 -1
- package/dist/src/function-configs/numeric/round.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/round.js +13 -16
- package/dist/src/function-configs/numeric/round.js.map +1 -1
- package/dist/src/function-configs/numeric/setPrecision.d.ts +1 -1
- package/dist/src/function-configs/numeric/setPrecision.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/setPrecision.js +29 -32
- package/dist/src/function-configs/numeric/setPrecision.js.map +1 -1
- package/dist/src/function-configs/numeric/sign.d.ts +1 -1
- package/dist/src/function-configs/numeric/sign.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/sign.js +13 -16
- package/dist/src/function-configs/numeric/sign.js.map +1 -1
- package/dist/src/function-configs/numeric/sin.d.ts +1 -1
- package/dist/src/function-configs/numeric/sin.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/sin.js +13 -16
- package/dist/src/function-configs/numeric/sin.js.map +1 -1
- package/dist/src/function-configs/numeric/sinh.d.ts +1 -1
- package/dist/src/function-configs/numeric/sinh.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/sinh.js +13 -16
- package/dist/src/function-configs/numeric/sinh.js.map +1 -1
- package/dist/src/function-configs/numeric/sqrt.d.ts +1 -1
- package/dist/src/function-configs/numeric/sqrt.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/sqrt.js +13 -16
- package/dist/src/function-configs/numeric/sqrt.js.map +1 -1
- package/dist/src/function-configs/numeric/subtract.d.ts +1 -1
- package/dist/src/function-configs/numeric/subtract.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/subtract.js +19 -22
- package/dist/src/function-configs/numeric/subtract.js.map +1 -1
- package/dist/src/function-configs/numeric/subtractValues.d.ts +1 -1
- package/dist/src/function-configs/numeric/subtractValues.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/subtractValues.js +24 -27
- package/dist/src/function-configs/numeric/subtractValues.js.map +1 -1
- package/dist/src/function-configs/numeric/tan.d.ts +1 -1
- package/dist/src/function-configs/numeric/tan.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/tan.js +11 -14
- package/dist/src/function-configs/numeric/tan.js.map +1 -1
- package/dist/src/function-configs/numeric/tanh.d.ts +1 -1
- package/dist/src/function-configs/numeric/tanh.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/tanh.js +12 -15
- package/dist/src/function-configs/numeric/tanh.js.map +1 -1
- package/dist/src/function-configs/numeric/toCelsius.d.ts +1 -1
- package/dist/src/function-configs/numeric/toCelsius.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/toCelsius.js +11 -14
- package/dist/src/function-configs/numeric/toCelsius.js.map +1 -1
- package/dist/src/function-configs/numeric/toFahrenheit.d.ts +1 -1
- package/dist/src/function-configs/numeric/toFahrenheit.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/toFahrenheit.js +11 -14
- package/dist/src/function-configs/numeric/toFahrenheit.js.map +1 -1
- package/dist/src/function-configs/numeric/toNumber.d.ts +1 -1
- package/dist/src/function-configs/numeric/toNumber.d.ts.map +1 -1
- package/dist/src/function-configs/numeric/toNumber.js +25 -28
- package/dist/src/function-configs/numeric/toNumber.js.map +1 -1
- package/dist/src/function-configs/numeric/utils.js +3 -7
- package/dist/src/function-configs/numeric/utils.js.map +1 -1
- package/dist/src/function-configs/object/equals.d.ts +1 -1
- package/dist/src/function-configs/object/equals.d.ts.map +1 -1
- package/dist/src/function-configs/object/equals.js +15 -18
- package/dist/src/function-configs/object/equals.js.map +1 -1
- package/dist/src/function-configs/object/index.d.ts +6 -6
- package/dist/src/function-configs/object/index.d.ts.map +1 -1
- package/dist/src/function-configs/object/index.js +7 -10
- package/dist/src/function-configs/object/index.js.map +1 -1
- package/dist/src/function-configs/object/isEmpty.d.ts +1 -1
- package/dist/src/function-configs/object/isEmpty.d.ts.map +1 -1
- package/dist/src/function-configs/object/isEmpty.js +13 -16
- package/dist/src/function-configs/object/isEmpty.js.map +1 -1
- package/dist/src/function-configs/object/lookup.d.ts +1 -1
- package/dist/src/function-configs/object/lookup.d.ts.map +1 -1
- package/dist/src/function-configs/object/lookup.js +17 -20
- package/dist/src/function-configs/object/lookup.js.map +1 -1
- package/dist/src/function-configs/repository.d.ts +205 -205
- package/dist/src/function-configs/repository.js +17 -20
- package/dist/src/function-configs/repository.js.map +1 -1
- package/dist/src/function-configs/string/contains.d.ts +1 -1
- package/dist/src/function-configs/string/contains.d.ts.map +1 -1
- package/dist/src/function-configs/string/contains.js +13 -16
- package/dist/src/function-configs/string/contains.js.map +1 -1
- package/dist/src/function-configs/string/createID.d.ts +2 -2
- package/dist/src/function-configs/string/createID.d.ts.map +1 -1
- package/dist/src/function-configs/string/createID.js +21 -24
- package/dist/src/function-configs/string/createID.js.map +1 -1
- package/dist/src/function-configs/string/decodeBase64.d.ts +1 -1
- package/dist/src/function-configs/string/decodeBase64.d.ts.map +1 -1
- package/dist/src/function-configs/string/decodeBase64.js +9 -12
- package/dist/src/function-configs/string/decodeBase64.js.map +1 -1
- package/dist/src/function-configs/string/decodeHex.d.ts +1 -1
- package/dist/src/function-configs/string/decodeHex.d.ts.map +1 -1
- package/dist/src/function-configs/string/decodeHex.js +9 -12
- package/dist/src/function-configs/string/decodeHex.js.map +1 -1
- package/dist/src/function-configs/string/decodeURL.d.ts +1 -1
- package/dist/src/function-configs/string/decodeURL.d.ts.map +1 -1
- package/dist/src/function-configs/string/decodeURL.js +9 -12
- package/dist/src/function-configs/string/decodeURL.js.map +1 -1
- package/dist/src/function-configs/string/encode-utils.d.ts +1 -1
- package/dist/src/function-configs/string/encode-utils.d.ts.map +1 -1
- package/dist/src/function-configs/string/encode-utils.js +10 -17
- package/dist/src/function-configs/string/encode-utils.js.map +1 -1
- package/dist/src/function-configs/string/encode.d.ts +2 -2
- package/dist/src/function-configs/string/encode.d.ts.map +1 -1
- package/dist/src/function-configs/string/encode.js +17 -20
- package/dist/src/function-configs/string/encode.js.map +1 -1
- package/dist/src/function-configs/string/encodeBase64.d.ts +1 -1
- package/dist/src/function-configs/string/encodeBase64.d.ts.map +1 -1
- package/dist/src/function-configs/string/encodeBase64.js +11 -14
- package/dist/src/function-configs/string/encodeBase64.js.map +1 -1
- package/dist/src/function-configs/string/encodeHex.d.ts +1 -1
- package/dist/src/function-configs/string/encodeHex.d.ts.map +1 -1
- package/dist/src/function-configs/string/encodeHex.js +11 -14
- package/dist/src/function-configs/string/encodeHex.js.map +1 -1
- package/dist/src/function-configs/string/encodeSHA.d.ts +2 -2
- package/dist/src/function-configs/string/encodeSHA.d.ts.map +1 -1
- package/dist/src/function-configs/string/encodeSHA.js +14 -17
- package/dist/src/function-configs/string/encodeSHA.js.map +1 -1
- package/dist/src/function-configs/string/encodeSHA1.d.ts +2 -2
- package/dist/src/function-configs/string/encodeSHA1.d.ts.map +1 -1
- package/dist/src/function-configs/string/encodeSHA1.js +13 -16
- package/dist/src/function-configs/string/encodeSHA1.js.map +1 -1
- package/dist/src/function-configs/string/encodeURL.d.ts +1 -1
- package/dist/src/function-configs/string/encodeURL.d.ts.map +1 -1
- package/dist/src/function-configs/string/encodeURL.js +11 -14
- package/dist/src/function-configs/string/encodeURL.js.map +1 -1
- package/dist/src/function-configs/string/endsWith.d.ts +1 -1
- package/dist/src/function-configs/string/endsWith.d.ts.map +1 -1
- package/dist/src/function-configs/string/endsWith.js +14 -17
- package/dist/src/function-configs/string/endsWith.js.map +1 -1
- package/dist/src/function-configs/string/entropy.d.ts +1 -1
- package/dist/src/function-configs/string/entropy.d.ts.map +1 -1
- package/dist/src/function-configs/string/entropy.js +17 -20
- package/dist/src/function-configs/string/entropy.js.map +1 -1
- package/dist/src/function-configs/string/extract.d.ts +1 -1
- package/dist/src/function-configs/string/extract.d.ts.map +1 -1
- package/dist/src/function-configs/string/extract.js +16 -19
- package/dist/src/function-configs/string/extract.js.map +1 -1
- package/dist/src/function-configs/string/index.d.ts +74 -74
- package/dist/src/function-configs/string/index.d.ts.map +1 -1
- package/dist/src/function-configs/string/index.js +101 -104
- package/dist/src/function-configs/string/index.js.map +1 -1
- package/dist/src/function-configs/string/isAlpha.d.ts +1 -1
- package/dist/src/function-configs/string/isAlpha.d.ts.map +1 -1
- package/dist/src/function-configs/string/isAlpha.js +18 -24
- package/dist/src/function-configs/string/isAlpha.js.map +1 -1
- package/dist/src/function-configs/string/isAlphaNumeric.d.ts +1 -1
- package/dist/src/function-configs/string/isAlphaNumeric.d.ts.map +1 -1
- package/dist/src/function-configs/string/isAlphaNumeric.js +18 -24
- package/dist/src/function-configs/string/isAlphaNumeric.js.map +1 -1
- package/dist/src/function-configs/string/isBase64.d.ts +1 -1
- package/dist/src/function-configs/string/isBase64.d.ts.map +1 -1
- package/dist/src/function-configs/string/isBase64.js +12 -15
- package/dist/src/function-configs/string/isBase64.js.map +1 -1
- package/dist/src/function-configs/string/isCountryCode.d.ts +1 -1
- package/dist/src/function-configs/string/isCountryCode.d.ts.map +1 -1
- package/dist/src/function-configs/string/isCountryCode.js +14 -17
- package/dist/src/function-configs/string/isCountryCode.js.map +1 -1
- package/dist/src/function-configs/string/isEmail.d.ts +1 -1
- package/dist/src/function-configs/string/isEmail.d.ts.map +1 -1
- package/dist/src/function-configs/string/isEmail.js +18 -21
- package/dist/src/function-configs/string/isEmail.js.map +1 -1
- package/dist/src/function-configs/string/isFQDN.d.ts +1 -1
- package/dist/src/function-configs/string/isFQDN.d.ts.map +1 -1
- package/dist/src/function-configs/string/isFQDN.js +16 -19
- package/dist/src/function-configs/string/isFQDN.js.map +1 -1
- package/dist/src/function-configs/string/isHash.d.ts +1 -1
- package/dist/src/function-configs/string/isHash.d.ts.map +1 -1
- package/dist/src/function-configs/string/isHash.js +14 -20
- package/dist/src/function-configs/string/isHash.js.map +1 -1
- package/dist/src/function-configs/string/isISDN.d.ts +1 -1
- package/dist/src/function-configs/string/isISDN.d.ts.map +1 -1
- package/dist/src/function-configs/string/isISDN.js +16 -19
- package/dist/src/function-configs/string/isISDN.js.map +1 -1
- package/dist/src/function-configs/string/isLength.d.ts +1 -1
- package/dist/src/function-configs/string/isLength.d.ts.map +1 -1
- package/dist/src/function-configs/string/isLength.js +20 -26
- package/dist/src/function-configs/string/isLength.js.map +1 -1
- package/dist/src/function-configs/string/isMACAddress.d.ts +1 -1
- package/dist/src/function-configs/string/isMACAddress.d.ts.map +1 -1
- package/dist/src/function-configs/string/isMACAddress.js +23 -26
- package/dist/src/function-configs/string/isMACAddress.js.map +1 -1
- package/dist/src/function-configs/string/isMIMEType.d.ts +1 -1
- package/dist/src/function-configs/string/isMIMEType.d.ts.map +1 -1
- package/dist/src/function-configs/string/isMIMEType.js +13 -16
- package/dist/src/function-configs/string/isMIMEType.js.map +1 -1
- package/dist/src/function-configs/string/isPhoneNumberLike.d.ts +1 -1
- package/dist/src/function-configs/string/isPhoneNumberLike.d.ts.map +1 -1
- package/dist/src/function-configs/string/isPhoneNumberLike.js +15 -18
- package/dist/src/function-configs/string/isPhoneNumberLike.js.map +1 -1
- package/dist/src/function-configs/string/isPort.d.ts +1 -1
- package/dist/src/function-configs/string/isPort.d.ts.map +1 -1
- package/dist/src/function-configs/string/isPort.js +14 -17
- package/dist/src/function-configs/string/isPort.js.map +1 -1
- package/dist/src/function-configs/string/isPostalCode.d.ts +1 -1
- package/dist/src/function-configs/string/isPostalCode.d.ts.map +1 -1
- package/dist/src/function-configs/string/isPostalCode.js +19 -25
- package/dist/src/function-configs/string/isPostalCode.js.map +1 -1
- package/dist/src/function-configs/string/isString.d.ts +1 -1
- package/dist/src/function-configs/string/isString.d.ts.map +1 -1
- package/dist/src/function-configs/string/isString.js +14 -17
- package/dist/src/function-configs/string/isString.js.map +1 -1
- package/dist/src/function-configs/string/isURL.d.ts +1 -1
- package/dist/src/function-configs/string/isURL.d.ts.map +1 -1
- package/dist/src/function-configs/string/isURL.js +17 -20
- package/dist/src/function-configs/string/isURL.js.map +1 -1
- package/dist/src/function-configs/string/isUUID.d.ts +1 -1
- package/dist/src/function-configs/string/isUUID.d.ts.map +1 -1
- package/dist/src/function-configs/string/isUUID.js +14 -17
- package/dist/src/function-configs/string/isUUID.js.map +1 -1
- package/dist/src/function-configs/string/join.d.ts +1 -1
- package/dist/src/function-configs/string/join.d.ts.map +1 -1
- package/dist/src/function-configs/string/join.js +19 -22
- package/dist/src/function-configs/string/join.js.map +1 -1
- package/dist/src/function-configs/string/replaceLiteral.d.ts +1 -1
- package/dist/src/function-configs/string/replaceLiteral.d.ts.map +1 -1
- package/dist/src/function-configs/string/replaceLiteral.js +11 -14
- package/dist/src/function-configs/string/replaceLiteral.js.map +1 -1
- package/dist/src/function-configs/string/replaceRegex.d.ts +1 -1
- package/dist/src/function-configs/string/replaceRegex.d.ts.map +1 -1
- package/dist/src/function-configs/string/replaceRegex.js +18 -21
- package/dist/src/function-configs/string/replaceRegex.js.map +1 -1
- package/dist/src/function-configs/string/reverse.d.ts +1 -1
- package/dist/src/function-configs/string/reverse.d.ts.map +1 -1
- package/dist/src/function-configs/string/reverse.js +13 -16
- package/dist/src/function-configs/string/reverse.js.map +1 -1
- package/dist/src/function-configs/string/split.d.ts +1 -1
- package/dist/src/function-configs/string/split.d.ts.map +1 -1
- package/dist/src/function-configs/string/split.js +12 -15
- package/dist/src/function-configs/string/split.js.map +1 -1
- package/dist/src/function-configs/string/startsWith.d.ts +1 -1
- package/dist/src/function-configs/string/startsWith.d.ts.map +1 -1
- package/dist/src/function-configs/string/startsWith.js +15 -18
- package/dist/src/function-configs/string/startsWith.js.map +1 -1
- package/dist/src/function-configs/string/toCamelCase.d.ts +1 -1
- package/dist/src/function-configs/string/toCamelCase.d.ts.map +1 -1
- package/dist/src/function-configs/string/toCamelCase.js +12 -15
- package/dist/src/function-configs/string/toCamelCase.js.map +1 -1
- package/dist/src/function-configs/string/toISDN.d.ts +1 -1
- package/dist/src/function-configs/string/toISDN.d.ts.map +1 -1
- package/dist/src/function-configs/string/toISDN.js +16 -19
- package/dist/src/function-configs/string/toISDN.js.map +1 -1
- package/dist/src/function-configs/string/toKebabCase.d.ts +1 -1
- package/dist/src/function-configs/string/toKebabCase.d.ts.map +1 -1
- package/dist/src/function-configs/string/toKebabCase.js +12 -15
- package/dist/src/function-configs/string/toKebabCase.js.map +1 -1
- package/dist/src/function-configs/string/toLowerCase.d.ts +1 -1
- package/dist/src/function-configs/string/toLowerCase.d.ts.map +1 -1
- package/dist/src/function-configs/string/toLowerCase.js +9 -12
- package/dist/src/function-configs/string/toLowerCase.js.map +1 -1
- package/dist/src/function-configs/string/toPascalCase.d.ts +1 -1
- package/dist/src/function-configs/string/toPascalCase.d.ts.map +1 -1
- package/dist/src/function-configs/string/toPascalCase.js +12 -15
- package/dist/src/function-configs/string/toPascalCase.js.map +1 -1
- package/dist/src/function-configs/string/toSnakeCase.d.ts +1 -1
- package/dist/src/function-configs/string/toSnakeCase.d.ts.map +1 -1
- package/dist/src/function-configs/string/toSnakeCase.js +12 -15
- package/dist/src/function-configs/string/toSnakeCase.js.map +1 -1
- package/dist/src/function-configs/string/toString.d.ts +1 -1
- package/dist/src/function-configs/string/toString.d.ts.map +1 -1
- package/dist/src/function-configs/string/toString.js +15 -18
- package/dist/src/function-configs/string/toString.js.map +1 -1
- package/dist/src/function-configs/string/toTitleCase.d.ts +1 -1
- package/dist/src/function-configs/string/toTitleCase.d.ts.map +1 -1
- package/dist/src/function-configs/string/toTitleCase.js +12 -15
- package/dist/src/function-configs/string/toTitleCase.js.map +1 -1
- package/dist/src/function-configs/string/toUpperCase.d.ts +1 -1
- package/dist/src/function-configs/string/toUpperCase.d.ts.map +1 -1
- package/dist/src/function-configs/string/toUpperCase.js +10 -13
- package/dist/src/function-configs/string/toUpperCase.js.map +1 -1
- package/dist/src/function-configs/string/trim.d.ts +1 -1
- package/dist/src/function-configs/string/trim.d.ts.map +1 -1
- package/dist/src/function-configs/string/trim.js +21 -24
- package/dist/src/function-configs/string/trim.js.map +1 -1
- package/dist/src/function-configs/string/trimEnd.d.ts +1 -1
- package/dist/src/function-configs/string/trimEnd.d.ts.map +1 -1
- package/dist/src/function-configs/string/trimEnd.js +15 -18
- package/dist/src/function-configs/string/trimEnd.js.map +1 -1
- package/dist/src/function-configs/string/trimStart.d.ts +1 -1
- package/dist/src/function-configs/string/trimStart.d.ts.map +1 -1
- package/dist/src/function-configs/string/trimStart.js +14 -17
- package/dist/src/function-configs/string/trimStart.js.map +1 -1
- package/dist/src/function-configs/string/truncate.d.ts +1 -1
- package/dist/src/function-configs/string/truncate.d.ts.map +1 -1
- package/dist/src/function-configs/string/truncate.js +12 -15
- package/dist/src/function-configs/string/truncate.js.map +1 -1
- package/dist/src/index.d.ts +19 -17
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +33 -49
- package/dist/src/index.js.map +1 -1
- package/dist/src/interfaces.d.ts +1 -2
- package/dist/src/interfaces.d.ts.map +1 -1
- package/dist/src/interfaces.js +2 -5
- package/dist/src/interfaces.js.map +1 -1
- package/dist/src/jexl/index.d.ts +3 -4
- package/dist/src/jexl/index.d.ts.map +1 -1
- package/dist/src/jexl/index.js +49 -85
- package/dist/src/jexl/index.js.map +1 -1
- package/dist/src/record-transforms/dedup.js +2 -3
- package/dist/src/record-transforms/dedup.js.map +1 -1
- package/dist/src/record-validators/required.js +2 -3
- package/dist/src/record-validators/required.js.map +1 -1
- package/dist/src/transforms/field-transform.d.ts +2 -2
- package/dist/src/transforms/field-transform.d.ts.map +1 -1
- package/dist/src/transforms/field-transform.js +224 -291
- package/dist/src/transforms/field-transform.js.map +1 -1
- package/dist/src/transforms/helpers.js +15 -19
- package/dist/src/transforms/helpers.js.map +1 -1
- package/dist/src/transforms/index.d.ts +2 -2
- package/dist/src/transforms/index.d.ts.map +1 -1
- package/dist/src/transforms/index.js +4 -30
- package/dist/src/transforms/index.js.map +1 -1
- package/dist/src/transforms/interfaces.js +1 -2
- package/dist/src/transforms/record-transform.d.ts +1 -1
- package/dist/src/transforms/record-transform.d.ts.map +1 -1
- package/dist/src/transforms/record-transform.js +37 -69
- package/dist/src/transforms/record-transform.js.map +1 -1
- package/dist/src/validations/field-validator.d.ts +7 -5
- package/dist/src/validations/field-validator.d.ts.map +1 -1
- package/dist/src/validations/field-validator.js +153 -221
- package/dist/src/validations/field-validator.js.map +1 -1
- package/dist/src/validations/index.d.ts +2 -2
- package/dist/src/validations/index.d.ts.map +1 -1
- package/dist/src/validations/index.js +4 -30
- package/dist/src/validations/index.js.map +1 -1
- package/dist/src/validations/interfaces.js +1 -2
- package/dist/src/validations/record-validator.d.ts +1 -1
- package/dist/src/validations/record-validator.d.ts.map +1 -1
- package/dist/src/validations/record-validator.js +26 -55
- package/dist/src/validations/record-validator.js.map +1 -1
- package/dist/src/vector/ListVector.d.ts +2 -2
- package/dist/src/vector/ListVector.d.ts.map +1 -1
- package/dist/src/vector/ListVector.js +28 -44
- package/dist/src/vector/ListVector.js.map +1 -1
- package/dist/src/vector/Vector.d.ts +2 -2
- package/dist/src/vector/Vector.d.ts.map +1 -1
- package/dist/src/vector/Vector.js +58 -27
- package/dist/src/vector/Vector.js.map +1 -1
- package/dist/src/vector/index.d.ts +5 -5
- package/dist/src/vector/index.d.ts.map +1 -1
- package/dist/src/vector/index.js +8 -24
- package/dist/src/vector/index.js.map +1 -1
- package/dist/src/vector/interfaces.d.ts +1 -1
- package/dist/src/vector/interfaces.d.ts.map +1 -1
- package/dist/src/vector/interfaces.js +2 -5
- package/dist/src/vector/interfaces.js.map +1 -1
- package/dist/src/vector/types/AnyVector.d.ts +2 -2
- package/dist/src/vector/types/AnyVector.d.ts.map +1 -1
- package/dist/src/vector/types/AnyVector.js +9 -13
- package/dist/src/vector/types/AnyVector.js.map +1 -1
- package/dist/src/vector/types/BigIntVector.d.ts +2 -2
- package/dist/src/vector/types/BigIntVector.d.ts.map +1 -1
- package/dist/src/vector/types/BigIntVector.js +7 -11
- package/dist/src/vector/types/BigIntVector.js.map +1 -1
- package/dist/src/vector/types/BooleanVector.d.ts +2 -2
- package/dist/src/vector/types/BooleanVector.d.ts.map +1 -1
- package/dist/src/vector/types/BooleanVector.js +6 -10
- package/dist/src/vector/types/BooleanVector.js.map +1 -1
- package/dist/src/vector/types/DateVector.d.ts +2 -2
- package/dist/src/vector/types/DateVector.d.ts.map +1 -1
- package/dist/src/vector/types/DateVector.js +8 -12
- package/dist/src/vector/types/DateVector.js.map +1 -1
- package/dist/src/vector/types/FloatVector.d.ts +2 -2
- package/dist/src/vector/types/FloatVector.d.ts.map +1 -1
- package/dist/src/vector/types/FloatVector.js +6 -10
- package/dist/src/vector/types/FloatVector.js.map +1 -1
- package/dist/src/vector/types/GeoBoundaryVector.d.ts +2 -2
- package/dist/src/vector/types/GeoBoundaryVector.d.ts.map +1 -1
- package/dist/src/vector/types/GeoBoundaryVector.js +6 -10
- package/dist/src/vector/types/GeoBoundaryVector.js.map +1 -1
- package/dist/src/vector/types/GeoJSONVector.d.ts +2 -2
- package/dist/src/vector/types/GeoJSONVector.d.ts.map +1 -1
- package/dist/src/vector/types/GeoJSONVector.js +6 -10
- package/dist/src/vector/types/GeoJSONVector.js.map +1 -1
- package/dist/src/vector/types/GeoPointVector.d.ts +2 -2
- package/dist/src/vector/types/GeoPointVector.d.ts.map +1 -1
- package/dist/src/vector/types/GeoPointVector.js +6 -10
- package/dist/src/vector/types/GeoPointVector.js.map +1 -1
- package/dist/src/vector/types/IPRangeVector.d.ts +2 -2
- package/dist/src/vector/types/IPRangeVector.d.ts.map +1 -1
- package/dist/src/vector/types/IPRangeVector.js +6 -10
- package/dist/src/vector/types/IPRangeVector.js.map +1 -1
- package/dist/src/vector/types/IPVector.d.ts +2 -2
- package/dist/src/vector/types/IPVector.d.ts.map +1 -1
- package/dist/src/vector/types/IPVector.js +7 -11
- package/dist/src/vector/types/IPVector.js.map +1 -1
- package/dist/src/vector/types/IntVector.d.ts +2 -2
- package/dist/src/vector/types/IntVector.d.ts.map +1 -1
- package/dist/src/vector/types/IntVector.js +6 -10
- package/dist/src/vector/types/IntVector.js.map +1 -1
- package/dist/src/vector/types/ObjectVector.d.ts +2 -2
- package/dist/src/vector/types/ObjectVector.d.ts.map +1 -1
- package/dist/src/vector/types/ObjectVector.js +19 -36
- package/dist/src/vector/types/ObjectVector.js.map +1 -1
- package/dist/src/vector/types/StringVector.d.ts +2 -2
- package/dist/src/vector/types/StringVector.d.ts.map +1 -1
- package/dist/src/vector/types/StringVector.js +6 -10
- package/dist/src/vector/types/StringVector.js.map +1 -1
- package/dist/src/vector/types/TupleVector.d.ts +2 -2
- package/dist/src/vector/types/TupleVector.d.ts.map +1 -1
- package/dist/src/vector/types/TupleVector.js +17 -34
- package/dist/src/vector/types/TupleVector.js.map +1 -1
- package/dist/src/vector/types/index.d.ts +14 -14
- package/dist/src/vector/types/index.d.ts.map +1 -1
- package/dist/src/vector/types/index.js +14 -30
- package/dist/src/vector/types/index.js.map +1 -1
- package/dist/src/vector/utils.d.ts +2 -2
- package/dist/src/vector/utils.d.ts.map +1 -1
- package/dist/src/vector/utils.js +95 -106
- package/dist/src/vector/utils.js.map +1 -1
- package/package.json +7 -6
|
@@ -1,326 +1,297 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
-
};
|
|
28
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.toTitleCase = exports.toSnakeCase = exports.toPascalCase = exports.toKebabCase = exports.toCamelCase = exports.parseDate = exports.formatDate = exports.toISO8601 = exports.toUnixTime = exports.splitString = exports.replaceLiteral = exports.replaceRegex = exports.extract = exports.toGeoPoint = exports.toJSON = exports.parseJSON = exports.encodeSHA1 = exports.encodeSHA = exports.encodeMD5 = exports.encodeHex = exports.decodeHex = exports.encodeURL = exports.decodeURL = exports.encodeBase64 = exports.decodeBase64 = exports.toNumber = exports.toISDN = exports.truncate = exports.trimEnd = exports.trimStart = exports.trim = exports.toLowerCase = exports.toUpperCase = exports.toBoolean = exports.toString = exports.setField = exports.map = exports.setDefault = exports.repository = void 0;
|
|
30
|
-
const ts = __importStar(require("@terascope/utils"));
|
|
31
|
-
const types_1 = require("@terascope/types");
|
|
32
|
-
const crypto_1 = __importDefault(require("crypto"));
|
|
33
|
-
const awesome_phonenumber_1 = __importDefault(require("awesome-phonenumber"));
|
|
34
|
-
const date_fns_1 = require("date-fns");
|
|
35
|
-
const field_validator_1 = require("../validations/field-validator");
|
|
36
|
-
const interfaces_1 = require("../interfaces");
|
|
37
|
-
exports.repository = {
|
|
1
|
+
import * as ts from '@terascope/utils';
|
|
2
|
+
import { FieldType } from '@terascope/types';
|
|
3
|
+
import crypto from 'node:crypto';
|
|
4
|
+
import PhoneValidator from 'awesome-phonenumber';
|
|
5
|
+
import { format as dateFormat, parse } from 'date-fns';
|
|
6
|
+
import { isString, isValidDate, isNumber, isArray, isNumberTuple } from '../validations/field-validator.js';
|
|
7
|
+
import { InputType } from '../interfaces.js';
|
|
8
|
+
export const repository = {
|
|
38
9
|
toString: {
|
|
39
10
|
fn: toString,
|
|
40
11
|
config: {},
|
|
41
|
-
output_type:
|
|
42
|
-
primary_input_type:
|
|
12
|
+
output_type: FieldType.String,
|
|
13
|
+
primary_input_type: InputType.String
|
|
43
14
|
},
|
|
44
15
|
toBoolean: {
|
|
45
16
|
fn: toBoolean,
|
|
46
17
|
config: {},
|
|
47
|
-
output_type:
|
|
48
|
-
primary_input_type:
|
|
18
|
+
output_type: FieldType.Boolean,
|
|
19
|
+
primary_input_type: InputType.Any
|
|
49
20
|
},
|
|
50
21
|
toUpperCase: {
|
|
51
22
|
fn: toUpperCase,
|
|
52
23
|
config: {},
|
|
53
|
-
output_type:
|
|
54
|
-
primary_input_type:
|
|
24
|
+
output_type: FieldType.String,
|
|
25
|
+
primary_input_type: InputType.String
|
|
55
26
|
},
|
|
56
27
|
toLowerCase: {
|
|
57
28
|
fn: toLowerCase,
|
|
58
29
|
config: {},
|
|
59
|
-
output_type:
|
|
60
|
-
primary_input_type:
|
|
30
|
+
output_type: FieldType.String,
|
|
31
|
+
primary_input_type: InputType.String
|
|
61
32
|
},
|
|
62
33
|
trim: {
|
|
63
34
|
fn: trim,
|
|
64
35
|
config: {
|
|
65
|
-
char: { type:
|
|
36
|
+
char: { type: FieldType.String }
|
|
66
37
|
},
|
|
67
|
-
output_type:
|
|
68
|
-
primary_input_type:
|
|
38
|
+
output_type: FieldType.String,
|
|
39
|
+
primary_input_type: InputType.String
|
|
69
40
|
},
|
|
70
41
|
truncate: {
|
|
71
42
|
fn: truncate,
|
|
72
43
|
config: {
|
|
73
|
-
size: { type:
|
|
44
|
+
size: { type: FieldType.Number }
|
|
74
45
|
},
|
|
75
|
-
output_type:
|
|
76
|
-
primary_input_type:
|
|
46
|
+
output_type: FieldType.String,
|
|
47
|
+
primary_input_type: InputType.String
|
|
77
48
|
},
|
|
78
49
|
toISDN: {
|
|
79
50
|
fn: toISDN,
|
|
80
51
|
config: {},
|
|
81
|
-
output_type:
|
|
82
|
-
primary_input_type:
|
|
52
|
+
output_type: FieldType.String,
|
|
53
|
+
primary_input_type: InputType.String
|
|
83
54
|
},
|
|
84
55
|
toNumber: {
|
|
85
56
|
fn: toNumber,
|
|
86
57
|
config: {
|
|
87
|
-
booleanLike: { type:
|
|
58
|
+
booleanLike: { type: FieldType.Boolean }
|
|
88
59
|
},
|
|
89
|
-
output_type:
|
|
90
|
-
primary_input_type:
|
|
60
|
+
output_type: FieldType.Number,
|
|
61
|
+
primary_input_type: InputType.String
|
|
91
62
|
},
|
|
92
63
|
decodeBase64: {
|
|
93
64
|
fn: decodeBase64,
|
|
94
65
|
config: {},
|
|
95
|
-
output_type:
|
|
96
|
-
primary_input_type:
|
|
66
|
+
output_type: FieldType.String,
|
|
67
|
+
primary_input_type: InputType.String
|
|
97
68
|
},
|
|
98
69
|
encodeBase64: {
|
|
99
70
|
fn: encodeBase64,
|
|
100
71
|
config: {},
|
|
101
|
-
output_type:
|
|
102
|
-
primary_input_type:
|
|
72
|
+
output_type: FieldType.String,
|
|
73
|
+
primary_input_type: InputType.String
|
|
103
74
|
},
|
|
104
75
|
decodeURL: {
|
|
105
76
|
fn: decodeURL,
|
|
106
77
|
config: {},
|
|
107
|
-
output_type:
|
|
108
|
-
primary_input_type:
|
|
78
|
+
output_type: FieldType.String,
|
|
79
|
+
primary_input_type: InputType.String
|
|
109
80
|
},
|
|
110
81
|
encodeURL: {
|
|
111
82
|
fn: encodeURL,
|
|
112
83
|
config: {},
|
|
113
|
-
output_type:
|
|
114
|
-
primary_input_type:
|
|
84
|
+
output_type: FieldType.String,
|
|
85
|
+
primary_input_type: InputType.String
|
|
115
86
|
},
|
|
116
87
|
decodeHex: {
|
|
117
88
|
fn: decodeHex,
|
|
118
89
|
config: {},
|
|
119
|
-
output_type:
|
|
120
|
-
primary_input_type:
|
|
90
|
+
output_type: FieldType.String,
|
|
91
|
+
primary_input_type: InputType.String
|
|
121
92
|
},
|
|
122
93
|
encodeHex: {
|
|
123
94
|
fn: encodeHex,
|
|
124
95
|
config: {},
|
|
125
|
-
output_type:
|
|
126
|
-
primary_input_type:
|
|
96
|
+
output_type: FieldType.String,
|
|
97
|
+
primary_input_type: InputType.String
|
|
127
98
|
},
|
|
128
99
|
encodeMD5: {
|
|
129
100
|
fn: encodeMD5,
|
|
130
101
|
config: {},
|
|
131
|
-
output_type:
|
|
132
|
-
primary_input_type:
|
|
102
|
+
output_type: FieldType.String,
|
|
103
|
+
primary_input_type: InputType.String
|
|
133
104
|
},
|
|
134
105
|
encodeSHA: {
|
|
135
106
|
fn: encodeSHA,
|
|
136
107
|
config: {
|
|
137
|
-
hash: { type:
|
|
138
|
-
digest: { type:
|
|
108
|
+
hash: { type: FieldType.String },
|
|
109
|
+
digest: { type: FieldType.String }
|
|
139
110
|
},
|
|
140
|
-
output_type:
|
|
141
|
-
primary_input_type:
|
|
111
|
+
output_type: FieldType.String,
|
|
112
|
+
primary_input_type: InputType.String
|
|
142
113
|
},
|
|
143
114
|
encodeSHA1: {
|
|
144
115
|
fn: encodeSHA1,
|
|
145
116
|
config: {},
|
|
146
|
-
output_type:
|
|
147
|
-
primary_input_type:
|
|
117
|
+
output_type: FieldType.String,
|
|
118
|
+
primary_input_type: InputType.String
|
|
148
119
|
},
|
|
149
120
|
parseJSON: {
|
|
150
121
|
fn: parseJSON,
|
|
151
122
|
config: {},
|
|
152
|
-
output_type:
|
|
153
|
-
primary_input_type:
|
|
123
|
+
output_type: FieldType.Any,
|
|
124
|
+
primary_input_type: InputType.String
|
|
154
125
|
},
|
|
155
126
|
toJSON: {
|
|
156
127
|
fn: toJSON,
|
|
157
128
|
config: {
|
|
158
|
-
pretty: { type:
|
|
129
|
+
pretty: { type: FieldType.Boolean }
|
|
159
130
|
},
|
|
160
|
-
output_type:
|
|
161
|
-
primary_input_type:
|
|
131
|
+
output_type: FieldType.String,
|
|
132
|
+
primary_input_type: InputType.Any
|
|
162
133
|
},
|
|
163
134
|
toGeoPoint: {
|
|
164
135
|
fn: toGeoPoint,
|
|
165
136
|
config: {},
|
|
166
|
-
output_type:
|
|
167
|
-
primary_input_type:
|
|
137
|
+
output_type: FieldType.GeoPoint,
|
|
138
|
+
primary_input_type: InputType.String
|
|
168
139
|
},
|
|
169
140
|
// this will be overridden
|
|
170
141
|
extract: {
|
|
171
142
|
fn: extract,
|
|
172
143
|
config: {
|
|
173
|
-
regex: { type:
|
|
174
|
-
isMultiValue: { type:
|
|
175
|
-
jexlExp: { type:
|
|
176
|
-
start: { type:
|
|
177
|
-
end: { type:
|
|
144
|
+
regex: { type: FieldType.String },
|
|
145
|
+
isMultiValue: { type: FieldType.Boolean },
|
|
146
|
+
jexlExp: { type: FieldType.String },
|
|
147
|
+
start: { type: FieldType.String },
|
|
148
|
+
end: { type: FieldType.String }
|
|
178
149
|
},
|
|
179
|
-
output_type:
|
|
180
|
-
primary_input_type:
|
|
150
|
+
output_type: FieldType.Any,
|
|
151
|
+
primary_input_type: InputType.String
|
|
181
152
|
},
|
|
182
153
|
replaceRegex: {
|
|
183
154
|
fn: replaceRegex,
|
|
184
155
|
config: {
|
|
185
|
-
regex: { type:
|
|
186
|
-
replace: { type:
|
|
187
|
-
global: { type:
|
|
188
|
-
ignore_case: { type:
|
|
156
|
+
regex: { type: FieldType.String },
|
|
157
|
+
replace: { type: FieldType.String },
|
|
158
|
+
global: { type: FieldType.String },
|
|
159
|
+
ignore_case: { type: FieldType.Boolean }
|
|
189
160
|
},
|
|
190
|
-
output_type:
|
|
191
|
-
primary_input_type:
|
|
161
|
+
output_type: FieldType.String,
|
|
162
|
+
primary_input_type: InputType.String
|
|
192
163
|
},
|
|
193
164
|
replaceLiteral: {
|
|
194
165
|
fn: replaceLiteral,
|
|
195
166
|
config: {
|
|
196
167
|
search: {
|
|
197
|
-
type:
|
|
168
|
+
type: FieldType.String
|
|
198
169
|
},
|
|
199
170
|
replace: {
|
|
200
|
-
type:
|
|
171
|
+
type: FieldType.String
|
|
201
172
|
}
|
|
202
173
|
},
|
|
203
|
-
output_type:
|
|
204
|
-
primary_input_type:
|
|
174
|
+
output_type: FieldType.String,
|
|
175
|
+
primary_input_type: InputType.String
|
|
205
176
|
},
|
|
206
177
|
toUnixTime: {
|
|
207
178
|
fn: toUnixTime,
|
|
208
179
|
config: {},
|
|
209
|
-
output_type:
|
|
210
|
-
primary_input_type:
|
|
180
|
+
output_type: FieldType.Number,
|
|
181
|
+
primary_input_type: InputType.String
|
|
211
182
|
},
|
|
212
183
|
toISO8601: {
|
|
213
184
|
fn: toISO8601,
|
|
214
185
|
config: {
|
|
215
186
|
resolution: {
|
|
216
|
-
type:
|
|
187
|
+
type: FieldType.String,
|
|
217
188
|
description: 'may be set to seconds | milliseconds'
|
|
218
189
|
}
|
|
219
190
|
},
|
|
220
|
-
output_type:
|
|
221
|
-
primary_input_type:
|
|
191
|
+
output_type: FieldType.String,
|
|
192
|
+
primary_input_type: InputType.String
|
|
222
193
|
},
|
|
223
194
|
formatDate: {
|
|
224
195
|
fn: formatDate,
|
|
225
196
|
config: {
|
|
226
|
-
format: { type:
|
|
227
|
-
resolution: { type:
|
|
197
|
+
format: { type: FieldType.String },
|
|
198
|
+
resolution: { type: FieldType.String, description: 'may be set to seconds | milliseconds' },
|
|
228
199
|
},
|
|
229
|
-
output_type:
|
|
230
|
-
primary_input_type:
|
|
200
|
+
output_type: FieldType.String,
|
|
201
|
+
primary_input_type: InputType.String
|
|
231
202
|
},
|
|
232
203
|
parseDate: {
|
|
233
204
|
fn: parseDate,
|
|
234
205
|
config: {
|
|
235
|
-
format: { type:
|
|
206
|
+
format: { type: FieldType.String },
|
|
236
207
|
},
|
|
237
|
-
output_type:
|
|
238
|
-
primary_input_type:
|
|
208
|
+
output_type: FieldType.Date,
|
|
209
|
+
primary_input_type: InputType.String
|
|
239
210
|
},
|
|
240
211
|
trimStart: {
|
|
241
212
|
fn: trimStart,
|
|
242
213
|
config: {
|
|
243
|
-
char: { type:
|
|
214
|
+
char: { type: FieldType.String }
|
|
244
215
|
},
|
|
245
|
-
output_type:
|
|
246
|
-
primary_input_type:
|
|
216
|
+
output_type: FieldType.String,
|
|
217
|
+
primary_input_type: InputType.String
|
|
247
218
|
},
|
|
248
219
|
trimEnd: {
|
|
249
220
|
fn: trimEnd,
|
|
250
221
|
config: {
|
|
251
|
-
char: { type:
|
|
222
|
+
char: { type: FieldType.String }
|
|
252
223
|
},
|
|
253
|
-
output_type:
|
|
254
|
-
primary_input_type:
|
|
224
|
+
output_type: FieldType.String,
|
|
225
|
+
primary_input_type: InputType.String
|
|
255
226
|
},
|
|
256
227
|
toCamelCase: {
|
|
257
228
|
fn: toCamelCase,
|
|
258
229
|
config: {},
|
|
259
|
-
output_type:
|
|
260
|
-
primary_input_type:
|
|
230
|
+
output_type: FieldType.String,
|
|
231
|
+
primary_input_type: InputType.String
|
|
261
232
|
},
|
|
262
233
|
toKebabCase: {
|
|
263
234
|
fn: toKebabCase,
|
|
264
235
|
config: {},
|
|
265
|
-
output_type:
|
|
266
|
-
primary_input_type:
|
|
236
|
+
output_type: FieldType.String,
|
|
237
|
+
primary_input_type: InputType.String
|
|
267
238
|
},
|
|
268
239
|
toPascalCase: {
|
|
269
240
|
fn: toPascalCase,
|
|
270
241
|
config: {},
|
|
271
|
-
output_type:
|
|
272
|
-
primary_input_type:
|
|
242
|
+
output_type: FieldType.String,
|
|
243
|
+
primary_input_type: InputType.String
|
|
273
244
|
},
|
|
274
245
|
toSnakeCase: {
|
|
275
246
|
fn: toSnakeCase,
|
|
276
247
|
config: {},
|
|
277
|
-
output_type:
|
|
278
|
-
primary_input_type:
|
|
248
|
+
output_type: FieldType.String,
|
|
249
|
+
primary_input_type: InputType.String
|
|
279
250
|
},
|
|
280
251
|
toTitleCase: {
|
|
281
252
|
fn: toTitleCase,
|
|
282
253
|
config: {},
|
|
283
|
-
output_type:
|
|
284
|
-
primary_input_type:
|
|
254
|
+
output_type: FieldType.String,
|
|
255
|
+
primary_input_type: InputType.String
|
|
285
256
|
},
|
|
286
257
|
setField: {
|
|
287
258
|
fn: setField,
|
|
288
259
|
config: {
|
|
289
260
|
value: {
|
|
290
|
-
type:
|
|
261
|
+
type: FieldType.Any
|
|
291
262
|
}
|
|
292
263
|
},
|
|
293
|
-
output_type:
|
|
294
|
-
primary_input_type:
|
|
264
|
+
output_type: FieldType.Any,
|
|
265
|
+
primary_input_type: InputType.String
|
|
295
266
|
},
|
|
296
267
|
setDefault: {
|
|
297
268
|
fn: setDefault,
|
|
298
269
|
config: {
|
|
299
270
|
value: {
|
|
300
|
-
type:
|
|
271
|
+
type: FieldType.Any
|
|
301
272
|
}
|
|
302
273
|
},
|
|
303
|
-
output_type:
|
|
304
|
-
primary_input_type:
|
|
274
|
+
output_type: FieldType.Any,
|
|
275
|
+
primary_input_type: InputType.String
|
|
305
276
|
},
|
|
306
277
|
map: {
|
|
307
278
|
fn: map,
|
|
308
279
|
config: {
|
|
309
280
|
fn: {
|
|
310
|
-
type:
|
|
281
|
+
type: FieldType.String
|
|
311
282
|
},
|
|
312
283
|
options: {
|
|
313
|
-
type:
|
|
284
|
+
type: FieldType.Object
|
|
314
285
|
}
|
|
315
286
|
},
|
|
316
|
-
output_type:
|
|
317
|
-
primary_input_type:
|
|
287
|
+
output_type: FieldType.Any,
|
|
288
|
+
primary_input_type: InputType.Array
|
|
318
289
|
},
|
|
319
290
|
splitString: {
|
|
320
291
|
fn: splitString,
|
|
321
292
|
config: {},
|
|
322
|
-
output_type:
|
|
323
|
-
primary_input_type:
|
|
293
|
+
output_type: FieldType.String,
|
|
294
|
+
primary_input_type: InputType.String
|
|
324
295
|
}
|
|
325
296
|
};
|
|
326
297
|
/**
|
|
@@ -336,7 +307,7 @@ exports.repository = {
|
|
|
336
307
|
* @param {{ value: any }} args value is what will be given when input is null/undefined
|
|
337
308
|
* @returns {*}
|
|
338
309
|
*/
|
|
339
|
-
function setDefault(input, _parentContext, args) {
|
|
310
|
+
export function setDefault(input, _parentContext, args) {
|
|
340
311
|
if (ts.isNil(input)) {
|
|
341
312
|
if (ts.isNil(args.value))
|
|
342
313
|
throw new Error('Parameter value cannot be set to undefined or null');
|
|
@@ -344,7 +315,6 @@ function setDefault(input, _parentContext, args) {
|
|
|
344
315
|
}
|
|
345
316
|
return input;
|
|
346
317
|
}
|
|
347
|
-
exports.setDefault = setDefault;
|
|
348
318
|
/**
|
|
349
319
|
* This function is used to map an array of values with any FieldTransform method
|
|
350
320
|
*
|
|
@@ -359,18 +329,17 @@ exports.setDefault = setDefault;
|
|
|
359
329
|
* options is an object with any additional parameters needed
|
|
360
330
|
* @returns {any[] | null} returns the mapped values, return null if input is null/undefined
|
|
361
331
|
*/
|
|
362
|
-
function map(input, parentContext, args) {
|
|
332
|
+
export function map(input, parentContext, args) {
|
|
363
333
|
if (ts.isNil(input))
|
|
364
334
|
return null;
|
|
365
|
-
if (!
|
|
335
|
+
if (!isArray(input))
|
|
366
336
|
throw new Error(`Input must be an array, received ${ts.getTypeOf(input)}`);
|
|
367
337
|
const { fn, options } = args;
|
|
368
|
-
const repoConfig =
|
|
338
|
+
const repoConfig = repository[fn];
|
|
369
339
|
if (!repoConfig)
|
|
370
340
|
throw new Error(`No function ${fn} was found in the field transform repository`);
|
|
371
341
|
return input.map((data) => repoConfig.fn(data, parentContext, options));
|
|
372
342
|
}
|
|
373
|
-
exports.map = map;
|
|
374
343
|
// TODO: this is currently a hack for directives, this will evolve, do not use it for other purposes
|
|
375
344
|
/**
|
|
376
345
|
* This function is not meant to be used programmatically
|
|
@@ -380,11 +349,10 @@ exports.map = map;
|
|
|
380
349
|
* @param {{ value: any }} args value will be used to set field
|
|
381
350
|
* @returns
|
|
382
351
|
*/
|
|
383
|
-
function setField(_input, _parentContext, args) {
|
|
352
|
+
export function setField(_input, _parentContext, args) {
|
|
384
353
|
const { value } = args;
|
|
385
354
|
return value;
|
|
386
355
|
}
|
|
387
|
-
exports.setField = setField;
|
|
388
356
|
/**
|
|
389
357
|
* Converts values to strings
|
|
390
358
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -397,14 +365,13 @@ exports.setField = setField;
|
|
|
397
365
|
* @param {*} input
|
|
398
366
|
* @returns {String | null} returns null if input is null/undefined
|
|
399
367
|
*/
|
|
400
|
-
function toString(input, _parentContext) {
|
|
368
|
+
export function toString(input, _parentContext) {
|
|
401
369
|
if (ts.isNil(input))
|
|
402
370
|
return null;
|
|
403
|
-
if (
|
|
371
|
+
if (isArray(input))
|
|
404
372
|
return input.filter(ts.isNotNil).map(ts.toString);
|
|
405
373
|
return ts.toString(input);
|
|
406
374
|
}
|
|
407
|
-
exports.toString = toString;
|
|
408
375
|
/**
|
|
409
376
|
* Converts values to booleans
|
|
410
377
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -417,14 +384,13 @@ exports.toString = toString;
|
|
|
417
384
|
* @param {*} input
|
|
418
385
|
* @returns {Boolean | null} returns null if input is null/undefined
|
|
419
386
|
*/
|
|
420
|
-
function toBoolean(input, _parentContext) {
|
|
387
|
+
export function toBoolean(input, _parentContext) {
|
|
421
388
|
if (ts.isNil(input))
|
|
422
389
|
return null;
|
|
423
|
-
if (
|
|
390
|
+
if (isArray(input))
|
|
424
391
|
return input.filter(ts.isNotNil).map(ts.toBoolean);
|
|
425
392
|
return ts.toBoolean(input);
|
|
426
393
|
}
|
|
427
|
-
exports.toBoolean = toBoolean;
|
|
428
394
|
/**
|
|
429
395
|
* Converts strings to UpperCase
|
|
430
396
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -437,16 +403,15 @@ exports.toBoolean = toBoolean;
|
|
|
437
403
|
* @param {StringInput} input string or string[]
|
|
438
404
|
* @returns { String | String[] | null } returns null if input is null/undefined
|
|
439
405
|
*/
|
|
440
|
-
function toUpperCase(input, _parentContext) {
|
|
406
|
+
export function toUpperCase(input, _parentContext) {
|
|
441
407
|
if (ts.isNil(input))
|
|
442
408
|
return null;
|
|
443
|
-
if (
|
|
409
|
+
if (isArray(input))
|
|
444
410
|
return input.filter(ts.isNotNil).map((str) => str.toUpperCase());
|
|
445
|
-
if (!
|
|
411
|
+
if (!isString(input))
|
|
446
412
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
447
413
|
return input.toUpperCase();
|
|
448
414
|
}
|
|
449
|
-
exports.toUpperCase = toUpperCase;
|
|
450
415
|
/**
|
|
451
416
|
* Converts strings to lowercase
|
|
452
417
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -459,16 +424,15 @@ exports.toUpperCase = toUpperCase;
|
|
|
459
424
|
* @param {StringInput} input string | string[]
|
|
460
425
|
* @returns { String | String[] | null } returns null if input is null/undefined
|
|
461
426
|
*/
|
|
462
|
-
function toLowerCase(input, _parentContext) {
|
|
427
|
+
export function toLowerCase(input, _parentContext) {
|
|
463
428
|
if (ts.isNil(input))
|
|
464
429
|
return null;
|
|
465
|
-
if (
|
|
430
|
+
if (isArray(input))
|
|
466
431
|
return input.filter(ts.isNotNil).map((str) => str.toLowerCase());
|
|
467
|
-
if (!
|
|
432
|
+
if (!isString(input))
|
|
468
433
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
469
434
|
return input.toLowerCase();
|
|
470
435
|
}
|
|
471
|
-
exports.toLowerCase = toLowerCase;
|
|
472
436
|
/**
|
|
473
437
|
* Will trim the input
|
|
474
438
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -488,18 +452,17 @@ exports.toLowerCase = toLowerCase;
|
|
|
488
452
|
* @param {{ char: string }} [args] a single char or word that will be cut out
|
|
489
453
|
* @returns { String | String[] | null } returns null if input is null/undefined
|
|
490
454
|
*/
|
|
491
|
-
function trim(input, parentContext, args) {
|
|
455
|
+
export function trim(input, parentContext, args) {
|
|
492
456
|
if (ts.isNil(input))
|
|
493
457
|
return null;
|
|
494
|
-
const char = (
|
|
495
|
-
if (
|
|
458
|
+
const char = (args?.char && isString(args.char)) ? args.char : ' ';
|
|
459
|
+
if (isArray(input)) {
|
|
496
460
|
return input
|
|
497
461
|
.filter(ts.isNotNil)
|
|
498
462
|
.map((str) => ts.trim(str, char));
|
|
499
463
|
}
|
|
500
464
|
return ts.trim(input, char);
|
|
501
465
|
}
|
|
502
|
-
exports.trim = trim;
|
|
503
466
|
/**
|
|
504
467
|
* Will trim the beginning of the input
|
|
505
468
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -515,21 +478,20 @@ exports.trim = trim;
|
|
|
515
478
|
* @param {{ char: string }} [args]
|
|
516
479
|
* @returns { String | String[] | null } returns null if input is null/undefined
|
|
517
480
|
*/
|
|
518
|
-
function trimStart(input, _parentContext, args) {
|
|
481
|
+
export function trimStart(input, _parentContext, args) {
|
|
519
482
|
if (ts.isNil(input))
|
|
520
483
|
return null;
|
|
521
|
-
if (
|
|
484
|
+
if (args?.char && !isString(args.char))
|
|
522
485
|
throw new Error(`Parameter char must be a string, received ${ts.getTypeOf(input)}`);
|
|
523
|
-
if (
|
|
486
|
+
if (isArray(input)) {
|
|
524
487
|
return input
|
|
525
488
|
.filter(ts.isNotNil)
|
|
526
|
-
.map((str) => ts.trimStart(str, args
|
|
489
|
+
.map((str) => ts.trimStart(str, args?.char));
|
|
527
490
|
}
|
|
528
|
-
if (!
|
|
491
|
+
if (!isString(input))
|
|
529
492
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
530
|
-
return ts.trimStart(input, args
|
|
493
|
+
return ts.trimStart(input, args?.char);
|
|
531
494
|
}
|
|
532
|
-
exports.trimStart = trimStart;
|
|
533
495
|
/**
|
|
534
496
|
* Will trim the end of the input
|
|
535
497
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -544,21 +506,20 @@ exports.trimStart = trimStart;
|
|
|
544
506
|
* @param {{ char: string }} [args]
|
|
545
507
|
* @returns { String | String[] | null } returns null if input is null/undefined
|
|
546
508
|
*/
|
|
547
|
-
function trimEnd(input, _parentContext, args) {
|
|
509
|
+
export function trimEnd(input, _parentContext, args) {
|
|
548
510
|
if (ts.isNil(input))
|
|
549
511
|
return null;
|
|
550
|
-
if (
|
|
512
|
+
if (args?.char && !isString(args.char))
|
|
551
513
|
throw new Error(`Parameter char must be a string, received ${ts.getTypeOf(input)}`);
|
|
552
|
-
if (
|
|
514
|
+
if (isArray(input)) {
|
|
553
515
|
return input
|
|
554
516
|
.filter(ts.isNotNil)
|
|
555
|
-
.map((str) => ts.trimEnd(str, args
|
|
517
|
+
.map((str) => ts.trimEnd(str, args?.char));
|
|
556
518
|
}
|
|
557
|
-
if (!
|
|
519
|
+
if (!isString(input))
|
|
558
520
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
559
|
-
return ts.trimEnd(input, args
|
|
521
|
+
return ts.trimEnd(input, args?.char);
|
|
560
522
|
}
|
|
561
|
-
exports.trimEnd = trimEnd;
|
|
562
523
|
/**
|
|
563
524
|
* Will truncate the input to the length of the size given
|
|
564
525
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -572,22 +533,21 @@ exports.trimEnd = trimEnd;
|
|
|
572
533
|
* @param {{ size: number }} args
|
|
573
534
|
* @returns { String | String[] | null } returns null if input is null/undefined
|
|
574
535
|
*/
|
|
575
|
-
function truncate(input, _parentContext, args) {
|
|
536
|
+
export function truncate(input, _parentContext, args) {
|
|
576
537
|
const { size } = args;
|
|
577
538
|
if (ts.isNil(input))
|
|
578
539
|
return null;
|
|
579
540
|
if (!size || !ts.isNumber(size) || size <= 0)
|
|
580
541
|
throw new Error('Invalid size paramter for truncate');
|
|
581
|
-
if (
|
|
542
|
+
if (isArray(input)) {
|
|
582
543
|
return input
|
|
583
544
|
.filter(ts.isNotNil)
|
|
584
545
|
.map((str) => str.slice(0, size));
|
|
585
546
|
}
|
|
586
|
-
if (!
|
|
547
|
+
if (!isString(input))
|
|
587
548
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
588
549
|
return input.slice(0, size);
|
|
589
550
|
}
|
|
590
|
-
exports.truncate = truncate;
|
|
591
551
|
function parsePhoneNumber(str) {
|
|
592
552
|
let testNumber = ts.toString(str).trim();
|
|
593
553
|
if (testNumber.charAt(0) === '0')
|
|
@@ -595,7 +555,7 @@ function parsePhoneNumber(str) {
|
|
|
595
555
|
// needs to start with a +
|
|
596
556
|
if (testNumber.charAt(0) !== '+')
|
|
597
557
|
testNumber = `+${testNumber}`;
|
|
598
|
-
const fullNumber = new
|
|
558
|
+
const fullNumber = new PhoneValidator(testNumber).getNumber();
|
|
599
559
|
if (fullNumber)
|
|
600
560
|
return String(fullNumber).slice(1);
|
|
601
561
|
throw Error('Could not determine the incoming phone number');
|
|
@@ -614,17 +574,16 @@ function parsePhoneNumber(str) {
|
|
|
614
574
|
* @returns { String | String[] | null } a fully validated phone number,
|
|
615
575
|
* returns null if input is null/undefined
|
|
616
576
|
*/
|
|
617
|
-
function toISDN(input, _parentContext) {
|
|
577
|
+
export function toISDN(input, _parentContext) {
|
|
618
578
|
if (ts.isNil(input))
|
|
619
579
|
return null;
|
|
620
|
-
if (
|
|
580
|
+
if (isArray(input))
|
|
621
581
|
return input.filter(ts.isNotNil).map(parsePhoneNumber);
|
|
622
582
|
return parsePhoneNumber(input);
|
|
623
583
|
}
|
|
624
|
-
exports.toISDN = toISDN;
|
|
625
584
|
function convertToNumber(input, args) {
|
|
626
585
|
let result = input;
|
|
627
|
-
if (
|
|
586
|
+
if (args?.booleanLike === true && ts.isBooleanLike(input)) {
|
|
628
587
|
result = ts.toNumber(toBoolean(result));
|
|
629
588
|
}
|
|
630
589
|
result = ts.toNumber(result);
|
|
@@ -649,17 +608,16 @@ function convertToNumber(input, args) {
|
|
|
649
608
|
* @param {{ booleanLike?: boolean }} [args]
|
|
650
609
|
* @returns { number | null } returns null if input is null/undefined
|
|
651
610
|
*/
|
|
652
|
-
function toNumber(input, _parentContext, args) {
|
|
653
|
-
if (ts.isNil(input) &&
|
|
611
|
+
export function toNumber(input, _parentContext, args) {
|
|
612
|
+
if (ts.isNil(input) && args?.booleanLike !== true)
|
|
654
613
|
return null;
|
|
655
|
-
if (
|
|
614
|
+
if (isArray(input)) {
|
|
656
615
|
return input
|
|
657
616
|
.filter(ts.isNotNil)
|
|
658
617
|
.map((data) => convertToNumber(data, args));
|
|
659
618
|
}
|
|
660
619
|
return convertToNumber(input, args);
|
|
661
620
|
}
|
|
662
|
-
exports.toNumber = toNumber;
|
|
663
621
|
/**
|
|
664
622
|
* decodes a base64 encoded value
|
|
665
623
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -677,17 +635,16 @@ exports.toNumber = toNumber;
|
|
|
677
635
|
* @param {*} input
|
|
678
636
|
* @returns { string | null } returns null if input is null/undefined
|
|
679
637
|
*/
|
|
680
|
-
function decodeBase64(input, _parentContext) {
|
|
638
|
+
export function decodeBase64(input, _parentContext) {
|
|
681
639
|
if (ts.isNil(input))
|
|
682
640
|
return null;
|
|
683
|
-
if (
|
|
641
|
+
if (isArray(input)) {
|
|
684
642
|
return input
|
|
685
643
|
.filter(ts.isNotNil)
|
|
686
644
|
.map((data) => Buffer.from(data, 'base64').toString('utf8'));
|
|
687
645
|
}
|
|
688
646
|
return Buffer.from(input, 'base64').toString('utf8');
|
|
689
647
|
}
|
|
690
|
-
exports.decodeBase64 = decodeBase64;
|
|
691
648
|
/**
|
|
692
649
|
* converts a value into a base64 encoded value
|
|
693
650
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -702,17 +659,16 @@ exports.decodeBase64 = decodeBase64;
|
|
|
702
659
|
* @param {*} input
|
|
703
660
|
* @returns { string | null } returns null if input is null/undefined
|
|
704
661
|
*/
|
|
705
|
-
function encodeBase64(input, _parentContext) {
|
|
662
|
+
export function encodeBase64(input, _parentContext) {
|
|
706
663
|
if (ts.isNil(input))
|
|
707
664
|
return null;
|
|
708
|
-
if (
|
|
665
|
+
if (isArray(input)) {
|
|
709
666
|
return input
|
|
710
667
|
.filter(ts.isNotNil)
|
|
711
668
|
.map((data) => Buffer.from(data).toString('base64'));
|
|
712
669
|
}
|
|
713
670
|
return Buffer.from(input).toString('base64');
|
|
714
671
|
}
|
|
715
|
-
exports.encodeBase64 = encodeBase64;
|
|
716
672
|
/**
|
|
717
673
|
* decodes a URL encoded value
|
|
718
674
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -728,16 +684,15 @@ exports.encodeBase64 = encodeBase64;
|
|
|
728
684
|
* @param {StringInput} input
|
|
729
685
|
* @returns { string | null } returns null if input is null/undefined
|
|
730
686
|
*/
|
|
731
|
-
function decodeURL(input, _parentContext) {
|
|
687
|
+
export function decodeURL(input, _parentContext) {
|
|
732
688
|
if (ts.isNil(input))
|
|
733
689
|
return null;
|
|
734
|
-
if (
|
|
690
|
+
if (isArray(input))
|
|
735
691
|
return input.filter(ts.isNotNil).map(decodeURIComponent);
|
|
736
|
-
if (!
|
|
692
|
+
if (!isString(input))
|
|
737
693
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
738
694
|
return decodeURIComponent(input);
|
|
739
695
|
}
|
|
740
|
-
exports.decodeURL = decodeURL;
|
|
741
696
|
/**
|
|
742
697
|
* URL encodes a value
|
|
743
698
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -753,16 +708,15 @@ exports.decodeURL = decodeURL;
|
|
|
753
708
|
* @param {StringInput} input
|
|
754
709
|
* @returns { string | null } returns null if input is null/undefined
|
|
755
710
|
*/
|
|
756
|
-
function encodeURL(input, _parentContext) {
|
|
711
|
+
export function encodeURL(input, _parentContext) {
|
|
757
712
|
if (ts.isNil(input))
|
|
758
713
|
return null;
|
|
759
|
-
if (
|
|
714
|
+
if (isArray(input))
|
|
760
715
|
return input.filter(ts.isNotNil).map(encodeURIComponent);
|
|
761
|
-
if (!
|
|
716
|
+
if (!isString(input))
|
|
762
717
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
763
718
|
return encodeURIComponent(input);
|
|
764
719
|
}
|
|
765
|
-
exports.encodeURL = encodeURL;
|
|
766
720
|
/**
|
|
767
721
|
* decodes the hex encoded input
|
|
768
722
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -778,17 +732,16 @@ exports.encodeURL = encodeURL;
|
|
|
778
732
|
* @param {*} input
|
|
779
733
|
* @returns { string | null } returns null if input is null/undefined
|
|
780
734
|
*/
|
|
781
|
-
function decodeHex(input, _parentContext) {
|
|
735
|
+
export function decodeHex(input, _parentContext) {
|
|
782
736
|
if (ts.isNil(input))
|
|
783
737
|
return null;
|
|
784
|
-
if (
|
|
738
|
+
if (isArray(input)) {
|
|
785
739
|
return input
|
|
786
740
|
.filter(ts.isNotNil)
|
|
787
741
|
.map((data) => Buffer.from(data, 'hex').toString('utf8'));
|
|
788
742
|
}
|
|
789
743
|
return Buffer.from(input, 'hex').toString('utf8');
|
|
790
744
|
}
|
|
791
|
-
exports.decodeHex = decodeHex;
|
|
792
745
|
/**
|
|
793
746
|
* hex encodes the input
|
|
794
747
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -803,17 +756,16 @@ exports.decodeHex = decodeHex;
|
|
|
803
756
|
* @param {*} input
|
|
804
757
|
* @returns { string | null } returns null if input is null/undefined
|
|
805
758
|
*/
|
|
806
|
-
function encodeHex(input, _parentContext) {
|
|
759
|
+
export function encodeHex(input, _parentContext) {
|
|
807
760
|
if (ts.isNil(input))
|
|
808
761
|
return null;
|
|
809
|
-
if (
|
|
762
|
+
if (isArray(input)) {
|
|
810
763
|
return input
|
|
811
764
|
.filter(ts.isNotNil)
|
|
812
765
|
.map((data) => Buffer.from(data).toString('hex'));
|
|
813
766
|
}
|
|
814
767
|
return Buffer.from(input).toString('hex');
|
|
815
768
|
}
|
|
816
|
-
exports.encodeHex = encodeHex;
|
|
817
769
|
/**
|
|
818
770
|
* MD5 encodes the input
|
|
819
771
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -826,17 +778,16 @@ exports.encodeHex = encodeHex;
|
|
|
826
778
|
* @param {*} input
|
|
827
779
|
* @returns { string | null } returns null if input is null/undefined
|
|
828
780
|
*/
|
|
829
|
-
function encodeMD5(input, _parentContext) {
|
|
781
|
+
export function encodeMD5(input, _parentContext) {
|
|
830
782
|
if (ts.isNil(input))
|
|
831
783
|
return null;
|
|
832
|
-
if (
|
|
784
|
+
if (isArray(input)) {
|
|
833
785
|
return input
|
|
834
786
|
.filter(ts.isNotNil)
|
|
835
|
-
.map((data) =>
|
|
787
|
+
.map((data) => crypto.createHash('md5').update(data).digest('hex'));
|
|
836
788
|
}
|
|
837
|
-
return
|
|
789
|
+
return crypto.createHash('md5').update(input).digest('hex');
|
|
838
790
|
}
|
|
839
|
-
exports.encodeMD5 = encodeMD5;
|
|
840
791
|
/**
|
|
841
792
|
* SHA encodes the input to the hash specified
|
|
842
793
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -854,20 +805,19 @@ exports.encodeMD5 = encodeMD5;
|
|
|
854
805
|
* possible hash values
|
|
855
806
|
* @returns { string | null } returns null if input is null/undefined
|
|
856
807
|
*/
|
|
857
|
-
function encodeSHA(input, _parentContext, { hash = 'sha256', digest = 'hex' } = {}) {
|
|
808
|
+
export function encodeSHA(input, _parentContext, { hash = 'sha256', digest = 'hex' } = {}) {
|
|
858
809
|
if (ts.isNil(input))
|
|
859
810
|
return null;
|
|
860
811
|
if (!['ascii', 'utf8', 'utf16le', 'ucs2', 'base64', 'latin1', 'hex', 'binary'].includes(digest)) {
|
|
861
812
|
throw new Error('Parameter digest is misconfigured');
|
|
862
813
|
}
|
|
863
|
-
if (
|
|
814
|
+
if (isArray(input)) {
|
|
864
815
|
return input
|
|
865
816
|
.filter(ts.isNotNil)
|
|
866
|
-
.map((data) =>
|
|
817
|
+
.map((data) => crypto.createHash(hash).update(data).digest(digest));
|
|
867
818
|
}
|
|
868
|
-
return
|
|
819
|
+
return crypto.createHash(hash).update(input).digest(digest);
|
|
869
820
|
}
|
|
870
|
-
exports.encodeSHA = encodeSHA;
|
|
871
821
|
/**
|
|
872
822
|
* converts the value to a SHA1 encoded value
|
|
873
823
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -882,17 +832,16 @@ exports.encodeSHA = encodeSHA;
|
|
|
882
832
|
* @param {*} input
|
|
883
833
|
* @returns { string | null } returns null if input is null/undefined
|
|
884
834
|
*/
|
|
885
|
-
function encodeSHA1(input, _parentContext) {
|
|
835
|
+
export function encodeSHA1(input, _parentContext) {
|
|
886
836
|
if (ts.isNil(input))
|
|
887
837
|
return null;
|
|
888
|
-
if (
|
|
838
|
+
if (isArray(input)) {
|
|
889
839
|
return input
|
|
890
840
|
.filter(ts.isNotNil)
|
|
891
|
-
.map((data) =>
|
|
841
|
+
.map((data) => crypto.createHash('sha1').update(data).digest('hex'));
|
|
892
842
|
}
|
|
893
|
-
return
|
|
843
|
+
return crypto.createHash('sha1').update(input).digest('hex');
|
|
894
844
|
}
|
|
895
|
-
exports.encodeSHA1 = encodeSHA1;
|
|
896
845
|
/**
|
|
897
846
|
* Parses the json input
|
|
898
847
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -909,17 +858,16 @@ exports.encodeSHA1 = encodeSHA1;
|
|
|
909
858
|
* @param {*} input
|
|
910
859
|
* @returns { any | null } returns null if input is null/undefined
|
|
911
860
|
*/
|
|
912
|
-
function parseJSON(input, _parentContext) {
|
|
861
|
+
export function parseJSON(input, _parentContext) {
|
|
913
862
|
if (ts.isNil(input))
|
|
914
863
|
return null;
|
|
915
|
-
if (
|
|
864
|
+
if (isArray(input)) {
|
|
916
865
|
return input
|
|
917
866
|
.filter(ts.isNotNil)
|
|
918
867
|
.map((data) => JSON.parse(data));
|
|
919
868
|
}
|
|
920
869
|
return JSON.parse(input);
|
|
921
870
|
}
|
|
922
|
-
exports.parseJSON = parseJSON;
|
|
923
871
|
/**
|
|
924
872
|
* Converts input to JSON
|
|
925
873
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -935,10 +883,10 @@ exports.parseJSON = parseJSON;
|
|
|
935
883
|
* @param {*} [{ pretty = false }={}] setting pretty to true will format the json output
|
|
936
884
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
937
885
|
*/
|
|
938
|
-
function toJSON(input, _parentContext, { pretty = false } = {}) {
|
|
886
|
+
export function toJSON(input, _parentContext, { pretty = false } = {}) {
|
|
939
887
|
if (ts.isNil(input))
|
|
940
888
|
return null;
|
|
941
|
-
if (
|
|
889
|
+
if (isArray(input)) {
|
|
942
890
|
return input
|
|
943
891
|
.filter(ts.isNotNil)
|
|
944
892
|
.map((data) => {
|
|
@@ -951,7 +899,6 @@ function toJSON(input, _parentContext, { pretty = false } = {}) {
|
|
|
951
899
|
return JSON.stringify(input, null, 2);
|
|
952
900
|
return JSON.stringify(input);
|
|
953
901
|
}
|
|
954
|
-
exports.toJSON = toJSON;
|
|
955
902
|
/**
|
|
956
903
|
* Converts the value into a geo-point
|
|
957
904
|
* if given an array it will convert everything in the array excluding null/undefined values
|
|
@@ -970,18 +917,17 @@ exports.toJSON = toJSON;
|
|
|
970
917
|
* @returns {{ lat: number, lon: number } | { lat: number, lon: number }[] | null }
|
|
971
918
|
* returns null if input is null/undefined
|
|
972
919
|
*/
|
|
973
|
-
function toGeoPoint(input, _parentContext) {
|
|
920
|
+
export function toGeoPoint(input, _parentContext) {
|
|
974
921
|
if (ts.isNil(input))
|
|
975
922
|
return null;
|
|
976
923
|
// a tuple of numbers is a form of geo-point, do not map it
|
|
977
|
-
if (
|
|
924
|
+
if (isArray(input) && !isNumberTuple(input)) {
|
|
978
925
|
return input
|
|
979
926
|
.filter(ts.isNotNil)
|
|
980
927
|
.map((data) => ts.parseGeoPoint(data, true));
|
|
981
928
|
}
|
|
982
929
|
return ts.parseGeoPoint(input, true);
|
|
983
930
|
}
|
|
984
|
-
exports.toGeoPoint = toGeoPoint;
|
|
985
931
|
/**
|
|
986
932
|
* Can extract values from a string input. You may either specify a regex, a jexl expression, or
|
|
987
933
|
* specify the start and end from which the extraction will take all values between
|
|
@@ -1019,8 +965,7 @@ exports.toGeoPoint = toGeoPoint;
|
|
|
1019
965
|
* results; // ['hello', 'world'];
|
|
1020
966
|
*/
|
|
1021
967
|
// this will be overritten by extract in jexl folder
|
|
1022
|
-
function extract(_input, _parentContext, _args) { }
|
|
1023
|
-
exports.extract = extract;
|
|
968
|
+
export function extract(_input, _parentContext, _args) { }
|
|
1024
969
|
/**
|
|
1025
970
|
* This function replaces chars in a string based off the regex value provided
|
|
1026
971
|
*
|
|
@@ -1046,7 +991,7 @@ exports.extract = extract;
|
|
|
1046
991
|
* }
|
|
1047
992
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1048
993
|
*/
|
|
1049
|
-
function replaceRegex(input, _parentContext, { regex, replace, ignoreCase, global }) {
|
|
994
|
+
export function replaceRegex(input, _parentContext, { regex, replace, ignoreCase, global }) {
|
|
1050
995
|
if (ts.isNil(input))
|
|
1051
996
|
return null;
|
|
1052
997
|
let options = '';
|
|
@@ -1054,20 +999,19 @@ function replaceRegex(input, _parentContext, { regex, replace, ignoreCase, globa
|
|
|
1054
999
|
options += 'i';
|
|
1055
1000
|
if (global)
|
|
1056
1001
|
options += 'g';
|
|
1057
|
-
if (
|
|
1002
|
+
if (isArray(input)) {
|
|
1058
1003
|
return input.filter(ts.isNotNil).map((data) => {
|
|
1059
|
-
if (!
|
|
1004
|
+
if (!isString(data))
|
|
1060
1005
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
1061
1006
|
const re = new RegExp(regex, options);
|
|
1062
1007
|
return data.replace(re, replace);
|
|
1063
1008
|
});
|
|
1064
1009
|
}
|
|
1065
|
-
if (!
|
|
1010
|
+
if (!isString(input))
|
|
1066
1011
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
1067
1012
|
const re = new RegExp(regex, options);
|
|
1068
1013
|
return input.replace(re, replace);
|
|
1069
1014
|
}
|
|
1070
|
-
exports.replaceRegex = replaceRegex;
|
|
1071
1015
|
/**
|
|
1072
1016
|
* This function replaces the searched value with the replace value
|
|
1073
1017
|
*
|
|
@@ -1086,17 +1030,17 @@ exports.replaceRegex = replaceRegex;
|
|
|
1086
1030
|
* search is the word that is to be changed to the value specified with the paramter replace
|
|
1087
1031
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1088
1032
|
*/
|
|
1089
|
-
function replaceLiteral(input, _parentContext, { search, replace }) {
|
|
1033
|
+
export function replaceLiteral(input, _parentContext, { search, replace }) {
|
|
1090
1034
|
if (ts.isNil(input))
|
|
1091
1035
|
return null;
|
|
1092
|
-
if (
|
|
1036
|
+
if (isArray(input)) {
|
|
1093
1037
|
return input.filter(ts.isNotNil).map((data) => {
|
|
1094
|
-
if (!
|
|
1038
|
+
if (!isString(data))
|
|
1095
1039
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(data)}`);
|
|
1096
1040
|
return data.replace(search, replace);
|
|
1097
1041
|
});
|
|
1098
1042
|
}
|
|
1099
|
-
if (!
|
|
1043
|
+
if (!isString(input))
|
|
1100
1044
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(input)}`);
|
|
1101
1045
|
try {
|
|
1102
1046
|
return input.replace(search, replace);
|
|
@@ -1105,7 +1049,6 @@ function replaceLiteral(input, _parentContext, { search, replace }) {
|
|
|
1105
1049
|
throw new Error(`Could not replace ${search} with ${replace}`);
|
|
1106
1050
|
}
|
|
1107
1051
|
}
|
|
1108
|
-
exports.replaceLiteral = replaceLiteral;
|
|
1109
1052
|
/**
|
|
1110
1053
|
* Converts a string to an array of characters split by the delimiter provided
|
|
1111
1054
|
*
|
|
@@ -1121,11 +1064,11 @@ exports.replaceLiteral = replaceLiteral;
|
|
|
1121
1064
|
* @param {{ delimiter: string }} [args] delimter defaults to an empty string
|
|
1122
1065
|
* @returns {(string[] | null)}
|
|
1123
1066
|
*/
|
|
1124
|
-
function splitString(input, _parentContext, args) {
|
|
1067
|
+
export function splitString(input, _parentContext, args) {
|
|
1125
1068
|
if (ts.isNil(input))
|
|
1126
1069
|
return null;
|
|
1127
1070
|
const delimiter = args ? args.delimiter : '';
|
|
1128
|
-
if (
|
|
1071
|
+
if (isArray(input)) {
|
|
1129
1072
|
return input.filter(ts.isNotNil).map((data) => {
|
|
1130
1073
|
if (!ts.isString(data)) {
|
|
1131
1074
|
throw new Error(`Input must be a string, or an array of string, received ${ts.getTypeOf(data)}`);
|
|
@@ -1138,7 +1081,6 @@ function splitString(input, _parentContext, args) {
|
|
|
1138
1081
|
}
|
|
1139
1082
|
throw new Error(`Input must be a string or an array, got ${ts.getTypeOf(input)}`);
|
|
1140
1083
|
}
|
|
1141
|
-
exports.splitString = splitString;
|
|
1142
1084
|
function _makeUnitTime(input, { ms = false } = {}) {
|
|
1143
1085
|
let time;
|
|
1144
1086
|
if (ms) {
|
|
@@ -1167,25 +1109,24 @@ function _makeUnitTime(input, { ms = false } = {}) {
|
|
|
1167
1109
|
* @param {*} [{ ms = false }={}] set ms to true if you want time in milliseconds
|
|
1168
1110
|
* @returns { number | number[] | null} returns null if input is null/undefined
|
|
1169
1111
|
*/
|
|
1170
|
-
function toUnixTime(input, _parentContext, { ms = false } = {}) {
|
|
1112
|
+
export function toUnixTime(input, _parentContext, { ms = false } = {}) {
|
|
1171
1113
|
if (ts.isNil(input))
|
|
1172
1114
|
return null;
|
|
1173
|
-
if (
|
|
1115
|
+
if (isArray(input)) {
|
|
1174
1116
|
return input.filter(ts.isNotNil).map((data) => {
|
|
1175
|
-
if (!
|
|
1117
|
+
if (!isValidDate(data)) {
|
|
1176
1118
|
throw new Error(`Not a valid date, cannot transform ${data} to unix time`);
|
|
1177
1119
|
}
|
|
1178
1120
|
return _makeUnitTime(data, { ms });
|
|
1179
1121
|
});
|
|
1180
1122
|
}
|
|
1181
|
-
if (!
|
|
1123
|
+
if (!isValidDate(input))
|
|
1182
1124
|
throw new Error(`Not a valid date, cannot transform ${input} to unix time`);
|
|
1183
1125
|
return _makeUnitTime(input, { ms });
|
|
1184
1126
|
}
|
|
1185
|
-
exports.toUnixTime = toUnixTime;
|
|
1186
1127
|
function _makeIso(input, args) {
|
|
1187
1128
|
let value = input;
|
|
1188
|
-
if (
|
|
1129
|
+
if (isNumber(input) && args && args.resolution)
|
|
1189
1130
|
value *= 1000;
|
|
1190
1131
|
return new Date(value).toISOString();
|
|
1191
1132
|
}
|
|
@@ -1207,38 +1148,37 @@ function _makeIso(input, args) {
|
|
|
1207
1148
|
* if input is a number, you may specify the resolution of that number, defaults to seconds
|
|
1208
1149
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1209
1150
|
*/
|
|
1210
|
-
function toISO8601(input, _parentContext, args) {
|
|
1151
|
+
export function toISO8601(input, _parentContext, args) {
|
|
1211
1152
|
if (ts.isNil(input))
|
|
1212
1153
|
return null;
|
|
1213
|
-
if (
|
|
1154
|
+
if (isArray(input)) {
|
|
1214
1155
|
return input
|
|
1215
1156
|
.filter(ts.isNotNil)
|
|
1216
1157
|
.map((data) => {
|
|
1217
|
-
if (!
|
|
1158
|
+
if (!isValidDate(data)) {
|
|
1218
1159
|
throw new Error(`Input is not valid date, received ${data}`);
|
|
1219
1160
|
}
|
|
1220
1161
|
return _makeIso(data, args);
|
|
1221
1162
|
});
|
|
1222
1163
|
}
|
|
1223
|
-
if (!
|
|
1164
|
+
if (!isValidDate(input)) {
|
|
1224
1165
|
throw new Error(`Input is not valid date, received ${input}`);
|
|
1225
1166
|
}
|
|
1226
1167
|
return _makeIso(input, args);
|
|
1227
1168
|
}
|
|
1228
|
-
exports.toISO8601 = toISO8601;
|
|
1229
1169
|
function _formatDate(input, args) {
|
|
1230
|
-
if (!
|
|
1170
|
+
if (!isValidDate(input)) {
|
|
1231
1171
|
throw new Error('Input is not valid date');
|
|
1232
1172
|
}
|
|
1233
1173
|
let value = input;
|
|
1234
1174
|
const { format, resolution } = args;
|
|
1235
|
-
if (!
|
|
1175
|
+
if (!isString(format))
|
|
1236
1176
|
throw new Error(`Invalid parameter format, must be a string, received ${ts.getTypeOf(input)}`);
|
|
1237
|
-
if (
|
|
1177
|
+
if (isString(value))
|
|
1238
1178
|
value = new Date(value);
|
|
1239
|
-
if (
|
|
1179
|
+
if (isNumber(value) && resolution === 'seconds')
|
|
1240
1180
|
value *= 1000;
|
|
1241
|
-
return (
|
|
1181
|
+
return dateFormat(value, format);
|
|
1242
1182
|
}
|
|
1243
1183
|
/**
|
|
1244
1184
|
* Function that will format a number or date string to a given date format provided
|
|
@@ -1265,25 +1205,24 @@ function _formatDate(input, args) {
|
|
|
1265
1205
|
* format is the shape that the date will be, resolution is only needed when input is a number
|
|
1266
1206
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1267
1207
|
*/
|
|
1268
|
-
function formatDate(input, _parentContext, args) {
|
|
1208
|
+
export function formatDate(input, _parentContext, args) {
|
|
1269
1209
|
if (ts.isNil(input))
|
|
1270
1210
|
return null;
|
|
1271
|
-
if (
|
|
1211
|
+
if (isArray(input)) {
|
|
1272
1212
|
return input
|
|
1273
1213
|
.filter(ts.isNotNil)
|
|
1274
1214
|
.map((data) => _formatDate(data, args));
|
|
1275
1215
|
}
|
|
1276
1216
|
return _formatDate(input, args);
|
|
1277
1217
|
}
|
|
1278
|
-
exports.formatDate = formatDate;
|
|
1279
1218
|
function _parseDate(input, args) {
|
|
1280
1219
|
if (ts.isNil(input))
|
|
1281
1220
|
return null;
|
|
1282
1221
|
const { format } = args;
|
|
1283
|
-
if (!
|
|
1222
|
+
if (!isString(format)) {
|
|
1284
1223
|
throw new Error(`Invalid parameter format, must be a string, received ${ts.getTypeOf(input)}`);
|
|
1285
1224
|
}
|
|
1286
|
-
const parsed =
|
|
1225
|
+
const parsed = parse(input, format, new Date());
|
|
1287
1226
|
if (!ts.isValidDateInstance(parsed)) {
|
|
1288
1227
|
throw new Error('Cannot parse date');
|
|
1289
1228
|
}
|
|
@@ -1313,17 +1252,16 @@ function _parseDate(input, args) {
|
|
|
1313
1252
|
* @param { format: string } args
|
|
1314
1253
|
* @returns { Date | Date[] | null } returns null if input is null/undefined
|
|
1315
1254
|
*/
|
|
1316
|
-
function parseDate(input, _parentContext, args) {
|
|
1255
|
+
export function parseDate(input, _parentContext, args) {
|
|
1317
1256
|
if (ts.isNil(input))
|
|
1318
1257
|
return null;
|
|
1319
|
-
if (
|
|
1258
|
+
if (isArray(input)) {
|
|
1320
1259
|
return input
|
|
1321
1260
|
.filter(ts.isNotNil)
|
|
1322
1261
|
.map((data) => _parseDate(data, args));
|
|
1323
1262
|
}
|
|
1324
1263
|
return _parseDate(input, args);
|
|
1325
1264
|
}
|
|
1326
|
-
exports.parseDate = parseDate;
|
|
1327
1265
|
/**
|
|
1328
1266
|
* Will convert a string, or an array of strings to camel case;
|
|
1329
1267
|
*
|
|
@@ -1338,14 +1276,13 @@ exports.parseDate = parseDate;
|
|
|
1338
1276
|
* @param {string | string[]} input
|
|
1339
1277
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1340
1278
|
*/
|
|
1341
|
-
function toCamelCase(input, _parentContext) {
|
|
1279
|
+
export function toCamelCase(input, _parentContext) {
|
|
1342
1280
|
if (ts.isNil(input))
|
|
1343
1281
|
return null;
|
|
1344
|
-
if (
|
|
1282
|
+
if (isArray(input))
|
|
1345
1283
|
return input.filter(ts.isNotNil).map(ts.toCamelCase);
|
|
1346
1284
|
return ts.toCamelCase(input);
|
|
1347
1285
|
}
|
|
1348
|
-
exports.toCamelCase = toCamelCase;
|
|
1349
1286
|
/**
|
|
1350
1287
|
* Will convert a string, or an array of strings to kebab case
|
|
1351
1288
|
* @example
|
|
@@ -1361,14 +1298,13 @@ exports.toCamelCase = toCamelCase;
|
|
|
1361
1298
|
* @param {string | string[]} input
|
|
1362
1299
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1363
1300
|
*/
|
|
1364
|
-
function toKebabCase(input, _parentContext) {
|
|
1301
|
+
export function toKebabCase(input, _parentContext) {
|
|
1365
1302
|
if (ts.isNil(input))
|
|
1366
1303
|
return null;
|
|
1367
|
-
if (
|
|
1304
|
+
if (isArray(input))
|
|
1368
1305
|
return input.filter(ts.isNotNil).map(ts.toKebabCase);
|
|
1369
1306
|
return ts.toKebabCase(input);
|
|
1370
1307
|
}
|
|
1371
|
-
exports.toKebabCase = toKebabCase;
|
|
1372
1308
|
/**
|
|
1373
1309
|
* Converts a string, or an array of strings to pascal case
|
|
1374
1310
|
*
|
|
@@ -1383,14 +1319,13 @@ exports.toKebabCase = toKebabCase;
|
|
|
1383
1319
|
* @param {string | string[]} input
|
|
1384
1320
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1385
1321
|
*/
|
|
1386
|
-
function toPascalCase(input, _parentContext) {
|
|
1322
|
+
export function toPascalCase(input, _parentContext) {
|
|
1387
1323
|
if (ts.isNil(input))
|
|
1388
1324
|
return null;
|
|
1389
|
-
if (
|
|
1325
|
+
if (isArray(input))
|
|
1390
1326
|
return input.filter(ts.isNotNil).map(ts.toPascalCase);
|
|
1391
1327
|
return ts.toPascalCase(input);
|
|
1392
1328
|
}
|
|
1393
|
-
exports.toPascalCase = toPascalCase;
|
|
1394
1329
|
/**
|
|
1395
1330
|
* Converts a string, or an array of strings to snake case
|
|
1396
1331
|
* @example
|
|
@@ -1404,14 +1339,13 @@ exports.toPascalCase = toPascalCase;
|
|
|
1404
1339
|
* @param {string | string[]} input
|
|
1405
1340
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1406
1341
|
*/
|
|
1407
|
-
function toSnakeCase(input, _parentContext) {
|
|
1342
|
+
export function toSnakeCase(input, _parentContext) {
|
|
1408
1343
|
if (ts.isNil(input))
|
|
1409
1344
|
return null;
|
|
1410
|
-
if (
|
|
1345
|
+
if (isArray(input))
|
|
1411
1346
|
return input.filter(ts.isNotNil).map(ts.toSnakeCase);
|
|
1412
1347
|
return ts.toSnakeCase(input);
|
|
1413
1348
|
}
|
|
1414
|
-
exports.toSnakeCase = toSnakeCase;
|
|
1415
1349
|
/**
|
|
1416
1350
|
* Converts a string, or an array of strings to title case
|
|
1417
1351
|
* @example
|
|
@@ -1422,12 +1356,11 @@ exports.toSnakeCase = toSnakeCase;
|
|
|
1422
1356
|
* @param {string | string[]} input
|
|
1423
1357
|
* @returns { string | string[] | null } returns null if input is null/undefined
|
|
1424
1358
|
*/
|
|
1425
|
-
function toTitleCase(input, _parentContext) {
|
|
1359
|
+
export function toTitleCase(input, _parentContext) {
|
|
1426
1360
|
if (ts.isNil(input))
|
|
1427
1361
|
return null;
|
|
1428
|
-
if (
|
|
1362
|
+
if (isArray(input))
|
|
1429
1363
|
return input.filter(ts.isNotNil).map(ts.toTitleCase);
|
|
1430
1364
|
return ts.toTitleCase(input);
|
|
1431
1365
|
}
|
|
1432
|
-
exports.toTitleCase = toTitleCase;
|
|
1433
1366
|
//# sourceMappingURL=field-transform.js.map
|