LCOV - code coverage report
Current view: top level - lib/src/voip/models - call_participant.dart (source / functions) Coverage Total Hit
Test: merged.info Lines: 86.7 % 15 13
Test Date: 2025-01-14 13:39:53 Functions: - 0 0

            Line data    Source code
       1              : import 'package:matrix/matrix.dart';
       2              : 
       3              : class CallParticipant {
       4              :   final VoIP voip;
       5              :   final String userId;
       6              :   final String? deviceId;
       7              : 
       8            2 :   CallParticipant(
       9              :     this.voip, {
      10              :     required this.userId,
      11              :     this.deviceId,
      12              :   });
      13              : 
      14            2 :   bool get isLocal =>
      15           10 :       userId == voip.client.userID && deviceId == voip.client.deviceID;
      16              : 
      17            2 :   String get id {
      18            2 :     String pid = userId;
      19            2 :     if (deviceId != null) {
      20            6 :       pid += ':$deviceId';
      21              :     }
      22              :     return pid;
      23              :   }
      24              : 
      25            0 :   @override
      26              :   String toString() {
      27            0 :     return id;
      28              :   }
      29              : 
      30            2 :   @override
      31              :   bool operator ==(Object other) =>
      32              :       identical(this, other) ||
      33            2 :       (other is CallParticipant &&
      34            6 :           userId == other.userId &&
      35            6 :           deviceId == other.deviceId);
      36              : 
      37            2 :   @override
      38           10 :   int get hashCode => Object.hash(userId.hashCode, deviceId.hashCode);
      39              : }
        

Generated by: LCOV version 2.0-1