Class ConnectionProperties.Builder

    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • data

        public ConnectionProperties.Builder data​(String data)
        Call this method to set the secure (server-side) data associated to this Connection. Every client will receive this data in property Connection.data. Object Connection can be retrieved by subscribing to event connectionCreated of Session object in your clients.
        • If you have provided no data in your clients when calling method Session.connect(TOKEN, DATA) (DATA not defined), then Connection.data will only have this data(String) property.
        • If you have provided some data when calling Session.connect(TOKEN, DATA) (DATA defined), then Connection.data will have the following structure: "CLIENT_DATA%/%SERVER_DATA", being CLIENT_DATA the second parameter passed in OpenVidu Browser in method Session.connect and SERVER_DATA this data(String) property.
      • adaptativeBitrate

        public ConnectionProperties.Builder adaptativeBitrate​(boolean adaptativeBitrate)
        Call this method to set whether to use adaptative bitrate (and therefore adaptative quality) or not. For local network connections that do not require media transcoding this can be disabled to save CPU power. If you are not sure if transcoding might be necessary, setting this property to false may result in media connections not being established. Default to true.

        Only for ConnectionType.IPCAM
      • onlyPlayWithSubscribers

        public ConnectionProperties.Builder onlyPlayWithSubscribers​(boolean onlyPlayWithSubscribers)
        Call this method to set whether to enable the IP camera stream only when some user is subscribed to it, or not. This allows you to reduce power consumption and network bandwidth in your server while nobody is asking to receive the camera's video. On the counterpart, first user subscribing to the IP camera stream will take a little longer to receive its video. Default to true.

        Only for ConnectionType.IPCAM
      • networkCache

        public ConnectionProperties.Builder networkCache​(int networkCache)
        Call this method to set the size of the buffer of the endpoint receiving the IP camera's stream, in milliseconds. The smaller it is, the less delay the signal will have, but more problematic will be in unstable networks. Use short buffers only if there is a quality connection between the IP camera and OpenVidu Server. Default to 2000.

        Only for ConnectionType.IPCAM