00001
00002 #if !defined(oagFpgaModRef_P)
00003 #define oagFpgaModRef_P
00004
00005 #include <stdlib.h>
00006
00007 #include "oaDesignDB.h"
00008 #include "oagFpgaRtlGraph.h"
00009
00010 namespace oagFpga {
00011
00012
00013
00014
00019
00020
00021
00022 class ModRef {
00023 public:
00024 ModRef() {
00025 ref = 0; module = NULL;
00026 }
00027 ModRef(const ModRef ©) {
00028 ref = copy.ref; module = copy.module;
00029 }
00030 ModRef(BBRef a, oa::oaModule *o) {
00031 ref = a; module = o;
00032 }
00033
00034 BBRef ref;
00035 oa::oaModule *module;
00036
00037 bool operator<(const ModRef &comp) const {
00044
00045 if (module != comp.module)
00046 return module<comp.module;
00047 else
00048 return ref<comp.ref;
00049 }
00050 bool operator==(const ModRef &comp) const {
00051 return module == comp.module && ref == comp.ref;
00052 }
00053 bool operator!=(const ModRef &comp) const {
00054 return module != comp.module || ref != comp.ref;
00055 }
00056
00057 void printName(bool lineFeed = true);
00058 void print(bool lineFeed = true);
00059 };
00060
00061 }
00062
00063 #endif