This is the famous 'golden rule', which turns up in many formulations
in literature, and also in different languages. This particular
formulation is not especially well phrased: the second part,
in particular, is rhythmically awkward to modern ears, though
such word orders were more usual in the sixteenth century. The
emphasis on maleness also belongs to an earlier era. But the
universality and eminent good sense of the assertion makes it
a queen of quotations, to my mind, more commonly and memorably
expressed as 'Do unto others as you would have them do unto
you'.