How to define an enum with zero or more Runnables operating on implementations of a common interface?

后端 未结 0 1192
臣服心动
臣服心动 2020-12-11 17:24

I have something like the below code (simplified as much as possible), which compiles:

class Test {

  enum TestEnum {
    ELEMENT1(Test::methodUsingTestclass         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题