different attempt to parse using collapsable text

ranges
This commit is contained in:
Dave Holoway
2020-05-23 13:20:51 +01:00
parent bdc5b1d4cd
commit 23dc6d3871
18 changed files with 1904 additions and 345 deletions

View File

@@ -86,14 +86,15 @@ class MTI extends MinifiableInfo {
* @param {string[]} modifiers
* @param {'class'|'enum'|'interface'|'@interface'} typeKind
* @param {string} name
* @param {string[]} typeVarNames
*/
addType(package_name, docs, modifiers, typeKind, name) {
addType(package_name, docs, modifiers, typeKind, name, typeVarNames) {
const t = {
d: docs,
p: this.addPackage(package_name),
m: getTypeMods(modifiers, typeKind),
n: name.replace(/\./g,'$'),
v: [],
v: typeVarNames.map(name => this.addRefType('', name)),
e: /interface/.test(typeKind) ? []
: typeKind === 'enum' ? this.addRefType('java.lang', 'Enum')
: this.addRefType('java.lang', 'Object'),
@@ -353,6 +354,11 @@ class MTITypeBase extends MinifiableInfo {
*/
get methods() { return [] }
/**
* @type {ReferencedType[]}
*/
get typevars() { return [] }
/**
* @param {string} name
*/