services:
    oro_comment.form.type.comment_api:
        class: Oro\Bundle\CommentBundle\Form\Type\CommentTypeApi
        arguments:
            - '@oro_entity_config.config_manager'
        tags:
            - { name: form.type, alias: oro_comment_api }

    Oro\Bundle\CommentBundle\Form\Type\CommentTypeApi:
        alias: oro_comment.form.comment.api

    oro_comment.form.comment.api:
        class: Symfony\Component\Form\Form
        public: true
        factory: ['@form.factory', createNamed]
        arguments:
            - ''
            - Oro\Bundle\CommentBundle\Form\Type\CommentTypeApi

    oro_comment.api.form.handler:
        class: Oro\Bundle\CommentBundle\Form\Handler\CommentApiHandler
        public: true
        arguments:
            - '@oro_comment.form.comment.api'
            - '@request_stack'
            - '@doctrine.orm.entity_manager'
            - '@oro_entity_config.config_manager'
