{{!--~ shape_traits
-- display Traits table for a shape
~--}}{{#*inline "shape_traits" }}
{{#if (traits this)}}
Namespace {{ namespace }}
{{~> toc title="Services" kind="service"}}
{{~> toc title="Operations" kind="operation"}}
{{~> toc title="Structures" kind="structure"}}
{{~> toc title="Traits" kind="trait"}}
{{~> toc title="Simple" kind="simple"}}
{{~> toc title="Lists" kind="list"}}
{{~> toc title="Maps" kind="map"}}
{{#each (filter_namespace namespace model.shapes) ~}}
{{#if (is_trait this) ~}}
{{~> display_trait }}
{{else ~}}
{{#if (is_simple this.type) ~}}
{{~> display_simple }}
{{/if ~}}
{{#if (eq this.type "list") ~}}
{{~> type_head}}
|
|
|
member: |
{{ typ member.target ../namespace }} |
|
{{ >shape_traits ns=../namespace }}
{{~/if }}
{{#if (eq this.type "set") ~}}
{{~> type_head}}
|
|
|
member: |
{{ typ member.target ../namespace }} |
{{ doc member }} |
{{ >shape_traits ns=../namespace }}
{{~/if }}
{{#if (eq type "map") ~}}
{{~> type_head}}
|
|
|
key: |
{{ typ this.key.target ../namespace }} |
{{ doc this.key }} |
value: |
{{ typ value.target ../namespace}} |
{{ doc value }} |
{{ >shape_traits ns=../namespace }}
{{~/if }}
{{#if (eq type "operation") ~}}
{{~> type_head}}
|
|
|
{{~#if input }}
input: |
{{ typ input.target ../namespace }} |
{{ doc input }} |
{{~/if}}
{{~#if output }}
output: |
{{ typ output.target ../namespace }} |
{{ doc output }} |
{{~/if}}
{{~#if errors }}
errors: |
{{#each errors}}
- {{ typ target }}
{{/each}}
|
{{ doc errors }} |
{{~/if}}
{{ >shape_traits ns=../namespace }}
{{~/if }}
{{~#if (eq type "structure") }}
{{~> type_head }}
|
|
|
{{~#each members }}
{{member_name @key}}: |
{{ typ target ../../namespace }} |
{{ doc
this }} |
{{~/each }}
{{~ >shape_traits ns=../namespace }}
{{~/if }}
{{#if (eq type "service") }}
{{~> type_head}}
{{~#if operations }}
{{~/if}}
{{~ >shape_traits ns=../namespace }}
{{~/if }}
{{~/if }}
{{~/each }}
{{~/inline }}
{{~> page_base ~}}