skylot/jadx · error · JadxRuntimeException

Not implemented

Error message

Not implemented

What it means

UsageData implements IUsageInfoVisitor-based traversal, but the visitUsageData method is not yet implemented — it unconditionally throws JadxRuntimeException. This is a stub indicating the feature (bulk usage data export/visitation) is planned but incomplete.

Source

Thrown at jadx-gui/src/main/java/jadx/gui/cache/usage/UsageData.java:80

			if (mthUsageData != null) {
				mth.setUseIn(resolveMthList(mthUsageData.getUsage()));
				mth.setUsed(resolveMthList(mthUsageData.getUses()));
				mth.setUnresolvedUsed(resolveMthInfoList(mthUsageData.getUnresolvedUsage()));
				mth.setCallsSelf(mthUsageData.callsSelf());
			}
		}
		Map<String, FldUsageData> fldUsage = clsUsageData.getFldUsage();
		for (FieldNode fld : cls.getFields()) {
			FldUsageData fldUsageData = fldUsage.get(fld.getFieldInfo().getShortId());
			if (fldUsageData != null) {
				fld.setUseIn(resolveMthList(fldUsageData.getUsage()));
			}
		}
	}

	@Override
	public void visitUsageData(IUsageInfoVisitor visitor) {
		throw new JadxRuntimeException("Not implemented");
	}

	private List<ClassNode> resolveClsList(List<String> clsList) {
		return Utils.collectionMap(clsList, root::resolveRawClass);
	}

	private List<MethodNode> resolveMthList(List<MthRef> mthRefList) {
		return Utils.collectionMap(mthRefList, m -> root.resolveDirectMethod(m.getCls(), m.getShortId()));
	}

	private List<MethodInfo> resolveMthInfoList(List<IMethodRef> mthRefList) {
		return Utils.collectionMap(mthRefList, m -> MethodInfo.fromRef(root, m));
	}
}

View on GitHub (pinned to e738a26571)

Solutions

  1. Do not call visitUsageData — use the per-class/per-field usage accessors instead (which are implemented)
  2. Check the jadx changelog or source for when this method gets implemented
  3. File a feature request if you need bulk usage export
  4. Use the individual getUsage methods on ClassNode/MethodNode/FieldNode as an alternative

Example fix

// Instead of bulk visitation, iterate classes individually:
for (JavaClass cls : decompiler.getClasses()) {
    ClassNode cn = cls.getClassNode();
    // use cn.getUseIn(), cn.getMethods(), etc. — these are implemented
}
// Avoid: usageData.visitUsageData(visitor); // throws "Not implemented"
Defensive patterns

Strategy: validation

Validate before calling

// Avoid calling the unimplemented method
// if (usageData instanceof UsageData) { /* visitUsageData throws */ }

Type guard

// Check before calling — no working implementation exists:
// Use reflection or version check to avoid calling visitUsageData on stubs.
// Simpler: never call it; use per-class accessors instead.

Try / catch

try {
    usageData.visitUsageData(visitor);
} catch (JadxRuntimeException e) {
    if (e.getMessage().equals("Not implemented")) {
        LOG.warn("visitUsageData not supported in this version");
        // fall back to per-class iteration
    }
}

Prevention

When it happens

Trigger: Any code that obtains a UsageData instance and calls visitUsageData(visitor) will immediately throw, regardless of input. This method is part of an interface contract but has no working implementation in the current version.

Common situations: A plugin, script, or tool tries to programmatically enumerate all usage data at once. Code was written against the interface without checking implementation status. Using an older or development build where this was left as a TODO.

Related errors


AI-assisted analysis of skylot/jadx@e738a26571 (2026-08-14). Data as JSON: /api/errors/30f6c6627006124d. Report an issue: GitHub.