Skip to content
This repository was archived by the owner on Feb 17, 2024. It is now read-only.

Trait merging#529

Open
ddenisenko wants to merge 1 commit intoraml-org:masterfrom
ddenisenko:TraitReferenceResolving
Open

Trait merging#529
ddenisenko wants to merge 1 commit intoraml-org:masterfrom
ddenisenko:TraitReferenceResolving

Conversation

@ddenisenko
Copy link
Copy Markdown

Refactored trait merging algorithm structure. Modified merging algorithm to use YAML terms. Added parameters application and reference patching sections.

…thm to use YAML terms. Added parameters application and reference patching sections.
@ddenisenko
Copy link
Copy Markdown
Author

@sichvoge please review and modify if needed

is: [ { secured : { tokenName: token } } ]
```

To resolve a collision arising from this inequality, priority is given to the trait in closest proximity to the target method or resource. In the previous example, the `tokenName` parameter value for the `GET:/servers` method is `token`, and the trait list consists of single trait occurrence: `[ {secured:{ tokenName:token}} ]`.
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, we support applying same trate with different parameters raml-org/raml-js-parser-2#94

@sichvoge
Copy link
Copy Markdown
Contributor

sichvoge commented Oct 4, 2016

@ddenisenko where are we with this?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

5 participants