Allow ChannelProviderFactory::newInstance to accept a Configuration

Deprecate ChannelProvider::configure(), which doesn't do much and
is incompatible with the idea of shared context.

A lot of down-stream mess related to the confused relationship
between InternalClientContextImpl and InternalClientContextImpl::ChannelProviderImpl.
This is changed to compose the provider within the context
and use a nested shared_ptr so that references to the provider
are really references to the context.

This brings the ownership semantic in line with what the API
suggests, and what other providers implement.
This commit is contained in:
Michael Davidsaver
2015-12-10 17:31:18 -05:00
parent 03e5b0c747
commit c0ee432598
5 changed files with 95 additions and 170 deletions

View File

@@ -371,17 +371,6 @@ int main()
{
for (int i = 0; i < 10; i++) {
{
/*
ClientContextImpl::shared_pointer context = createClientContextImpl();
context->printInfo();
context->initialize();
context->printInfo();
epicsThreadSleep ( SLEEP_TIME );
ChannelProvider::shared_pointer provider = context->getProvider();
*/
ClientFactory::start();
ChannelProvider::shared_pointer provider = getChannelProviderRegistry()->getProvider("pva");