Mayor Gray officiates the wedding of D.C. residents Carlos Ignacio Taylor, left and Robert Vernon Robertson Jr. (Marlon Correa/The Washington Post)

Mayor Vincent C. Gray took the first advantage of a new city law allowing him to preside over weddings on Tuesday afternoon, marrying an Adams Morgan couple at the John A. Wilson Building.

Rob Robertson, a 52-year-old technology consultant, and Carlos Taylor, a 46-year-old IT analyst, took their vows in the mayor’s fifth-floor ceremonial office in front of dozens of family and friends, as well as a gaggle of reporters, TV cameras and city hall aides.

The new law expanding the pool of permitted marriage officiants was passed by the D.C. Council in July and cleared a congressional review period earlier this month. Besides mayors, the new law allows marriages to be solemnized by council members, holders of temporary court-issued licenses and even spouses-to-be themselves.

The mayoral ceremony was arranged by Peter Rosenstein, a prominent supporter of Gray’s and a friend of the couple. Gray said afterward that he would have gladly officiated at any wedding, “but I was happy that this was a same-sex marriage because I think it underscores what we’ve been able to do in this city,” he said, referring the District’s 2010 legalization of gay weddings.

Gray said he’s ready to start marrying more couples: “I really enjoyed this, and if there are others who would like to do it, I’d be happy to try to figure out how to make it happen.”