23 std::cout <<
"Creating a component: \"ConsoleIn\"....";
25 std::cout <<
"succeed." << std::endl;
27 RTC::ComponentProfile_var prof;
29 std::cout <<
"=================================================" << std::endl;
30 std::cout <<
" Component Profile" << std::endl;
31 std::cout <<
"-------------------------------------------------" << std::endl;
32 std::cout <<
"InstanceID: " << prof->instance_name << std::endl;
33 std::cout <<
"Implementation: " << prof->type_name << std::endl;
34 std::cout <<
"Description: " << prof->description << std::endl;
35 std::cout <<
"Version: " << prof->version << std::endl;
36 std::cout <<
"Maker: " << prof->vendor << std::endl;
37 std::cout <<
"Category: " << prof->category << std::endl;
38 std::cout <<
" Other properties " << std::endl;
40 std::cout <<
"=================================================" << std::endl;
45 for (CORBA::ULong i(0), n(portlist->length()); i < n; ++i)
48 port = (*portlist)[i];
49 std::cout <<
"=================================================" 51 std::cout <<
"Port" << i <<
" (name): ";
52 std::cout << port->get_port_profile()->name << std::endl;
53 std::cout <<
"-------------------------------------------------" 56 iflist = port->get_port_profile()->interfaces;
58 for (CORBA::ULong i(0), n(iflist.length()); i < n; ++i)
60 std::cout <<
"I/F name: ";
61 std::cout << iflist[i].instance_name << std::endl;
62 std::cout <<
"I/F type: ";
63 std::cout << iflist[i].type_name << std::endl;
65 pol = iflist[i].polarity == 0 ?
"PROVIDED" :
"REQUIRED";
66 std::cout <<
"Polarity: " << pol << std::endl;
68 std::cout <<
"- properties -" << std::endl;
70 std::cout <<
"-------------------------------------------------" << std::endl;
77 int main (
int argc,
char** argv)
RTObject_impl * createComponent(const char *comp_args)
Create RT-Components.
virtual ComponentProfile * get_component_profile()
[RTObject CORBA interface] Get RTC's profile
void runManager(bool no_block=false)
Run the Manager.
virtual PortServiceList * get_ports()
[RTObject CORBA interface] Get Ports
int main(int argc, char **argv)
RTComponent manager class.
std::vector< PortInterfaceProfile * > PortInterfaceProfileList
void ConsoleInInit(RTC::Manager *manager)
static Manager * init(int argc, char **argv)
Initialize manager.
NameValue and NVList utility functions.
void dump(const SDOPackage::NVList &nv)
Print information configured in NVList as a string type to Standard Outport.
bool activateManager()
Activate the Manager.
std::vector< IPortService * > PortServiceList
void setModuleInitProc(ModuleInitProc proc)
Set initial procedure.
void MyModuleInit(RTC::Manager *manager)