(continued from previous pageself value value class number(object)""sample class that uses positivevalueonly descriptor""value positivevalueonly(test number(print(test value test value print(test value test value - valueerroronly positive values can be used passing arguments to decorator in previous codesno arguments were passed in the decorator in this exampletaxrate is passed in the decorator and total price is calculated based on tax rate taxrate py class total(object)""calculate total values ""def __init__(selftaxrate )self rate taxrate def __get__(selfinstancecls)net_price rate return instance net self rate override __set__so that there will be no way to set the value def __set__(selfinstancevalue)raise noimplementationerror("can not change value"class pricenz(object)total total( def __init__(selfnetcomment="")self net net self comment comment class priceaustralia(object)total total( def __init__(selfnet)self net net pricenz pricenz( "nzd"print(pricenz total priceaustralia priceaustralia( print(priceaustralia total descriptors