"His students" is the direct object complement. You could rephrase the sentence as "he watched his students as they were writing their exam", so it's a kind of apposition to students
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.