Should main method be only consists of object creations and method calls?
- by crucified soul
A friend of mine told me that, the best practice is class containing main method should be named Main and only contains main method. Also main method should only parse inputs, create other objects and call other methods. The Main class and main method shouldn't do anything else. Basically what he is saying that class containing main method should be like:
public class Main
{
public static void main(String[] args)
{
//parse inputs
//create other objects
//call methods
}
}
Is it the best practice?