Adds a main class