BUCHAREST, Romania (AP) — The European Court of Justice on Tuesday ruled that a gay Romanian-American couple is entitled to the same residency rights as other married couples in the European Union.

Romanian Adrian Coman and his American husband, Claibourn Robert Hamilton, have fought a six-year legal battle to get their 2010 marriage in Belgium legally recognized in Romania.

The Luxembourg-based court ruled that EU members "may not obstruct the freedom of residence" of EU citizens by refusing to grant residence for the same-sex spouse. However, members retain "the freedom whether or not to authorize marriage between persons of the same sex."

The ruling has implications for at least tens of thousands of same-sex couples in Romania, Poland, Slovakia, Bulgaria, Lithuania and Latvia, which don't currently offer legal protection to same-sex couples.

Coman, a 46-year-old gay rights' activist, said he was overwhelmed by the ruling.

"Today's decision means that I can finally look in the eyes of any Romanian or EU clerk with the certainty we are a family and the state recognizes what we are," while Hamilton, also 46, speaking by video link from New York, said: "We are one step closer to being recognized as a family and I am truly elated."

Iustina Ionescu, a human rights' lawyer, said the ruling meant that the couple would "be legally recognized in Romania and the other EU states (and can) freely move around and settle in any of the member states."

Practically, the ruling means that Hamilton as a non-EU citizen will have employment rights and health benefits, previously denied to him, as Coman's spouse. The couple lives in New York.

Opposition to same-sex relationships is often fierce in Romania, where homosexuality was only decriminalized in 2002.

Coman's father, Liviu Coman, told The Associated Press he was pleased at the ruling which would make some aspects of their lives easier.

However, he said he was most gratified as a parent that: "They are happy together and get on well."