Xcode 5 - comment for documentation
New feature of Xcode 5. You can document your own code as like the below:
/*! Add new message between source to destination timeline as empty name string
* \param sourceId Source timeline entity ID
* \param destId Destination timeline entity ID
* \returns A newly created message instance
*/
- (ISMessage*)messageFromTimeline:(NSInteger)sourceId toTimeline:(NSInteger)destId;
Property documentation is also possible.
Please check this stackoverflow discussion also:
http://stackoverflow.com/questions/19168423/what-are-the-new-documentation-commands-available-in-xcode-5
And, Apple's documentation:
https://developer.apple.com/library/mac/documentation/DeveloperTools/Conceptual/HeaderDoc/tags/tags.html
/*! Add new message between source to destination timeline as empty name string
* \param sourceId Source timeline entity ID
* \param destId Destination timeline entity ID
* \returns A newly created message instance
*/
- (ISMessage*)messageFromTimeline:(NSInteger)sourceId toTimeline:(NSInteger)destId;
You can use Doxygen format for documentation. Then you can see the documentation of this function from Xcode 5 UI (by using Quick Help or Option-Click).
Very easy! The following comment styles are also possible.
/**
* Add new message between source to destination timeline as empty name string
* @author Wonil Kim
*
* @param sourceId Source timeline entity ID
* @param destId Destination timeline entity ID
* @return A newly created message instance
*/
- (ISMessage*)messageFromTimeline:(NSInteger)sourceId toTimeline:(NSInteger)destId;
/// Add new message between source to destination timeline
///
/// @param sourceId Source timeline entity ID
/// @param destId Destination timeline entity ID
/// @param name Message name
/// @return A newly created message instance
- (ISMessage*)messageFromTimeline:(NSInteger)sourceId toTimeline:(NSInteger)destId withName:(NSString*)name;
/// Minimum height of entity for layout calculation
@property NSInteger minEntityHeight;
http://stackoverflow.com/questions/19168423/what-are-the-new-documentation-commands-available-in-xcode-5
And, Apple's documentation:
https://developer.apple.com/library/mac/documentation/DeveloperTools/Conceptual/HeaderDoc/tags/tags.html