@openrewrite/rewrite 0.25.2 → 0.25.4
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/dist/src/java/remote/receiver.d.ts.map +1 -1
- package/dist/src/java/remote/receiver.js +10 -0
- package/dist/src/java/remote/receiver.js.map +1 -1
- package/dist/src/java/remote/sender.d.ts.map +1 -1
- package/dist/src/java/remote/sender.js +7 -0
- package/dist/src/java/remote/sender.js.map +1 -1
- package/dist/src/java/tree/support_types.d.ts +2 -1
- package/dist/src/java/tree/support_types.d.ts.map +1 -1
- package/dist/src/java/tree/support_types.js.map +1 -1
- package/dist/src/java/tree/tree.d.ts +39 -0
- package/dist/src/java/tree/tree.d.ts.map +1 -1
- package/dist/src/java/tree/tree.js +48 -2
- package/dist/src/java/tree/tree.js.map +1 -1
- package/dist/src/java/visitor.d.ts +2 -1
- package/dist/src/java/visitor.d.ts.map +1 -1
- package/dist/src/java/visitor.js +15 -0
- package/dist/src/java/visitor.js.map +1 -1
- package/dist/src/javascript/parser.d.ts +3 -3
- package/dist/src/javascript/parser.d.ts.map +1 -1
- package/dist/src/javascript/parser.js +56 -43
- package/dist/src/javascript/parser.js.map +1 -1
- package/dist/src/javascript/remote/receiver.js +17 -4
- package/dist/src/javascript/remote/receiver.js.map +1 -1
- package/dist/src/javascript/remote/sender.js +11 -1
- package/dist/src/javascript/remote/sender.js.map +1 -1
- package/dist/src/javascript/tree/support_types.d.ts +11 -10
- package/dist/src/javascript/tree/support_types.d.ts.map +1 -1
- package/dist/src/javascript/tree/support_types.js +9 -8
- package/dist/src/javascript/tree/support_types.js.map +1 -1
- package/dist/src/javascript/tree/tree.d.ts +41 -20
- package/dist/src/javascript/tree/tree.d.ts.map +1 -1
- package/dist/src/javascript/tree/tree.js +63 -22
- package/dist/src/javascript/tree/tree.js.map +1 -1
- package/dist/src/javascript/visitor.d.ts.map +1 -1
- package/dist/src/javascript/visitor.js +3 -1
- package/dist/src/javascript/visitor.js.map +1 -1
- package/package.json +1 -1
|
@@ -676,11 +676,12 @@ exports.ExpressionWithTypeArguments = ExpressionWithTypeArguments = ExpressionWi
|
|
|
676
676
|
(0, core_1.LstType)("org.openrewrite.javascript.tree.JS$ExpressionWithTypeArguments")
|
|
677
677
|
], ExpressionWithTypeArguments);
|
|
678
678
|
let FunctionType = FunctionType_1 = class FunctionType extends (0, support_types_1.JSMixin)(Object) {
|
|
679
|
-
constructor(id, prefix, markers, constructorType, typeParameters, parameters, arrow, returnType, _type) {
|
|
679
|
+
constructor(id, prefix, markers, modifiers, constructorType, typeParameters, parameters, arrow, returnType, _type) {
|
|
680
680
|
super();
|
|
681
681
|
this._id = id;
|
|
682
682
|
this._prefix = prefix;
|
|
683
683
|
this._markers = markers;
|
|
684
|
+
this._modifiers = modifiers;
|
|
684
685
|
this._constructorType = constructorType;
|
|
685
686
|
this._typeParameters = typeParameters;
|
|
686
687
|
this._parameters = parameters;
|
|
@@ -692,19 +693,25 @@ let FunctionType = FunctionType_1 = class FunctionType extends (0, support_types
|
|
|
692
693
|
return this._id;
|
|
693
694
|
}
|
|
694
695
|
withId(id) {
|
|
695
|
-
return id === this._id ? this : new FunctionType_1(id, this._prefix, this._markers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
696
|
+
return id === this._id ? this : new FunctionType_1(id, this._prefix, this._markers, this._modifiers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
696
697
|
}
|
|
697
698
|
get prefix() {
|
|
698
699
|
return this._prefix;
|
|
699
700
|
}
|
|
700
701
|
withPrefix(prefix) {
|
|
701
|
-
return prefix === this._prefix ? this : new FunctionType_1(this._id, prefix, this._markers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
702
|
+
return prefix === this._prefix ? this : new FunctionType_1(this._id, prefix, this._markers, this._modifiers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
702
703
|
}
|
|
703
704
|
get markers() {
|
|
704
705
|
return this._markers;
|
|
705
706
|
}
|
|
706
707
|
withMarkers(markers) {
|
|
707
|
-
return markers === this._markers ? this : new FunctionType_1(this._id, this._prefix, markers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
708
|
+
return markers === this._markers ? this : new FunctionType_1(this._id, this._prefix, markers, this._modifiers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
709
|
+
}
|
|
710
|
+
get modifiers() {
|
|
711
|
+
return this._modifiers;
|
|
712
|
+
}
|
|
713
|
+
withModifiers(modifiers) {
|
|
714
|
+
return modifiers === this._modifiers ? this : new FunctionType_1(this._id, this._prefix, this._markers, modifiers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
708
715
|
}
|
|
709
716
|
get constructorType() {
|
|
710
717
|
return this._constructorType.element;
|
|
@@ -716,7 +723,7 @@ let FunctionType = FunctionType_1 = class FunctionType extends (0, support_types
|
|
|
716
723
|
return this._typeParameters;
|
|
717
724
|
}
|
|
718
725
|
withTypeParameters(typeParameters) {
|
|
719
|
-
return typeParameters === this._typeParameters ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._constructorType, typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
726
|
+
return typeParameters === this._typeParameters ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._modifiers, this._constructorType, typeParameters, this._parameters, this._arrow, this._returnType, this._type);
|
|
720
727
|
}
|
|
721
728
|
get parameters() {
|
|
722
729
|
return this._parameters.elements;
|
|
@@ -728,19 +735,19 @@ let FunctionType = FunctionType_1 = class FunctionType extends (0, support_types
|
|
|
728
735
|
return this._arrow;
|
|
729
736
|
}
|
|
730
737
|
withArrow(arrow) {
|
|
731
|
-
return arrow === this._arrow ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._constructorType, this._typeParameters, this._parameters, arrow, this._returnType, this._type);
|
|
738
|
+
return arrow === this._arrow ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._modifiers, this._constructorType, this._typeParameters, this._parameters, arrow, this._returnType, this._type);
|
|
732
739
|
}
|
|
733
740
|
get returnType() {
|
|
734
741
|
return this._returnType;
|
|
735
742
|
}
|
|
736
743
|
withReturnType(returnType) {
|
|
737
|
-
return returnType === this._returnType ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._constructorType, this._typeParameters, this._parameters, this._arrow, returnType, this._type);
|
|
744
|
+
return returnType === this._returnType ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._modifiers, this._constructorType, this._typeParameters, this._parameters, this._arrow, returnType, this._type);
|
|
738
745
|
}
|
|
739
746
|
get type() {
|
|
740
747
|
return this._type;
|
|
741
748
|
}
|
|
742
749
|
withType(_type) {
|
|
743
|
-
return _type === this._type ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, _type);
|
|
750
|
+
return _type === this._type ? this : new FunctionType_1(this._id, this._prefix, this._markers, this._modifiers, this._constructorType, this._typeParameters, this._parameters, this._arrow, this._returnType, _type);
|
|
744
751
|
}
|
|
745
752
|
acceptJavaScript(v, p) {
|
|
746
753
|
return v.visitFunctionType(this, p);
|
|
@@ -752,13 +759,13 @@ let FunctionType = FunctionType_1 = class FunctionType extends (0, support_types
|
|
|
752
759
|
return t._constructorType;
|
|
753
760
|
}
|
|
754
761
|
withConstructorType(constructorType) {
|
|
755
|
-
return t._constructorType === constructorType ? t : new FunctionType_1(t._id, t._prefix, t._markers, constructorType, t._typeParameters, t._parameters, t._arrow, t._returnType, t._type);
|
|
762
|
+
return t._constructorType === constructorType ? t : new FunctionType_1(t._id, t._prefix, t._markers, t._modifiers, constructorType, t._typeParameters, t._parameters, t._arrow, t._returnType, t._type);
|
|
756
763
|
}
|
|
757
764
|
get parameters() {
|
|
758
765
|
return t._parameters;
|
|
759
766
|
}
|
|
760
767
|
withParameters(parameters) {
|
|
761
|
-
return t._parameters === parameters ? t : new FunctionType_1(t._id, t._prefix, t._markers, t._constructorType, t._typeParameters, parameters, t._arrow, t._returnType, t._type);
|
|
768
|
+
return t._parameters === parameters ? t : new FunctionType_1(t._id, t._prefix, t._markers, t._modifiers, t._constructorType, t._typeParameters, parameters, t._arrow, t._returnType, t._type);
|
|
762
769
|
}
|
|
763
770
|
};
|
|
764
771
|
}
|
|
@@ -1548,31 +1555,32 @@ exports.ObjectBindingDeclarations = ObjectBindingDeclarations = ObjectBindingDec
|
|
|
1548
1555
|
(0, core_1.LstType)("org.openrewrite.javascript.tree.JS$ObjectBindingDeclarations")
|
|
1549
1556
|
], ObjectBindingDeclarations);
|
|
1550
1557
|
let PropertyAssignment = PropertyAssignment_1 = class PropertyAssignment extends (0, support_types_1.JSMixin)(Object) {
|
|
1551
|
-
constructor(id, prefix, markers, name, initializer) {
|
|
1558
|
+
constructor(id, prefix, markers, name, assigmentToken, initializer) {
|
|
1552
1559
|
super();
|
|
1553
1560
|
this._id = id;
|
|
1554
1561
|
this._prefix = prefix;
|
|
1555
1562
|
this._markers = markers;
|
|
1556
1563
|
this._name = name;
|
|
1564
|
+
this._assigmentToken = assigmentToken;
|
|
1557
1565
|
this._initializer = initializer;
|
|
1558
1566
|
}
|
|
1559
1567
|
get id() {
|
|
1560
1568
|
return this._id;
|
|
1561
1569
|
}
|
|
1562
1570
|
withId(id) {
|
|
1563
|
-
return id === this._id ? this : new PropertyAssignment_1(id, this._prefix, this._markers, this._name, this._initializer);
|
|
1571
|
+
return id === this._id ? this : new PropertyAssignment_1(id, this._prefix, this._markers, this._name, this._assigmentToken, this._initializer);
|
|
1564
1572
|
}
|
|
1565
1573
|
get prefix() {
|
|
1566
1574
|
return this._prefix;
|
|
1567
1575
|
}
|
|
1568
1576
|
withPrefix(prefix) {
|
|
1569
|
-
return prefix === this._prefix ? this : new PropertyAssignment_1(this._id, prefix, this._markers, this._name, this._initializer);
|
|
1577
|
+
return prefix === this._prefix ? this : new PropertyAssignment_1(this._id, prefix, this._markers, this._name, this._assigmentToken, this._initializer);
|
|
1570
1578
|
}
|
|
1571
1579
|
get markers() {
|
|
1572
1580
|
return this._markers;
|
|
1573
1581
|
}
|
|
1574
1582
|
withMarkers(markers) {
|
|
1575
|
-
return markers === this._markers ? this : new PropertyAssignment_1(this._id, this._prefix, markers, this._name, this._initializer);
|
|
1583
|
+
return markers === this._markers ? this : new PropertyAssignment_1(this._id, this._prefix, markers, this._name, this._assigmentToken, this._initializer);
|
|
1576
1584
|
}
|
|
1577
1585
|
get name() {
|
|
1578
1586
|
return this._name.element;
|
|
@@ -1580,11 +1588,17 @@ let PropertyAssignment = PropertyAssignment_1 = class PropertyAssignment extends
|
|
|
1580
1588
|
withName(name) {
|
|
1581
1589
|
return this.padding.withName(this._name.withElement(name));
|
|
1582
1590
|
}
|
|
1591
|
+
get assigmentToken() {
|
|
1592
|
+
return this._assigmentToken;
|
|
1593
|
+
}
|
|
1594
|
+
withAssigmentToken(assigmentToken) {
|
|
1595
|
+
return assigmentToken === this._assigmentToken ? this : new PropertyAssignment_1(this._id, this._prefix, this._markers, this._name, assigmentToken, this._initializer);
|
|
1596
|
+
}
|
|
1583
1597
|
get initializer() {
|
|
1584
1598
|
return this._initializer;
|
|
1585
1599
|
}
|
|
1586
1600
|
withInitializer(initializer) {
|
|
1587
|
-
return initializer === this._initializer ? this : new PropertyAssignment_1(this._id, this._prefix, this._markers, this._name, initializer);
|
|
1601
|
+
return initializer === this._initializer ? this : new PropertyAssignment_1(this._id, this._prefix, this._markers, this._name, this._assigmentToken, initializer);
|
|
1588
1602
|
}
|
|
1589
1603
|
acceptJavaScript(v, p) {
|
|
1590
1604
|
return v.visitPropertyAssignment(this, p);
|
|
@@ -1602,7 +1616,7 @@ let PropertyAssignment = PropertyAssignment_1 = class PropertyAssignment extends
|
|
|
1602
1616
|
return t._name;
|
|
1603
1617
|
}
|
|
1604
1618
|
withName(name) {
|
|
1605
|
-
return t._name === name ? t : new PropertyAssignment_1(t._id, t._prefix, t._markers, name, t._initializer);
|
|
1619
|
+
return t._name === name ? t : new PropertyAssignment_1(t._id, t._prefix, t._markers, name, t._assigmentToken, t._initializer);
|
|
1606
1620
|
}
|
|
1607
1621
|
};
|
|
1608
1622
|
}
|
|
@@ -1611,6 +1625,14 @@ exports.PropertyAssignment = PropertyAssignment;
|
|
|
1611
1625
|
exports.PropertyAssignment = PropertyAssignment = PropertyAssignment_1 = __decorate([
|
|
1612
1626
|
(0, core_1.LstType)("org.openrewrite.javascript.tree.JS$PropertyAssignment")
|
|
1613
1627
|
], PropertyAssignment);
|
|
1628
|
+
(function (PropertyAssignment) {
|
|
1629
|
+
let AssigmentToken;
|
|
1630
|
+
(function (AssigmentToken) {
|
|
1631
|
+
AssigmentToken[AssigmentToken["Colon"] = 0] = "Colon";
|
|
1632
|
+
AssigmentToken[AssigmentToken["Equals"] = 1] = "Equals";
|
|
1633
|
+
AssigmentToken[AssigmentToken["Empty"] = 2] = "Empty";
|
|
1634
|
+
})(AssigmentToken = PropertyAssignment.AssigmentToken || (PropertyAssignment.AssigmentToken = {}));
|
|
1635
|
+
})(PropertyAssignment || (exports.PropertyAssignment = PropertyAssignment = {}));
|
|
1614
1636
|
let SatisfiesExpression = SatisfiesExpression_1 = class SatisfiesExpression extends (0, support_types_1.JSMixin)(Object) {
|
|
1615
1637
|
constructor(id, prefix, markers, expression, satisfiesType, _type) {
|
|
1616
1638
|
super();
|
|
@@ -2138,47 +2160,65 @@ exports.TypeOf = TypeOf = TypeOf_1 = __decorate([
|
|
|
2138
2160
|
(0, core_1.LstType)("org.openrewrite.javascript.tree.JS$TypeOf")
|
|
2139
2161
|
], TypeOf);
|
|
2140
2162
|
let TypeQuery = TypeQuery_1 = class TypeQuery extends (0, support_types_1.JSMixin)(Object) {
|
|
2141
|
-
constructor(id, prefix, markers, typeExpression, _type) {
|
|
2163
|
+
constructor(id, prefix, markers, typeExpression, typeArguments, _type) {
|
|
2142
2164
|
super();
|
|
2143
2165
|
this._id = id;
|
|
2144
2166
|
this._prefix = prefix;
|
|
2145
2167
|
this._markers = markers;
|
|
2146
2168
|
this._typeExpression = typeExpression;
|
|
2169
|
+
this._typeArguments = typeArguments;
|
|
2147
2170
|
this._type = _type;
|
|
2148
2171
|
}
|
|
2149
2172
|
get id() {
|
|
2150
2173
|
return this._id;
|
|
2151
2174
|
}
|
|
2152
2175
|
withId(id) {
|
|
2153
|
-
return id === this._id ? this : new TypeQuery_1(id, this._prefix, this._markers, this._typeExpression, this._type);
|
|
2176
|
+
return id === this._id ? this : new TypeQuery_1(id, this._prefix, this._markers, this._typeExpression, this._typeArguments, this._type);
|
|
2154
2177
|
}
|
|
2155
2178
|
get prefix() {
|
|
2156
2179
|
return this._prefix;
|
|
2157
2180
|
}
|
|
2158
2181
|
withPrefix(prefix) {
|
|
2159
|
-
return prefix === this._prefix ? this : new TypeQuery_1(this._id, prefix, this._markers, this._typeExpression, this._type);
|
|
2182
|
+
return prefix === this._prefix ? this : new TypeQuery_1(this._id, prefix, this._markers, this._typeExpression, this._typeArguments, this._type);
|
|
2160
2183
|
}
|
|
2161
2184
|
get markers() {
|
|
2162
2185
|
return this._markers;
|
|
2163
2186
|
}
|
|
2164
2187
|
withMarkers(markers) {
|
|
2165
|
-
return markers === this._markers ? this : new TypeQuery_1(this._id, this._prefix, markers, this._typeExpression, this._type);
|
|
2188
|
+
return markers === this._markers ? this : new TypeQuery_1(this._id, this._prefix, markers, this._typeExpression, this._typeArguments, this._type);
|
|
2166
2189
|
}
|
|
2167
2190
|
get typeExpression() {
|
|
2168
2191
|
return this._typeExpression;
|
|
2169
2192
|
}
|
|
2170
2193
|
withTypeExpression(typeExpression) {
|
|
2171
|
-
return typeExpression === this._typeExpression ? this : new TypeQuery_1(this._id, this._prefix, this._markers, typeExpression, this._type);
|
|
2194
|
+
return typeExpression === this._typeExpression ? this : new TypeQuery_1(this._id, this._prefix, this._markers, typeExpression, this._typeArguments, this._type);
|
|
2195
|
+
}
|
|
2196
|
+
get typeArguments() {
|
|
2197
|
+
return this._typeArguments === null ? null : this._typeArguments.elements;
|
|
2198
|
+
}
|
|
2199
|
+
withTypeArguments(typeArguments) {
|
|
2200
|
+
return this.padding.withTypeArguments(tree_1.JContainer.withElementsNullable(this._typeArguments, typeArguments));
|
|
2172
2201
|
}
|
|
2173
2202
|
get type() {
|
|
2174
2203
|
return this._type;
|
|
2175
2204
|
}
|
|
2176
2205
|
withType(_type) {
|
|
2177
|
-
return _type === this._type ? this : new TypeQuery_1(this._id, this._prefix, this._markers, this._typeExpression, _type);
|
|
2206
|
+
return _type === this._type ? this : new TypeQuery_1(this._id, this._prefix, this._markers, this._typeExpression, this._typeArguments, _type);
|
|
2178
2207
|
}
|
|
2179
2208
|
acceptJavaScript(v, p) {
|
|
2180
2209
|
return v.visitTypeQuery(this, p);
|
|
2181
2210
|
}
|
|
2211
|
+
get padding() {
|
|
2212
|
+
const t = this;
|
|
2213
|
+
return new class {
|
|
2214
|
+
get typeArguments() {
|
|
2215
|
+
return t._typeArguments;
|
|
2216
|
+
}
|
|
2217
|
+
withTypeArguments(typeArguments) {
|
|
2218
|
+
return t._typeArguments === typeArguments ? t : new TypeQuery_1(t._id, t._prefix, t._markers, t._typeExpression, typeArguments, t._type);
|
|
2219
|
+
}
|
|
2220
|
+
};
|
|
2221
|
+
}
|
|
2182
2222
|
};
|
|
2183
2223
|
exports.TypeQuery = TypeQuery;
|
|
2184
2224
|
exports.TypeQuery = TypeQuery = TypeQuery_1 = __decorate([
|
|
@@ -3262,6 +3302,7 @@ exports.NamespaceDeclaration = NamespaceDeclaration = NamespaceDeclaration_1 = _
|
|
|
3262
3302
|
(function (KeywordType) {
|
|
3263
3303
|
KeywordType[KeywordType["Namespace"] = 0] = "Namespace";
|
|
3264
3304
|
KeywordType[KeywordType["Module"] = 1] = "Module";
|
|
3305
|
+
KeywordType[KeywordType["Empty"] = 2] = "Empty";
|
|
3265
3306
|
})(KeywordType = NamespaceDeclaration.KeywordType || (NamespaceDeclaration.KeywordType = {}));
|
|
3266
3307
|
})(NamespaceDeclaration || (exports.NamespaceDeclaration = NamespaceDeclaration = {}));
|
|
3267
3308
|
let FunctionDeclaration = FunctionDeclaration_1 = class FunctionDeclaration extends (0, support_types_1.JSMixin)(Object) {
|