What is the meaning of @private in the API source code?

In the case of javascript frameworks like Ember… and the ember addons available… What is the meaning of @private in the API source code?

…does it mean the property/method is private to the component/class and should only be used internally by that component/class?

Or does it mean that the property/method is private to the framework and should only be used internally by the framework?

Another way to put this question is: Can someone explain/clarify to me the difference between public/private methods/properties, and public/private API. (…are they both essentially the same thing?)

I trying to figure out when I should make my own methods/properties private or public and why it matters (haven’t really given it too much thought before now)

A private class, event, method, or property, in the Ember framework, is not meant to be used by users of the framework, including app and addon authors, and is not to be considered part of the public API which is subject to semver. That means there is absolutely no guarantee that the private class or field will still be available in the next minor or even patch version of Ember.

1 Like