当前位置: 首页>>代码示例>>C++>>正文


C++ InitialisationParams类代码示例

本文整理汇总了C++中InitialisationParams的典型用法代码示例。如果您正苦于以下问题:C++ InitialisationParams类的具体用法?C++ InitialisationParams怎么用?C++ InitialisationParams使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了InitialisationParams类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: iEnv

DvStack::DvStack(OpenHome::Environment& aEnv)
    : iEnv(aEnv)
    , iBootId(1)
    , iNextBootId(2)
    , iMdns(NULL)
{
    iEnv.SetDvStack(this);
    iSsdpNotifierManager = new DviSsdpNotifierManager(*this);
    iPropertyUpdateCollection = new DviPropertyUpdateCollection(*this);
    InitialisationParams* initParams = iEnv.InitParams();
    TUint port = initParams->DvUpnpServerPort();
    iDviDeviceMap = new DviDeviceMap;
    iDviServerUpnp = new DviServerUpnp(*this, port);
    iSubscriptionManager = new DviSubscriptionManager(*this);
    iDviServerWebSocket = new DviServerWebSocket(*this);
    const TChar* hostName = NULL;
    if (initParams->DvIsBonjourEnabled(hostName)) {
#ifndef DEFINE_WINDOWS_UNIVERSAL
        iMdns = new OpenHome::Net::MdnsProvider(iEnv, hostName);
#endif
    }
    if (initParams->DvNumLpecThreads() == 0) {
        iLpecServer = NULL;
    }
    else {
        port = initParams->DvLpecServerPort();
        iLpecServer = new DviServerLpec(*this, port);
    }
}
开发者ID:Montellese,项目名称:ohNet,代码行数:29,代码来源:DviStack.cpp

示例2: threadMain

static void threadMain ( void* aData )
{
    InitialisationParams* initParams = InitialisationParams::Create();
    Logger logger;
    FunctorMsg functor = MakeFunctorMsg(logger, &Logger::Log);
    initParams->SetLogOutput(functor);
    Runner::Main(0, NULL, initParams);
}
开发者ID:astaykov,项目名称:ohNet,代码行数:8,代码来源:Main.cpp

示例3: TestDviDiscovery

void TestDviDiscovery(DvStack& aDvStack)
{
    InitialisationParams* initParams = aDvStack.Env().InitParams();
    TUint oldMsearchTime = initParams->MsearchTimeSecs();
    initParams->SetMsearchTime(3); // higher time to give valgrind tests a hope of completing

    //Debug::SetLevel(Debug::kNetwork);
    Runner runner("SSDP discovery\n");
    runner.Add(new SuiteAlive(aDvStack));
    runner.Add(new SuiteMsearch(aDvStack));
    runner.Run();

    initParams->SetMsearchTime(oldMsearchTime);
}
开发者ID:Jacik,项目名称:ohNet,代码行数:14,代码来源:TestDviDiscovery.cpp

示例4: TestDviDeviceList

void TestDviDeviceList(CpStack& aCpStack, DvStack& aDvStack)
{
    InitialisationParams* initParams = aDvStack.Env().InitParams();
    TUint oldMsearchTime = initParams->MsearchTimeSecs();
    initParams->SetMsearchTime(1);

//    Debug::SetLevel(/*Debug::kDevice | Debug::kDvDevice | Debug::kXmlFetch | Debug::kError);

    Print("TestDviDeviceList - starting\n");

    DvDevices* devices = new DvDevices(aDvStack);
    CpDevices* deviceList = new CpDevices;
    FunctorCpDevice added = MakeFunctorCpDevice(*deviceList, &CpDevices::Added);
    FunctorCpDevice removed = MakeFunctorCpDevice(*deviceList, &CpDevices::Removed);

    Print("Count devices implementing service1\n");
    Brn domainName("a.b.c");
    Brn serviceType("service1");
    TUint ver = 1;
    CpDeviceListUpnpServiceType* list =
                new CpDeviceListUpnpServiceType(aCpStack, domainName, serviceType, ver, added, removed);
    std::vector<const char*> udns;
    udns.push_back((const char*)gNameDevice1.Ptr());
    udns.push_back((const char*)gNameDevice2.Ptr());
    deviceList->Validate(udns);
    udns.clear();
    delete list;
    deviceList->Clear();

    Print("Count devices implementing service2\n");
    serviceType.Set("service2");
    list = new CpDeviceListUpnpServiceType(aCpStack, domainName, serviceType, ver, added, removed);
    udns.push_back((const char*)gNameDevice1_1.Ptr());
    udns.push_back((const char*)gNameDevice2.Ptr());
    deviceList->Validate(udns);
    udns.clear();
    delete list;

    delete deviceList;
    delete devices;

    Print("TestDviDeviceList - completed\n");
    initParams->SetMsearchTime(oldMsearchTime);
}
开发者ID:fuzzy01,项目名称:ohNet,代码行数:44,代码来源:TestDviDeviceList.cpp

