Class dependency the better? way