官术网_书友最值得收藏!

Summary

In this chapter, you learned how to recognize real-world elements and translate them into the different components of the object-oriented paradigm supported in Swift: classes, protocols, properties, methods, and instances. You understood that the classes represent blueprints or templates to generate the objects, also known as instances.

We designed a few classes with properties and methods that represent blueprints for real-life objects. Then, we improved the initial design by taking advantage of the power of abstraction and specialized different classes. We generated many versions of the initial UML diagram as we added superclasses and subclasses. Finally, we wrote some code in the Swift Playground to understand how we can interact with API objects.

Now that you have learned some of the basics of the object-oriented paradigm, we are ready to start creating classes and instances in Swift, which is the topic of the next chapter.

主站蜘蛛池模板: 巴塘县| 阿勒泰市| 泌阳县| 泽库县| 普兰店市| 嘉祥县| 天长市| 邯郸市| 平罗县| 仲巴县| 遵义县| 高密市| 玉环县| 哈巴河县| 江门市| 裕民县| 横峰县| 竹北市| 宜兴市| 离岛区| 陵川县| 瑞金市| 商南县| 枣庄市| 瑞丽市| 武川县| 寻乌县| 景洪市| 天全县| 福清市| 夏津县| 班玛县| 霍山县| 商丘市| 永寿县| 芷江| 庆阳市| 河北省| 孝义市| 都兰县| 筠连县|