Skip to content

Commit

Permalink
chore(java): remove unused deprecated methods from JvmGraph (#5302)
Browse files Browse the repository at this point in the history
  • Loading branch information
justbuchanan committed Jun 9, 2022
1 parent 30b4d98 commit f557a10
Showing 1 changed file with 0 additions and 72 deletions.
72 changes: 0 additions & 72 deletions kythe/java/com/google/devtools/kythe/analyzers/jvm/JvmGraph.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,6 @@ public KytheEntrySets getKytheEntrySets() {
return entrySets;
}

/** Returns the {@link VName} corresponding to the given class/enum/interface type. */
@Deprecated
public static VName getReferenceVName(Type.ReferenceType referenceType) {
return getReferenceVName(CorpusPath.EMPTY, referenceType);
}

/** Returns the {@link VName} corresponding to the given class/enum/interface type. */
public static VName getReferenceVName(CorpusPath corpusPath, Type.ReferenceType referenceType) {
return corpusPath
Expand Down Expand Up @@ -90,21 +84,6 @@ public static VName getMethodVName(
.build();
}

/**
* Returns the {@link VName} corresponding to the given parameter of a method type.
*
* <p>Parameter indices are used because names are only optionally retained in class files and not
* required by the spec.
*/
@Deprecated
public static VName getParameterVName(
Type.ReferenceType parentClass,
String methodName,
Type.MethodType methodType,
int parameterIndex) {
return getParameterVName(CorpusPath.EMPTY, parentClass, methodName, methodType, parameterIndex);
}

/**
* Returns the {@link VName} corresponding to the given parameter of a method type.
*
Expand All @@ -124,12 +103,6 @@ public static VName getParameterVName(
.build();
}

/** Returns the {@link VName} corresponding to the given field type. */
@Deprecated
public static VName getFieldVName(Type.ReferenceType parentClass, String name) {
return getFieldVName(CorpusPath.EMPTY, parentClass, name);
}

/** Returns the {@link VName} corresponding to the given field type. */
public static VName getFieldVName(
CorpusPath corpusPath, Type.ReferenceType parentClass, String name) {
Expand All @@ -153,59 +126,29 @@ private static String parameterSignature(
return methodSignature(parentClass, methodName, methodType) + ".param" + parameterIndex;
}

/** Emits and returns a Kythe {@code record} node for a JVM class. */
@Deprecated
public VName emitClassNode(Type.ReferenceType refType) {
return emitClassNode(CorpusPath.EMPTY, refType);
}

/** Emits and returns a Kythe {@code record} node for a JVM class. */
public VName emitClassNode(CorpusPath corpusPath, Type.ReferenceType refType) {
return emitNode(
NodeKind.RECORD_CLASS, getReferenceVName(corpusPath, refType), markedSource(refType));
}

/** Emits and returns a Kythe {@code interface} node for a JVM interface. */
@Deprecated
public VName emitInterfaceNode(Type.ReferenceType refType) {
return emitInterfaceNode(CorpusPath.EMPTY, refType);
}
/** Emits and returns a Kythe {@code interface} node for a JVM interface. */
public VName emitInterfaceNode(CorpusPath corpusPath, Type.ReferenceType refType) {
return emitNode(
NodeKind.INTERFACE, getReferenceVName(corpusPath, refType), markedSource(refType));
}

/** Emits and returns a Kythe {@code sum} node for a JVM enum class. */
@Deprecated
public VName emitEnumNode(Type.ReferenceType refType) {
return emitEnumNode(CorpusPath.EMPTY, refType);
}

/** Emits and returns a Kythe {@code sum} node for a JVM enum class. */
public VName emitEnumNode(CorpusPath corpusPath, Type.ReferenceType refType) {
return emitNode(
NodeKind.SUM_ENUM_CLASS, getReferenceVName(corpusPath, refType), markedSource(refType));
}

/** Emits and returns a Kythe {@code variable} node for a JVM field. */
@Deprecated
public VName emitFieldNode(Type.ReferenceType parentClass, String name) {
return emitFieldNode(CorpusPath.EMPTY, parentClass, name);
}

/** Emits and returns a Kythe {@code variable} node for a JVM field. */
public VName emitFieldNode(CorpusPath corpusPath, Type.ReferenceType parentClass, String name) {
return emitNode(NodeKind.VARIABLE_FIELD, getFieldVName(corpusPath, parentClass, name));
}

/** Emits and returns a Kythe {@code function} node for a JVM method. */
@Deprecated
public VName emitMethodNode(
Type.ReferenceType parentClass, String methodName, Type.MethodType type) {
return emitMethodNode(CorpusPath.EMPTY, parentClass, methodName, type);
}

/** Emits and returns a Kythe {@code function} node for a JVM method. */
public VName emitMethodNode(
CorpusPath corpusPath,
Expand All @@ -217,21 +160,6 @@ public VName emitMethodNode(
getMethodVName(corpusPath, parentClass, methodName, type));
}

/**
* Emits and returns a Kythe {@code variable/local/parameter} node for a JVM parameter to a
* method.
*
* @see #getParameterVName(Type.ReferenceType, String, Type.MethodType, int)
*/
@Deprecated
public VName emitParameterNode(
Type.ReferenceType parentClass,
String methodName,
Type.MethodType methodType,
int parameterIndex) {
return emitParameterNode(CorpusPath.EMPTY, parentClass, methodName, methodType, parameterIndex);
}

/**
* Emits and returns a Kythe {@code variable/local/parameter} node for a JVM parameter to a
* method.
Expand Down

0 comments on commit f557a10

Please sign in to comment.