|
360 | 360 | sub-instance that validated against the schema containing the LDO.
|
361 | 361 | </t>
|
362 | 362 | <t>
|
363 |
| - <xref target="hrefPointers">"hrefPointers"</xref> allows adjusting |
| 363 | + <xref target="templatePointers">"templatePointers"</xref> allows adjusting |
364 | 364 | the location from which instance data is resolved on a per-variable
|
365 | 365 | basis.
|
366 | 366 | </t>
|
|
550 | 550 | express a requirement for those variables that can be supplied via input,
|
551 | 551 | some variables must be resolved from instance data. When that instance
|
552 | 552 | data is not required by the context schema, the
|
553 |
| - <xref target="hrefRequired">"hrefRequired</xref> keyword may be used to |
554 |
| - indicate that when the instance data is not available, the link does |
555 |
| - not apply. |
| 553 | + <xref target="templateRequired">"templateRequired</xref> keyword may |
| 554 | + be used to indicate that when the instance data is not available, the |
| 555 | + link does not apply. |
556 | 556 | </t>
|
557 | 557 | </section>
|
558 | 558 | </section>
|
559 | 559 |
|
560 | 560 | </section>
|
561 | 561 |
|
562 |
| - <section title="hrefPointers" anchor="hrefPointers"> |
| 562 | + <section title="templatePointers" anchor="templatePointers"> |
563 | 563 | <t>
|
564 |
| - The value of the "hrefPointers" link description property MUST be |
| 564 | + The value of the "templatePointers" link description property MUST be |
565 | 565 | an object. Each property value in the object MUST be a valid
|
566 | 566 | <xref target="RFC6901">JSON Pointer</xref>, or a valid
|
567 | 567 | <xref target="I-D.luff-relative-json-pointer">Relative JSON Pointer</xref>
|
|
596 | 596 | {
|
597 | 597 | "rel": "self",
|
598 | 598 | "href": "/trees/{rootId}/nodes/{id}",
|
599 |
| - "hrefPointers": { |
| 599 | + "templatePointers": { |
600 | 600 | "rootId": "/id"
|
601 | 601 | }
|
602 | 602 | },
|
603 | 603 | {
|
604 | 604 | "rel": "up",
|
605 | 605 | "href": "/trees/{rootId}/nodes/{parentId}",
|
606 |
| - "hrefPointers": { |
| 606 | + "templatePointers": { |
607 | 607 | "rootId": "/id",
|
608 | 608 | "parentId": "2/id"
|
609 | 609 | },
|
610 |
| - "hrefRequired": ["parentId"] |
| 610 | + "templateRequired": ["parentId"] |
611 | 611 | }
|
612 | 612 | ]
|
613 | 613 | }]]>
|
614 | 614 | </artwork>
|
615 | 615 | </figure>
|
616 | 616 | <t>
|
617 | 617 | In "self" link, the context node's id resolves with the standard process and
|
618 |
| - therefore does not appear in "hrefPointers". In both "self" and "up" links, |
| 618 | + therefore does not appear in "templatePointers". In both "self" and "up" links, |
619 | 619 | the root id is located using an absolute JSON Pointer. Finally, in "up" link,
|
620 | 620 | the parent node uses a Relative JSON Pointer, going up two levels (one level up
|
621 | 621 | is the array of children, two levels up is the whole parent node), and then
|
|
659 | 659 | </t>
|
660 | 660 | <t>
|
661 | 661 | For the root node, the relative pointer for the parent doesn't point
|
662 |
| - to anything, so <xref target="hrefRequired">"hrefRequired"</xref> |
| 662 | + to anything, so <xref target="templateRequired">"templateRequired"</xref> |
663 | 663 | prevents the link from being used with that node.
|
664 | 664 | </t>
|
665 | 665 | </section>
|
|
755 | 755 | </t>
|
756 | 756 | </section>
|
757 | 757 |
|
758 |
| - <section title="hrefRequired" anchor="hrefRequired"> |
| 758 | + <section title="templateRequired" anchor="templateRequired"> |
759 | 759 | <t>
|
760 | 760 | The value of this keyword MUST be an array, and the elements MUST be unique.
|
761 | 761 | Each element SHOULD match a variable in the link's URI Template, without
|
|
766 | 766 | <figure>
|
767 | 767 | <preamble>
|
768 | 768 | Here is a simplified version of the "up" link from the
|
769 |
| - <xref target="hrefPointers">"hrefPointers</xref> tree example, |
| 769 | + <xref target="templatePointers">"templatePointers</xref> tree example, |
770 | 770 | modified to only use the parent identifier for its "href" template.
|
771 | 771 | While each individual node is required to have an "id" field, the
|
772 | 772 | "up" link uses the parent node's field, and the root node, by definition,
|
773 |
| - does not have a parent node. Putting "parentId" in "hrefRequired" ensures |
774 |
| - that the "up" link is correctly unusable with the root node. |
| 773 | + does not have a parent node. Putting "parentId" in "templateRequired" |
| 774 | + ensures that the "up" link is correctly unusable with the root node. |
775 | 775 | </preamble>
|
776 | 776 | <artwork>
|
777 | 777 | <![CDATA[{
|
778 | 778 | "rel": "up",
|
779 | 779 | "href": "/nodes/{parentId}",
|
780 |
| - "hrefPointers": { |
| 780 | + "templatePointers": { |
781 | 781 | "parentId": "2/id"
|
782 | 782 | },
|
783 |
| - "hrefRequired": ["parentId"] |
| 783 | + "templateRequired": ["parentId"] |
784 | 784 | }]]>
|
785 | 785 | </artwork>
|
786 | 786 | </figure>
|
|
0 commit comments