Skip to content

Semantic highlight of static method is that of category method #512

@eric-milles

Description

@eric-milles

Main.groovy

static void setThreadLocalProperty(String key, Object val) { Class target = null // redacted
  def setter = Reflections.findMethod('setThreadLocalProperty', target, String, Object)
  Reflections.invokeMethod(setter, target, key, val) // semantic highlights as DGM
}

Reflections.groovy

import java.lang.reflect.*
class Reflections {
  static Method findMethod(String methodName, Class<?> targetClass, Class<?>... paramTypes) {
  }
  static Object invokeMethod(Method method, Object target, Object... params) {
  }
}

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions