OOP php from pdo method