ApartmentOwnership

Under Review

DOCUMENTSTOOLSUTILITYFINANCIAL

Contract purpose

Smart Contract that keep tracks of an apartment/house ownership over time.

Contract parameters

_addr: the full address of the apartment/house

_value : value of the apartment/house

_name: name of the current owner

_pricePaid: the sum the current owner paid for the apartment

_fromDate: the date when the ownership started (unix epoch time)

Exposed methods and variables

currentOwner address of the current owner

addr returns the full address of the apartment/house

value returns the value of the apartment/house

owners list of previous owners (returns the owner details stored at the specified index )

mapOwners returns the owner details based on his ethereum address

changeOwner called by the current owner when the apartment/house ownership changes

parameter nametypedetails
_namestringnew owner's name
_addrethereum addressaddress of the new owner
_pricePaidintegerthe amount the owner paid for the apartment
_fromDateintegerthe date when the new ownership starts

changeValue called only by the current owner when he wants to update the apartment/house value

parameter nametypedetails
_newintegerthe new value
Reviewed by Modex
Buy
Buy Contract

Create an account or login to purchase this smart contract