创建完美的应用程序设计 [英] create perfect oops design for application

查看:75
本文介绍了创建完美的应用程序设计的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我想提高我的OOPS技能.请为我提供一些与此相关的链接.

说我有一个产品作为实体.现在,可以由用户在UI中插入,编辑或删除它.用户还可以进一步配置该产品.

那么什么是理想的班级设计呢?

谢谢

Hi,

I want to improve my OOPS skills. Please guide me some links regarding that.

Say I have a product as entity. Now this can be inserted, edited or deleted by user in UI. User can further configure this product also.

So what can be ideal class design for that?

Thanks

推荐答案

您的问题含糊,毫无意义,并表明您对该主题缺乏知识.
但是,网络上有许多有用的资源可以帮助您更好地了解编程和OOP.
我假设您了解编程的基础知识.创建变量,分配值,创建类,方法,函数等.
因此,OOP并不容易,也不容易解释.我建议您开始对此主题进行一些阅读.
首先,您必须了解面向对象编程 [封装 [继承 [ ^ ]和多态 [ 之后,您距离那里还很远. SOLID原则 [设计模式 [
Your question is vague, makes little sense and shows your lack of knowledge on the subject.
However, there are many useful resources on the web that can help you to better understand programming and OOP.
I am assuming you know the basics of programming. Creating variables, assigning values, creating class, methods, functions etc.
So OOP is not easy, nor easy to explain. I suggest you start doing some reading on the subject.
First, you must understand Object Oriented Programming[^]. Make sure you get Encapsulation[^], Inheritance[^] and Polymorphism[^]. They are the ''three pillars of OOP''.
After that you are far from there yet. The SOLID principles[^] are key to building robust and re-usable software.
When you get all of these principles you may start reading up on Design Patterns[^].

Once you''ve read that you''re probably well on your way. Don''t forget to practice, practice, practice!
Hope it helps and good luck! :)


首先,您需要使用Add,Insert,Update和Delete方法定义接口.
然后,您所有不同的产品类型都可以实现.

您还可以创建一个名为Product的抽象类,并使所有不同的产品类型继承该产品类.

OOPS就是要考虑真实对象的所有方面,并应用OOPS原理,以便我们可以以提高可重用性和可维护性的方式进行编码.
下面的链接是关于OOPS的好文章. HeadFirst C#也是理解OOPS的好书.
面向对象编程概念(OOP)以及更多内容的介绍 [ ^ ]

您还可以在同一页面上查看Shivprasad Koirala(MVP)编译良好的视频.
First you need to define Interface with Add,Insert,Update and Delete Method.
All your different Product type can then implement that.

You can also create a abstract class called Product and have all your different product type inheriting the product class.

OOPS is just about thinking everything in terms of real object and applying the OOPS principle so that we can code in such a way that we can increase reusability and maintainability.
Below link is good article on OOPS. HeadFirst C# also is good book for understanding OOPS.
Introduction to Object Oriented Programming Concepts (OOP) and More[^]

You can also check Shivprasad Koirala''s (MVP) nicely compiled videos on the same.


我们无法回答.
这是一个非常广泛的主题-答案是一本书,而不是TextBox!
We can''t answer that.
It''s far, far too broad a subject - the answer is a book, not a TextBox!


这篇关于创建完美的应用程序设计的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