Jump to content

Traversing a custom object


sumit_tuwien

Recommended Posts

Hello All,

For a class

class mClass final
   :   public sc_core::sc_module
{


public :

   sc_core::sc_in < T >  thisInp ;

};

 

I can use sc_core::sc_find_object("AllesKlar") to do a hierarchy traversing and can find out thisInp.

How easy or how difficult to use sc_core::sc_find_object("AllesKlar") to find a custom defined class like as follows:

 

class allesGute ;

class mClass final
   :   public sc_core::sc_module
{


public :

   allesGute < T >  thisGute ;

};

 

How do I register my custom object with systemc kernel ?

 

Regards,

Sumit

Link to comment
Share on other sites

Hello @sumit_tuwien,

Is the allesGute template class derived from sc_object? If yes, then it will be straightforward to find object using sc_find_object.

While instantiating the allesGute object you would be providing the name (object name during construction), which will be registered with the SystemC kernel at the right hierarchical level.

Hope this helps.

Regards,

Ameya Vikram Singh

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...