Civil, Coduri, Legislatie