is this good or bad practice:

Code PHP:
<?php
require_once("Image/Barcode.php");
 
class BarcodeClass {
 
}

how would you use variables/etc from the required file, in the class?