Returning Unmodifiable List When Using Getters

前端 未结 0 494
闹比i
闹比i 2020-12-11 17:23

I have a class with private fields and I\'m using getters to access those private fields:

List get events {
    return _events;
  }
相关标签:
回答
  • 消灭零回复
提交回复
热议问题