No intercourse shall be allowed with any convict in solitary imprisonment, except for the conveyance of food and other necessary purposes, unless some minister of the gospel shall be disposed to visit him, in the manner hereinafter provided.