1. 概念的引入:
port是一个指针,它指向模块外部的channel。 sc_export<T>是一个指针,它指向其他模块内部的channel。
interface是一个抽象类(定义了一些纯虚函数),它也可被看成API,可派生出各个类。
2. 定义:
A SystemC interface is an abstract class that inherits from sc_interface and provides only pure virtual declarations of methods referenced by SystemC channels and ports. No implementations or data are provided in a SystemC interface.
SystemC interface 是个抽象类,它由sc_interface派生而来,仅仅声明了纯虚函数(这些纯虚函数会被channel以及port引用),而不含有任何数据成员。
A SystemC channel is a class that inherits from either sc_channel or from sc_prim_channel, and the channel should1 inherit and implement one or more SystemC interface classes. A channel implements all the pure virtual methods of the inherited interface classes.
SystemC channel 由sc_channel或sc_prim_channel派生而来,channel必须至少由一个interface派生而来,并