gate toString