MediaSFU Angular
    Preparing search index...

    Class ReceiveRoomMessages

    Asynchronously retrieves and updates messages for a specified room from the server.

    This method communicates with the server to request messages for a specific room and updates the messages array accordingly.

    The function parameters.

    The socket instance used for communication.

    The name of the room to retrieve messages for.

    Function to update the messages array with the retrieved messages.

    A promise that resolves when the messages have been successfully retrieved and updated.

    Will log an error message if an error occurs during the process of retrieving messages.

    const options = {
    socket: socketInstance,
    roomName: 'Room1',
    updateMessages: (messages) => {
    // Logic to update messages
    },
    };

    await receiveRoomMessages(options);
    Index

    Constructors

    Methods

    Constructors

    Methods