示例5: OhNetInitParamsMsearchTtl

uint32_t STDCALL OhNetInitParamsMsearchTtl(OhNetHandleInitParams aParams)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    return ip->MsearchTtl();
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例6: OhNetInitParamsSetMsearchTtl

void STDCALL OhNetInitParamsSetMsearchTtl(OhNetHandleInitParams aParams, uint32_t aTtl)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    ip->SetMsearchTtl(aTtl);
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例7: OhNetInitParamsSetAsyncBeginHandler

void STDCALL OhNetInitParamsSetAsyncBeginHandler(OhNetHandleInitParams aParams, OhNetCallbackAsync aCallback, void* aPtr)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    FunctorAsync functor = MakeFunctorAsync(aPtr, (OhNetFunctorAsync)aCallback);
    ip->SetAsyncBeginHandler(functor);
}
开发者ID:sewood,项目名称:ohNet,代码行数:6,代码来源:OhNetC.cpp

示例8: OhNetInitParamsDvIsBonjourEnabled

uint32_t STDCALL OhNetInitParamsDvIsBonjourEnabled(OhNetHandleInitParams aParams)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    const TChar* ignore = NULL;
    return (ip->DvIsBonjourEnabled(ignore)? 1 : 0);
}
开发者ID:sewood,项目名称:ohNet,代码行数:6,代码来源:OhNetC.cpp

示例9: OhNetInitParamsCpUpnpEventServerPort

uint32_t STDCALL OhNetInitParamsCpUpnpEventServerPort(OhNetHandleInitParams aParams)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    return ip->CpUpnpEventServerPort();
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例10: OhNetInitParamsDvMaxUpdateTimeSecs

uint32_t STDCALL OhNetInitParamsDvMaxUpdateTimeSecs(OhNetHandleInitParams aParams)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    return ip->DvMaxUpdateTimeSecs();
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例11: OhNetInitParamsSubscriptionDurationSecs

uint32_t STDCALL OhNetInitParamsSubscriptionDurationSecs(OhNetHandleInitParams aParams)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    return ip->SubscriptionDurationSecs();
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例12: OhNetInitParamsSetIncludeLoopbackNetworkAdapter

void STDCALL OhNetInitParamsSetIncludeLoopbackNetworkAdapter(OhNetHandleInitParams aParams)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    ip->SetIncludeLoopbackNetworkAdapter();
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例13: OhNetInitParamsSetFreeExternalCallback

void STDCALL OhNetInitParamsSetFreeExternalCallback(OhNetHandleInitParams aParams, OhNetCallbackFreeExternal aCallback)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    ip->SetFreeExternalCallback(aCallback);
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例14: OhNetInitParamsSetPendingSubscriptionTimeout

void STDCALL OhNetInitParamsSetPendingSubscriptionTimeout(OhNetHandleInitParams aParams, uint32_t aTimeoutMs)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    ip->SetPendingSubscriptionTimeout(aTimeoutMs);
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp

示例15: OhNetInitParamsSetSubscriptionDuration

void STDCALL OhNetInitParamsSetSubscriptionDuration(OhNetHandleInitParams aParams, uint32_t aDurationSecs)
{
    InitialisationParams* ip = reinterpret_cast<InitialisationParams*>(aParams);
    ip->SetSubscriptionDuration(aDurationSecs);
}
开发者ID:sewood,项目名称:ohNet,代码行数:5,代码来源:OhNetC.cpp


注:本文中的InitialisationParams类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。