It is the policy of this chapter to give maximum effect to the principle of freedom of contract and to the enforceability of agreements.