1656. Subrogation takes place by operation of law(1) in favour of a creditor who pays another creditor whose claim is preferred to his because of a prior claim or a hypothec;
(2) in favour of the acquirer of a property who pays a creditor whose claim is secured by a hypothec on the property;
(3) in favour of a person who pays a debt to which he is bound with others or for others and which he has an interest in paying;
(4) in favour of an heir who pays with his own funds a debt of the succession for which he was not bound;
(5) in any other case provided by law.