getWidth function never used problem

In chapter for Classes, Mosh created a function - > void getWidth( int width); and it worked.
For me it is not working. shows this function is never used. I disabled function in inspection
but still same thing.

Can you paste your code in a code block?

Your code here

remove int from calling the functins.

There is no need calling function. It is just declared and showing this message. Anyway I solved my problem.