Template:APIBreadcrumb/documentation: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
No edit summary
mNo edit summary
Line 20: Line 20:


==Usage==
==Usage==
The template has one required parameter and two optional ones, depending on the what is being documented. If documenting a class or enumeration, only parameter #1 is required, the rest can be left blank.
The template has one required parameter and two optional ones, depending on what is being documented.  


: 1 - Enter the API version in which the call <u>became</u> available.
: 1 - Enter the API version in which the call was <u>first</u> introduced. (Required)
: 2 - If the page is for a method or property, enter a link to the parent class.  
: 2 - If the page is for a method or property, enter a link to the parent class. Otherwise, leave it blank.  
: 3 - If the page is for a subclass, enter a link to the parent member.  
: 3 - If the page is for a subclass, enter a link to the parent member. Otherwise, leave it blank.  




For example, the following code will generate a template for a ''Version 10'' call that is associated with the ''Repository'' class. Notice the period ('''.''') before the link and how the code uses the pipe character (<nowiki> | </nowiki>) to change the way the link is displayed.
For example, the following code will generate a template for a call that was created in ''API Version 10'' and is associated with the ''Repository'' class. Notice the period ('''.''') before the link and how the code uses the pipe character (<nowiki> | </nowiki>) to change the way the link is displayed.


<pre> {{Template:APIBreadcrumb|10|.[[Repository Class|Repository]]}} </pre>
<pre> {{Template:APIBreadcrumb|10|.[[Repository Class|Repository]]}} </pre>

Revision as of 22:02, 29 July 2015


Template Documentation

Used for: Synthesis API reference documentation pages only


This boilerplate template creates the breadcrumb found in the method and property pages. If you're looking for the breadcrumb link for API classes and enums, see Template:APIBreadcrumbClass.

This breadcrumb link resembles the navigation element found in VBA and VB.NET's Object Browser window, and it serves as our main method for navigating the API product.

The breadcrumb contains the following information:

a) The API version in which the call became available.
b) The name of the object library.*
c) The name of the parent object and/or member, if applicable.


* Note that the name and link to the V9/V10 SynthesisAPI object library is hard coded into this template. If Development creates a new object library in the future, please create a new breadcrumb template for that library. This way, you have a method for finding all wiki pages related to a particular library. (As of July 2015, we've decided to stop using admin categories to find related pages. Templates, along with the "What links here" utility, are now used for that purpose.)

Usage

The template has one required parameter and two optional ones, depending on what is being documented.

1 - Enter the API version in which the call was first introduced. (Required)
2 - If the page is for a method or property, enter a link to the parent class. Otherwise, leave it blank.
3 - If the page is for a subclass, enter a link to the parent member. Otherwise, leave it blank.


For example, the following code will generate a template for a call that was created in API Version 10 and is associated with the Repository class. Notice the period (.) before the link and how the code uses the pipe character ( | ) to change the way the link is displayed.

 {{Template:APIBreadcrumb|10|.[[Repository Class|Repository]]}} 

The output appears as follows:

Member of: SynthesisAPI10.Repository