public static function fromRecordId($id, $dataConnector)
    {

        $toolConsumer = new ToolConsumer(null, $dataConnector);

        $toolConsumer->initialize();
        $toolConsumer->setRecordId($id);
        if (!$dataConnector->loadToolConsumer($toolConsumer)) {
            $toolConsumer->initialize();
        }

        return $toolConsumer;

    }
public static function fromRecordId($id, $dataConnector)
    {

        $toolConsumer = new ToolConsumer(null, $dataConnector);

        $toolConsumer->initialize();
        $toolConsumer->setRecordId($id);
        if (!$dataConnector->loadToolConsumer($toolConsumer)) {
            $toolConsumer->initialize();
        }

        return $toolConsumer;

    }
public static function fromRecordId ( $ id , $ dataConnector ) { $ toolConsumer = new ToolConsumer ( null , $ dataConnector ) ; $ toolConsumer -> initialize ( ) ; $ toolConsumer -> setRecordId ( $ id ) ; if ( ! $ dataConnector -> loadToolConsumer ( $ toolConsumer ) ) { $ toolConsumer -> initialize ( ) ; } return $ toolConsumer ; }
Load the tool consumer from the database by its record ID.

@param string          $id                The consumer key record ID
@param DataConnector   $dataConnector    Database connection object

@return object ToolConsumer       The tool consumer object
Load the tool consumer from the database by its record ID .