In this document you will be guided how to use @property in Python

Why?

If you want to change your class but do not want change the way to use the class which avoid other people must be change their code.

How?
  • There are to way to use:
    • Use <field_name> = property(<fucn_name>, <func_name>, ...)
    • Use @property decorator