-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(ns-asyncapi-2-0): add support for Kafka Channel Obj
Refs #387
- Loading branch information
Showing
8 changed files
with
47 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
apidom/packages/apidom-ns-asyncapi-2-0/src/elements/bindings/kafka/KafkaChannelBinding.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { Attributes, Meta, ObjectElement } from 'minim'; | ||
|
||
class KafkaChannelBinding extends ObjectElement { | ||
constructor(content?: Record<string, unknown>, meta?: Meta, attributes?: Attributes) { | ||
super(content, meta, attributes); | ||
this.element = 'kafkaChannelBinding'; | ||
} | ||
} | ||
|
||
export default KafkaChannelBinding; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
...asyncapi-2-0/src/refractor/visitors/async-api-2-0/bindings/kafka/channel-binding/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import stampit from 'stampit'; | ||
import { always } from 'ramda'; | ||
|
||
import KafkaChannelBindingElement from '../../../../../../elements/bindings/kafka/KafkaChannelBinding'; | ||
import FallbackVisitor from '../../../../FallbackVisitor'; | ||
import FixedFieldsVisitor from '../../../../generics/FixedFieldsVisitor'; | ||
|
||
const KafkaChannelBindingVisitor = stampit(FixedFieldsVisitor, FallbackVisitor, { | ||
props: { | ||
specPath: always(['document', 'objects', 'bindings', 'kafka', 'ChannelBinding']), | ||
canSupportSpecificationExtensions: false, | ||
}, | ||
init() { | ||
this.element = new KafkaChannelBindingElement(); | ||
}, | ||
}); | ||
|
||
export default KafkaChannelBindingVisitor; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters