本文整理汇总了C++中ekiga::ServiceCore类的典型用法代码示例。如果您正苦于以下问题:C++ ServiceCore类的具体用法?C++ ServiceCore怎么用?C++ ServiceCore使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了ServiceCore类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
boost::shared_ptr<Ekiga::CallCore> call_core = core.get<Ekiga::CallCore> ("call-core");
boost::shared_ptr<Ekiga::PersonalDetails> details = core.get<Ekiga::PersonalDetails> ("personal-details");
if (presence_core && call_core && details) {
boost::shared_ptr<Avahi::PresencePublisher> publisher (new Avahi::PresencePublisher (core, *details, *call_core));
if (core.add (publisher)) {
presence_core->add_presence_publisher (publisher);
result = true;
}
boost::shared_ptr<Avahi::Cluster> cluster = Avahi::Cluster::create (core);
if (core.add (cluster)) {
presence_core->add_cluster (cluster);
result = true;
}
}
return result;
}
开发者ID:GNOME,项目名称:ekiga,代码行数:26,代码来源:avahi-main.cpp
示例2:
bool
local_roster_bridge_init (Ekiga::ServiceCore &core,
int * /*argc*/,
char ** /*argv*/[])
{
bool result = false;
Ekiga::ContactCore *contact_core = NULL;
Local::Cluster *cluster = NULL;
Local::ContactDecorator *decorator = NULL;
contact_core
= dynamic_cast<Ekiga::ContactCore*>(core.get ("contact-core"));
cluster
= dynamic_cast<Local::Cluster*>(core.get ("local-cluster"));
if (cluster != NULL && contact_core != NULL) {
decorator = new Local::ContactDecorator (*cluster);
core.add (*decorator);
contact_core->add_contact_decorator (*decorator);
result = true;
}
return result;
}
开发者ID:nightfly19,项目名称:renyang-learn,代码行数:26,代码来源:local-roster-bridge.cpp
示例3: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");
boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
boost::shared_ptr<Ekiga::CallCore> call_core = core.get<Ekiga::CallCore> ("call-core");
boost::shared_ptr<Ekiga::ChatCore> chat_core = core.get<Ekiga::ChatCore> ("chat-core");
boost::shared_ptr<Ekiga::AccountCore> account_core = core.get<Ekiga::AccountCore> ("account-core");
boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");
boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");
boost::shared_ptr<Ekiga::AudioOutputCore> audiooutput_core = core.get<Ekiga::AudioOutputCore> ("audiooutput-core");
boost::shared_ptr<Ekiga::VideoOutputCore> videooutput_core = core.get<Ekiga::VideoOutputCore> ("videooutput-core");
boost::shared_ptr<Ekiga::PersonalDetails> personal_details = core.get<Ekiga::PersonalDetails> ("personal-details");
boost::shared_ptr<Bank> account_store = core.get<Bank> ("opal-account-store");
Ekiga::ServicePtr sip_endpoint = core.get ("opal-sip-endpoint");
if (contact_core && presence_core && call_core && chat_core
&& account_core && audioinput_core && videoinput_core
&& audiooutput_core && videooutput_core && personal_details
&& !account_store && !sip_endpoint) {
PIPSocket::SetSuppressCanonicalName (true); // avoid long delays
hook_ekiga_plugins_to_opal (core);
boost::shared_ptr<CallManager> call_manager (new CallManager (core));
core.add (call_manager);
boost::shared_ptr<Sip::EndPoint> sip_manager (new Sip::EndPoint (*call_manager, core), null_deleter ());
std::cout << "FIXME: where is H323" << std::endl << std::flush;
sip_manager->setup ();
call_manager->set_sip_endpoint (sip_manager);
core.add (sip_manager);
boost::shared_ptr<Bank> bank (new Bank (core));
account_core->add_bank (bank);
presence_core->add_cluster (bank);
core.add (bank);
contact_core->add_contact_decorator (bank);
presence_core->add_presentity_decorator (bank);
call_manager->ready.connect (boost::bind (&Opal::Bank::call_manager_ready, &*bank));
call_manager->setup ();
presence_core->add_presence_publisher (bank);
presence_core->add_presence_fetcher (bank);
call_core->add_manager (call_manager);
presence_core->add_supported_uri (&is_supported_address); //FIXME
result = true;
}
return result;
}
开发者ID:UIKit0,项目名称:ekiga,代码行数:55,代码来源:opal-main.cpp
示例4: core
GMAudioOutputManager_null::GMAudioOutputManager_null (Ekiga::ServiceCore & _core)
: core (_core),
runtime (*(dynamic_cast<Ekiga::Runtime *> (_core.get ("runtime"))))
{
current_state[Ekiga::primary].opened = false;
current_state[Ekiga::secondary].opened = false;
}
开发者ID:nightfly19,项目名称:renyang-learn,代码行数:7,代码来源:audiooutput-manager-null.cpp
示例5: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
boost::shared_ptr<Ekiga::PresenceCore> presence = core.get<Ekiga::PresenceCore> ("presence-core");
boost::shared_ptr<Ekiga::AccountCore> account = core.get<Ekiga::AccountCore> ("account-core");
boost::shared_ptr<Ekiga::ChatCore> chat = core.get<Ekiga::ChatCore> ("chat-core");
boost::shared_ptr<Ekiga::PersonalDetails> details = core.get<Ekiga::PersonalDetails> ("personal-details");
if (presence && account && chat && details) {
LM::DialectPtr dialect(new LM::Dialect (core));
LM::ClusterPtr cluster(new LM::Cluster (dialect, details));
LM::BankPtr bank (new LM::Bank (details, dialect, cluster));
if (core.add (bank)) {
chat->add_dialect (dialect);
account->add_bank (bank);
presence->add_cluster (cluster);
result = true;
}
}
return result;
}
开发者ID:Pobegunchik,项目名称:ekiga,代码行数:25,代码来源:loudmouth-main.cpp
示例6: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* argc,
char** argv[])
{
boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");
boost::shared_ptr<Ekiga::AudioOutputCore> audiooutput_core = core.get<Ekiga::AudioOutputCore> ("audiooutput-core");
boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");
if (audioinput_core && audiooutput_core && videoinput_core) {
if (gst_init_check (argc, argv, NULL)) {
GST::VideoInputManager* video = new GST::VideoInputManager ();
GST::AudioInputManager* audioin = new GST::AudioInputManager ();
GST::AudioOutputManager* audioout = new GST::AudioOutputManager ();
Ekiga::ServicePtr service (new GStreamerService);
if (core.add (service)) {
audioinput_core->add_manager (*audioin);
audiooutput_core->add_manager (*audioout);
videoinput_core->add_manager (*video);
result = true;
}
} else {
std::cout << "gst_init_check failed" << std::endl; // FIXME: remove
}
}
return result;
}
开发者ID:GNOME,项目名称:ekiga,代码行数:32,代码来源:gst-main.cpp
示例7: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
Ekiga::ServicePtr service = core.get ("xcap-core");
if ( !service) {
boost::shared_ptr<XCAP::Core> xcap(new XCAP::Core ());
core.add (xcap);
result = true;
}
return result;
}
开发者ID:Klom,项目名称:ekiga,代码行数:16,代码来源:xcap-main.cpp
示例8: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
Ekiga::ServicePtr service = core.get ("resource-list");
boost::shared_ptr<Ekiga::PresenceCore> presence_core = core.get<Ekiga::PresenceCore> ("presence-core");
boost::shared_ptr<XCAP::Core> xcap = core.get<XCAP::Core> ("xcap-core");
if ( !service && presence_core && xcap) {
boost::shared_ptr<RL::Cluster> cluster (new RL::Cluster (core));
core.add (cluster);
presence_core->add_cluster (cluster);
result = true;
}
return result;
}
开发者ID:Klom,项目名称:ekiga,代码行数:18,代码来源:resource-list-main.cpp
示例9: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
gmref_ptr<Ekiga::HalCore> hal_core = core.get ("hal-core");
if (hal_core) {
HalManager_dbus *hal_manager = new HalManager_dbus(core);
hal_core->add_manager (*hal_manager);
core.add (gmref_ptr<Ekiga::Service> (new Ekiga::BasicService ("hal-dbus",
"\tComponent bringing HAL through DBUS")));
result = true;
}
return result;
}
开发者ID:NeoWing,项目名称:ekiga-3.2.7,代码行数:18,代码来源:hal-main-dbus.cpp
示例10: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
gmref_ptr<Ekiga::Service> service = core.get ("call-history-store");
gmref_ptr<Ekiga::ContactCore> contact_core = core.get ("contact-core");
gmref_ptr<Ekiga::CallCore> call_core = core.get ("call-core");
if (contact_core && call_core && !service) {
gmref_ptr<History::Source> source (new History::Source (core));
core.add (source);
contact_core->add_source (source);
result = true;
}
return result;
}
开发者ID:NeoWing,项目名称:ekiga-3.2.7,代码行数:18,代码来源:history-main.cpp
示例11: m
/* The Methods */
PVideoOutputDevice_EKIGA::PVideoOutputDevice_EKIGA (Ekiga::ServiceCore & _core)
: core (_core), videooutput_core (*(dynamic_cast<Ekiga::VideoOutputCore *> (_core.get ("videooutput-core"))))
{
PWaitAndSignal m(videoDisplay_mutex);
is_active = FALSE;
/* Used to distinguish between input and output device. */
device_id = 0;
}
开发者ID:nightfly19,项目名称:renyang-learn,代码行数:11,代码来源:videooutput.cpp
示例12:
bool
local_roster_init (Ekiga::ServiceCore &core,
int */*argc*/,
char **/*argv*/[])
{
bool result = false;
Ekiga::PresenceCore *presence_core = NULL;
Local::Cluster *cluster = NULL;
presence_core
= dynamic_cast<Ekiga::PresenceCore*>(core.get ("presence-core"));
if (presence_core != NULL) {
cluster = new Local::Cluster (core);
core.add (*cluster);
presence_core->add_cluster (*cluster);
result = true;
}
return result;
}
开发者ID:nightfly19,项目名称:renyang-learn,代码行数:22,代码来源:local-roster-main.cpp
示例13: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
gmref_ptr<Ekiga::ContactCore> contact_core = core.get ("contact-core");
gmref_ptr<Ekiga::PresenceCore> presence_core = core.get ("presence-core");
gmref_ptr<Ekiga::CallCore> call_core = core.get ("call-core");
gmref_ptr<Ekiga::ChatCore> chat_core = core.get ("chat-core");
gmref_ptr<Ekiga::AccountCore> account_core = core.get ("account-core");
if (contact_core && presence_core && call_core && chat_core && account_core) {
gmref_ptr<CallManager> call_manager (new CallManager (core));
gmref_ptr<Opal::Bank> bank (new Bank (core));
account_core->add_bank (bank);
core.add (bank);
call_manager->ready.connect (sigc::mem_fun (&*bank, &Opal::Bank::call_manager_ready));
unsigned sip_port = gm_conf_get_int (SIP_KEY "listen_port");
gmref_ptr<Sip::EndPoint> sip_manager (new Sip::EndPoint (*call_manager, core, sip_port));
call_manager->add_protocol_manager (sip_manager);
account_core->add_account_subscriber (*sip_manager);
contact_core->add_contact_decorator (sip_manager);
presence_core->add_presentity_decorator (sip_manager);
presence_core->add_presence_fetcher (sip_manager);
presence_core->add_presence_publisher (sip_manager);
#ifdef HAVE_H323
unsigned h323_port = gm_conf_get_int (H323_KEY "listen_port");
gmref_ptr<H323::EndPoint> h323_manager (new H323::EndPoint (*call_manager, core, h323_port));
call_manager->add_protocol_manager (h323_manager);
account_core->add_account_subscriber (*h323_manager);
contact_core->add_contact_decorator (h323_manager);
presence_core->add_presentity_decorator (h323_manager);
#endif
call_core->add_manager (call_manager);
core.add (call_manager);
new ConfBridge (*call_manager); // FIXME: isn't that leaked!?
presence_core->add_supported_uri (sigc::ptr_fun (is_supported_address)); //FIXME
OpalLinkerHacks::loadOpalVideoInput = 1;
OpalLinkerHacks::loadOpalVideoOutput = 1;
OpalLinkerHacks::loadOpalAudio = 1;
result = true;
}
return result;
}
开发者ID:NeoWing,项目名称:ekiga-3.2.7,代码行数:55,代码来源:opal-main.cpp
示例14: gtk
bool
gtk_core_init (Ekiga::ServiceCore &core,
int *argc,
char **argv[])
{
if (gtk_init_check (argc, argv)) {
boost::shared_ptr<Gtk::Core> gtk (new Gtk::Core);
core.add (gtk);
return true;
} else
return false;
}
开发者ID:Pobegunchik,项目名称:ekiga,代码行数:16,代码来源:gtk-core-main.cpp
示例15:
bool
gtk_core_init (Ekiga::ServiceCore &core,
int *argc,
char **argv[])
{
if (gtk_init_check (argc, argv)) {
Gtk::Core *gtk = new Gtk::Core ();
core.add (*gtk);
return true;
} else
return false;
}
开发者ID:nightfly19,项目名称:renyang-learn,代码行数:16,代码来源:gtk-core-main.cpp
示例16: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
boost::shared_ptr<Ekiga::ContactCore> contact_core = core.get<Ekiga::ContactCore> ("contact-core");
if (contact_core) {
boost::shared_ptr<OPENLDAP::Source> service (OPENLDAP::Source::create (core));
core.add (service);
contact_core->add_source (service);
sasl_client_init (NULL); // FIXME: shouldn't it be done by the source!?
result = true;
}
return result;
}
开发者ID:GNOME,项目名称:ekiga,代码行数:17,代码来源:ldap-main.cpp
示例17: SIPEndPoint
/* The class */
Opal::Sip::EndPoint::EndPoint (Opal::CallManager & _manager,
Ekiga::ServiceCore & _core,
unsigned _listen_port)
: SIPEndPoint (_manager),
manager (_manager),
core (_core),
presence_core (*(dynamic_cast<Ekiga::PresenceCore *> (core.get ("presence-core")))),
runtime (*(dynamic_cast<Ekiga::Runtime *> (core.get ("runtime")))),
account_core (*(dynamic_cast<Ekiga::AccountCore *> (core.get ("account-core"))))
{
Ekiga::ChatCore* chat_core;
protocol_name = "sip";
uri_prefix = "sip:";
listen_port = _listen_port;
chat_core = dynamic_cast<Ekiga::ChatCore *> (core.get ("chat-core"));
dialect = new SIP::Dialect (core, sigc::mem_fun (this, &Opal::Sip::EndPoint::send_message));
chat_core->add_dialect (*dialect);
/* Timeouts */
SetAckTimeout (PTimeInterval (0, 32));
SetPduCleanUpTimeout (PTimeInterval (0, 1));
SetInviteTimeout (PTimeInterval (0, 6));
SetNonInviteTimeout (PTimeInterval (0, 6));
SetRetryTimeouts (500, 4000);
SetMaxRetries (8);
/* Start listener */
set_listen_port (listen_port);
/* Update the User Agent */
SetUserAgent ("Ekiga/" PACKAGE_VERSION);
/* Ready to take calls */
manager.AddRouteEntry("sip:.* = pc:<db>");
manager.AddRouteEntry("pc:.* = sip:<da>");
/* NAT Binding */
SetNATBindingRefreshMethod (SIPEndPoint::EmptyRequest);
Ekiga::PersonalDetails *details = dynamic_cast<Ekiga::PersonalDetails *> (_core.get ("personal-details"));
if (details)
publish (*details);
}
开发者ID:nightfly19,项目名称:renyang-learn,代码行数:46,代码来源:sip-endpoint.cpp
示例18: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
boost::shared_ptr<Ekiga::AudioInputCore> audioinput_core = core.get<Ekiga::AudioInputCore> ("audioinput-core");
if (audioinput_core) {
GMAudioInputManager_null *audioinput_manager = new GMAudioInputManager_null(core);
audioinput_core->add_manager (*audioinput_manager);
core.add (Ekiga::ServicePtr (new Ekiga::BasicService ("null-audio-input",
"\tComponent bringing silent audio input")));
result = true;
}
return result;
}
开发者ID:GNOME,项目名称:ekiga,代码行数:18,代码来源:audioinput-main-null.cpp
示例19: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
boost::shared_ptr<Ekiga::VideoInputCore> videoinput_core = core.get<Ekiga::VideoInputCore> ("videoinput-core");
if (videoinput_core) {
GMVideoInputManager_ptlib *videoinput_manager = new GMVideoInputManager_ptlib;
videoinput_core->add_manager (*videoinput_manager);
core.add (Ekiga::ServicePtr (new Ekiga::BasicService ("ptlib-video-input",
"\tComponent bringing PTLIB's video input")));
result = true;
}
return result;
}
开发者ID:Klom,项目名称:ekiga,代码行数:18,代码来源:videoinput-main-ptlib.cpp
示例20: try_initialize_more
bool try_initialize_more (Ekiga::ServiceCore& core,
int* /*argc*/,
char** /*argv*/[])
{
boost::shared_ptr<Ekiga::HalCore> hal_core = core.get<Ekiga::HalCore> ("hal-core");
boost::shared_ptr<GUDevMonitor> monitor = core.get<GUDevMonitor> ("gudev");
if (hal_core && !monitor) {
monitor = boost::shared_ptr<GUDevMonitor> (new GUDevMonitor);
core.add (Ekiga::ServicePtr (monitor));
hal_core->add_manager (*monitor);
result = true;
}
return result;
}
开发者ID:UIKit0,项目名称:ekiga,代码行数:18,代码来源:hal-gudev-main.cpp
注:本文中的ekiga::ServiceCore类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论