final case class Documentation(summary: String = "", pages: Seq[Page] = _root_.scala.Seq.empty, rules: Seq[DocumentationRule] = _root_.scala.Seq.empty, documentationRootUrl: String = "", overview: String = "", unknownFields: UnknownFieldSet = ...) extends GeneratedMessage with Updatable[Documentation] with Product with Serializable
Documentation provides the information for describing a service.
Example: <pre><code>documentation: summary: > The Google Calendar API gives access to most calendar features. pages:
- name: Overview content: (== include google/foo/overview.md ==)
- name: Tutorial
content: (== include google/foo/tutorial.md ==)
subpages;
- name: Java content: (== include google/foo/tutorial_java.md ==) rules:
- selector: google.calendar.Calendar.Get description: > ...
- selector: google.calendar.Calendar.Put description: > ... </code></pre> Documentation is provided in markdown syntax. In addition to standard markdown features, definition lists, tables and fenced code blocks are supported. Section headers can be provided and are interpreted relative to the section nesting of the context where a documentation fragment is embedded.
Documentation from the IDL is merged with documentation defined via the config at normalization time, where documentation provided by config rules overrides IDL provided.
A number of constructs specific to the API platform are supported in documentation text.
In order to reference a proto element, the following notation can be used: <pre><code>[fully.qualified.proto.name][]</code></pre> To override the display text used for the link, this can be used: <pre><code>[display text][fully.qualified.proto.name]</code></pre> Text can be excluded from doc using the following notation: <pre><code>(-- internal comment --)</code></pre>
A few directives are available in documentation. Note that
directives must appear on a single line to be properly
identified. The include directive includes a markdown file from
an external source:
<pre><code>(== include path/to/file ==)</code></pre>
The resource_for directive marks a message to be the resource of
a collection in REST view. If it is not specified, tools attempt
to infer the resource from the operations in a collection:
<pre><code>(== resource_for v1.shelves.books ==)</code></pre>
The directive suppress_warning does not directly affect documentation
and is documented together with service config validation.
- summary
A short summary of what the service does. Can only be provided by plain text.
- pages
The top level pages for the documentation set.
- rules
A list of documentation rules that apply to individual API elements. **NOTE:** All service configuration rules follow "last one wins" order.
- documentationRootUrl
The URL to the root of documentation.
- overview
Declares a single overview page. For example: <pre><code>documentation: summary: ... overview: (== include overview.md ==) </code></pre> This is a shortcut for the following declaration (using pages style): <pre><code>documentation: summary: ... pages:
- name: Overview
content: (== include overview.md ==)
</code></pre>
Note: you cannot specify both
overviewfield andpagesfield.
- name: Overview
content: (== include overview.md ==)
</code></pre>
Note: you cannot specify both
- Annotations
- @SerialVersionUID()
- Alphabetic
- By Inheritance
- Documentation
- Product
- Equals
- Updatable
- GeneratedMessage
- Serializable
- Serializable
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
-
new
Documentation(summary: String = "", pages: Seq[Page] = _root_.scala.Seq.empty, rules: Seq[DocumentationRule] = _root_.scala.Seq.empty, documentationRootUrl: String = "", overview: String = "", unknownFields: UnknownFieldSet = ...)
- summary
A short summary of what the service does. Can only be provided by plain text.
- pages
The top level pages for the documentation set.
- rules
A list of documentation rules that apply to individual API elements. **NOTE:** All service configuration rules follow "last one wins" order.
- documentationRootUrl
The URL to the root of documentation.
- overview
Declares a single overview page. For example: <pre><code>documentation: summary: ... overview: (== include overview.md ==) </code></pre> This is a shortcut for the following declaration (using pages style): <pre><code>documentation: summary: ... pages:
- name: Overview
content: (== include overview.md ==)
</code></pre>
Note: you cannot specify both
overviewfield andpagesfield.
- name: Overview
content: (== include overview.md ==)
</code></pre>
Note: you cannot specify both
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def addAllPages(__vs: Iterable[Page]): Documentation
- def addAllRules(__vs: Iterable[DocumentationRule]): Documentation
- def addPages(__vs: Page*): Documentation
- def addRules(__vs: DocumentationRule*): Documentation
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clearPages: Documentation
- def clearRules: Documentation
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
companion: Documentation.type
- Definition Classes
- Documentation → GeneratedMessage
- def discardUnknownFields: Documentation
- val documentationRootUrl: String
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
getField(__field: FieldDescriptor): PValue
- Definition Classes
- Documentation → GeneratedMessage
-
def
getFieldByNumber(__fieldNumber: Int): Any
- Definition Classes
- Documentation → GeneratedMessage
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val overview: String
- val pages: Seq[Page]
- val rules: Seq[DocumentationRule]
-
def
serializedSize: Int
- Definition Classes
- Documentation → GeneratedMessage
- val summary: String
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
final
def
toByteArray: Array[Byte]
- Definition Classes
- GeneratedMessage
-
final
def
toByteString: ByteString
- Definition Classes
- GeneratedMessage
-
final
def
toPMessage: PMessage
- Definition Classes
- GeneratedMessage
-
def
toProtoString: String
- Definition Classes
- Documentation → GeneratedMessage
- val unknownFields: UnknownFieldSet
-
def
update(ms: (Lens[Documentation, Documentation]) ⇒ Mutation[Documentation]*): Documentation
- Definition Classes
- Updatable
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- def withDocumentationRootUrl(__v: String): Documentation
- def withOverview(__v: String): Documentation
- def withPages(__v: Seq[Page]): Documentation
- def withRules(__v: Seq[DocumentationRule]): Documentation
- def withSummary(__v: String): Documentation
- def withUnknownFields(__v: UnknownFieldSet): Documentation
-
final
def
writeDelimitedTo(output: OutputStream): Unit
- Definition Classes
- GeneratedMessage
-
def
writeTo(_output__: CodedOutputStream): Unit
- Definition Classes
- Documentation → GeneratedMessage
-
final
def
writeTo(output: OutputStream): Unit
- Definition Classes
- GeneratedMessage