Apple's Beats Electronics and its cofounders have been sued in a U.S. court for allegedly easing out headphones developer Monster from a partnership ahead of the 2014 acquisition by the iPhone maker.

Describing a 2011 investment by HTC in Beats as a "sham transaction," Monster and its founder Noel Lee have alleged that the deal was used by Beats to invoke a clause in its contract with Monster to end the partnership while retaining all rights to the headphone technology.

Apple declined to comment on the suit. HTC could not be immediately reached for comment.

Beats' cofounders Jimmy Iovine and Andre Young, popularly known as Dr. Dre, entered into a partnership in January 2008 with Monster to develop and promote Monster's "Beats By Dr. Dre" product line, a licensed marketing label for a line of Monster headphones, according to the complaint. Monster claims it handled all designing, engineering, manufacturing, production, marketing, and distribution of the headphones in return for a license to the Beats brand and celebrity marketing by Iovine and Dre.

"Simply put, Monster did all the work, financed the entire effort, and paid Iovine and Dre a royalty for their marketing efforts," according to the complaint. By 2009, Beats Electronics had been added to the license and promotion agreement as a party and Lee was offered a 5 percent stake in Beats' equity to cement ties between the two companies.

Citing the change of control provision in the agreement after the HTC investment, Beats acquired Monster's "Beats By Dr. Dre" product line, including all development, engineering, manufacturing, marketing, distributing, and retail rights.

If the partnership had expired on its own terms some months later, this transfer would not have happened, according to the complaint, which holds that as a result Monster and Lee lost millions of dollars.

Lee had also sold most of his 5 percent stake in Beats in September 2012, after HTC sold back half its stake to Beats, as he "was concerned that he was being kept in the dark by Beats about material aspects of the business." He was later persuaded to offload the remaining 1.25 percent share to Beats, resulting in a total loss of over $100 million if he was still a 5 percent stakeholder after the Apple acquisition was announced, according to the complaint.

Beats' founders have falsely claimed that Beats, through Iovine and Dre, successfully spearheaded all of the designing, engineering, manufacturing, production, marketing, and distributing of "Beats By Dr. Dre" products, the complaint added.

Monster has asked for damages including punitive damages, and a jury trial for all relevant issues.