If a creature acquires a character class, it follows the rules for multiclass characters.
The creature's Hit Dice equal the number of class levels it has plus its racial Hit Dice. A creature's 'monster class' is always a favored class, and the creature never takes XP penalties for having it. Additional Hit Dice gained from taking levels in a character class never affect a creature's size.
Humanoids and Class Levels: Creatures with 1 or less HD replace their monster levels with their character levels. The monster loses the attack bonus, saving throw bonuses, skills, and feats granted by its 1 monster HD and gains the attack bonus, save bonuses, skills, feats, and other class abilities of a 1st-level character of the appropriate class.
Level Adjustment and Effective Character Level: To determine the effective character level (ECL) of a monster character, add its level adjustment to its racial Hit Dice and character class levels. The monster is considered to have experience points equal to the minimum needed to be a character of its ECL.
If you choose to equip a monster with gear, use its ECL as its character level for purposes of determining how much equipment it can purchase. Generally, only monsters with an Advancement entry of 'By character class' receive NPC gear; other creatures adding character levels should be treated as monsters of the appropriate CR and assigned treasure, not equipment.