/*
 * Copyright 2021 Free Software Foundation, Inc.
 *
 * This file is part of GNU Radio
 *
 * SPDX-License-Identifier: GPL-3.0-or-later
 *
 */

#include <pybind11/complex.h>
#include <pybind11/pybind11.h>
#include <pybind11/stl.h>

namespace py = pybind11;

#include <gnuradio/satlab/websocket_sink.h>
// pydoc.h is automatically generated in the build directory
#include <websocket_sink_pydoc.h>

void bind_websocket_sink(py::module& m)
{
    using websocket_sink = ::gr::satlab::websocket_sink;

    py::class_<websocket_sink,
	       gr::sync_block,
	       gr::block,
	       gr::basic_block,
	       std::shared_ptr<websocket_sink>>(m, "websocket_sink", D(websocket_sink))

        .def(py::init(&websocket_sink::make),
            py::arg("itemsize"),
            py::arg("port"),
            D(websocket_sink,make)
        )

        .def("set_greeting",&websocket_sink::set_greeting,       
             py::arg("msg"),
             D(websocket_sink,set_greeting)
        );
}
