If you ground the generator nutral to the frame then you must ground the frame and treat the generator as a separatly derived source and switch the nutral at the transfer switch. However if the nutral is separate from the frame then they are bonded at the main disconnect and are treated as a non-separetly derived system. Then you do not switch the nuteral at the transfer switch. Both are according to the code.