I am trying to create an object of third-party library class in controller file, I am facing issue while passing argument, below is a code I have written to create an object.
Sample_controller.php
protected $_third_party_object;
public function __construct(
\Magento\Framework\ObjectManagerInterface $objectManager
){
$this->_objectManager = $objectManager;
}
public function execute(){
$this->_third_party_object = $this->_objectManager->create('\venodor_name\module_name\lib\class_name',$param);
}
param is the parameter that needs to be passed to the constructor of the third-party class.
$param
holding?