k4ulyg
Last Updated: February 25, 2016
·
2.646K
· meerkatdev
Ead8cfecf0c3e291415bb83281f19c8c

Scala @deprecated annotation

When in Scala you want to deprecate a method, use the

@deprecated( description: String, since_version: String )

tag, example:

@deprecated( "use getFoo", "1.5" ) def getFuu = {...}

Another suggestion: When you plan to substitute a method successively, write its name uncompletely! (of course, still understandable)
It will be better then, because you could make a mental note that is a function to improve

Docs:
http://www.scala-lang.org/api/current/index.html#scala.deprecated

Say Thanks
Respond