for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace IBM\Watson\Common\Util;
use Http\Discovery\HttpClientDiscovery;
use Http\Discovery\MessageFactoryDiscovery;
/**
* Utility trait for discovering required components.
*/
trait DiscoveryTrait
{
* Discover configured HTTP client.
*
* @return \Http\Client\HttpClient
public function discoverHttpClient()
return HttpClientDiscovery::find();
}
* Discover configured message factory.
* @return \Http\Message\MessageFactory
public function discoverMessageFactory()
return MessageFactoryDiscovery::find();