- Class (static) variables: First the public class variables, then the protected, and then the private.
- Instance variables: First public, then protected, and then private.
- Constructors
- Methods: These methods should be grouped by functionality rather than by scope or accessibility. For example, a private class method can be in between two public instance methods. The goal is to make reading and understanding the code easier.
суббота, 24 сентября 2016 г.
Are there any Java method ordering conventions?
Подписаться на:
Комментарии к сообщению (Atom)
Комментариев нет:
Отправить комментарий