I am looking at the String class in Actionscript 3.0.
It's having a property String.length . Internally it's a getter function ( or method ?) returning the length of string.
Why it can't be String.getLength() ?
Methods can take in 1, 2 or more values.. so their significance can be understood. But what significance "property" has. As it's afterall, a function only. So, why categorization into properties? Just adding an overhead botheration to remember that something has been categorized into property ?
In other words, as a programmer, how i am helped, when i am told that String.length is a property of String class. And you can't find any method for the same.
While writing a program, how i would know what is a property, and what is a method?
Appreciate having some light on this.