I have read many docs regarding to proxy classes which is automatically generated by Magento 2 to stop the chain reaction of object instantiation. These docs definition told us that proxy classes should be define via the di.xml and must NOT be specified in the __ constructor method. But when I checked some third party module like Amasty and found that they define the Proxy in __ constructor method.
e.g. path of file: app/code/Amasty/ShopbyBase/Model/Category/Manager.php
in __construct method pass below proxy
and example file is
Above examples make me confused because as per definition that proxy classes define only via di.xml.
if anyone have idea about it,please let me know how we should use proxy via xml or via __construct method.