(1) The deceased may by contract appoint an heir, grant legacies, and impose testamentary burdens and may also select the laws of inheritance that are to be applied (contract of inheritance).
(2) Both the other contractual party and a third party may be appointed as an heir (contractual heir) or as a legatee.