To actually use an interface, you need a pointer to it.
为了实际使用一个接口,你需要一个指向它的指针。
The mental model that people have about a particular task may make it easy or hard to use an interface that you have designed.
人们所拥有的关于特定任务的心智模型,可能会使你设计的界面对于他们好用或是不好用。
As the operations offered by the classes are the same, you can use an interface to define a contract that all of your classes implement.
由于这些类提供的操作相同,您可以使用一个接口来定义一个所有类实现的协定。
In some cases, they can use an interface where lines are drawn between boxes and documents to establish the relationships and rules that an application must follow.
在某些情况下,他们可以使用一个界面,在方框和文件之间划线来表示应用程序必须遵守的关系和规则。
When do you use an abstract class and when do you use an interface?
什么时候使用抽象类,什么时候使用接口?
To use an interface, you write a class that implements the interface.
要使用接口,只需写一个类实现接口即可。
Given these similarities, when should a class designer use a delegate and when should it use an interface?
既然存在这些相似性,那么类设计器何时应使用委托,何时又该使用接口呢?
Given these similarities, when should a class designer use a delegate and when should it use an interface?
既然存在这些相似性,那么类设计器何时应使用委托,何时又该使用接口呢?
应用推荐