Why do we need separate “.swift” files for each class?

后端 未结 6 1218
刺人心
刺人心 2020-12-29 05:02

Wondering if you might be able to answer a very basic beginner question for me. I’m working through the Cocoa + Swift tutorial on Lynda and I’m a little confused about class

6条回答
  •  感情败类
    2020-12-29 05:27

    I also vote +1 to your question, and for the upper answers.

    As a newbie I really agree it is difficult to get the classes and inheritance concepts.

    But believe it is much better to handle code in separate documents, perhaps using MVC concept, rather than having this code in a single massive document.

    My own experience, it clears out the clouds of your code.

提交回复
热议问题