The Shulchan Aruch (יו”ד פט:ב) writes that if one ate dairy, one can eat meat immediately after that as long as they wash their mouth, eat something neutral such as bread, and wash their hands. The Rama writes that one should be stringent to wait between dairy and meat. There are many different opinions about how these halachot apply. Some say that the Rama is referring to meat after dairy but not to poultry, because poultry and dairy are only rabbinically prohibited. Some say that the Rama means to wait only a half hour. Others say that the Rama means that the wait should be the same as after meat – six hours. Each person should follow their custom in these halachot, or consult their rabbi.
Most agree that after eating hard cheese one definitely has to be more stringent and should wait before eating meat (רמ”א יו”ד פט:ב). The poskim say to wait six hours before eating meat. The definition of hard cheese is generally any cheese that has been aged six months and has a strong, lingering taste. If one ate cheese that was not aged that long but does have a strong taste (such as many cheaper varieties of cheddar), consult your rabbi about waiting. The general consensus of the poskim is that if hard cheese was melted or cooked, the strong flavor was compromised. Therefore, you do not have to wait six hours after eating the cheese.