Jump to content

Documentation: Difference between revisions

Added Kotlin
(Added entry for FreeBASIC)
(Added Kotlin)
Line 803:
//...code here
}
}</lang>
 
=={{header|Kotlin}}==
Kotlin uses a system of comments called KDoc to document source code. This is similar to Java's Javadoc though there are some additional block tags to support Kotlin-specific constructs.
 
Inline markup uses an extended form of the Markdown syntax.
 
The documentation is generated using a tool called Dokka.
 
The following is a slightly extended version of the example in the official Kotlin documentation:
<lang scala>/**
* A group of *members*.
* @author A Programmer.
* @since version 1.1.51.
*
* This class has no useful logic; it's just a documentation example.
*
* @param T the type of a member in this group.
* @property name the name of this group.
* @constructor Creates an empty group.
*/
class Group<T>(val name: String) {
/**
* Adds a [member] to this group.
* @throws AddException if the member can't be added.
* @return the new size of the group.
*/
fun add(member: T): Int { ... }
}</lang>
 
9,490

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.