View Categories

s.option

< 1 min read

Table of Contents

Syntax #

s.option

Purpose #

The s.option annotation is used to tag a span element as being an optional argument in a function, API, command, or any other programming element that takes arguments.

Example #

The following is an example of a time when you might want to use the annotation

 

The following is an example of a rule that will apply the annotation

The following is the DITA XML output for the rule:

<p>      len is the length of the password</p>

<p><option>alpha</option> is the number of letters in the password (upper and lowercase)</p>

<p><option>num</option> is the number of numbers in the password</p>

<p><option>sym</option> is the number of symbols in the password</p>

<p>If no values are given for <option>alpha</option>, <option>num</option>, and <option>sym</option>, random values totalling len will be assigned.</p>