add gate class