exchange-modularize gate class