Skip to content

Commit

Permalink
imports tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
Brazol committed Jan 15, 2025
1 parent e0e3e4e commit 11f1ca6
Show file tree
Hide file tree
Showing 25 changed files with 125 additions and 25 deletions.
27 changes: 26 additions & 1 deletion packages/stream_video/lib/src/call/call.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,33 +9,58 @@ import 'package:meta/meta.dart';
import 'package:stream_webrtc_flutter/stream_webrtc_flutter.dart';
import 'package:synchronized/synchronized.dart';

import '../../open_api/video/coordinator/api.dart';
import '../../protobuf/video/sfu/event/events.pb.dart' show ReconnectDetails;
import '../../stream_video.dart';
import '../../version.g.dart';
import '../call_state.dart';
import '../coordinator/coordinator_client.dart';
import '../coordinator/models/coordinator_events.dart';
import '../coordinator/models/coordinator_models.dart';
import '../coordinator/open_api/error/open_api_error.dart';
import '../errors/video_error_composer.dart';
import '../logger/impl/tagged_logger.dart';
import '../logger/stream_log.dart';
import '../models/call_received_data.dart';
import '../models/models.dart';
import '../platform_detector/platform_detector.dart';
import '../retry/retry_policy.dart';
import '../sfu/data/events/sfu_events.dart';
import '../sfu/data/models/sfu_error.dart';
import '../sfu/data/models/sfu_track_type.dart';
import '../shared_emitter.dart';
import '../state_emitter.dart';
import '../stream_video.dart';
import '../utils/cancelable_operation.dart';
import '../utils/cancelables.dart';
import '../utils/extensions.dart';
import '../utils/future.dart';
import '../utils/none.dart';
import '../utils/result.dart';
import '../utils/standard.dart';
import '../utils/subscriptions.dart';
import '../webrtc/media/media_constraints.dart';
import '../webrtc/model/rtc_video_dimension.dart';
import '../webrtc/model/rtc_video_parameters.dart';
import '../webrtc/model/stats/rtc_codec.dart';
import '../webrtc/model/stats/rtc_ice_candidate_pair.dart';
import '../webrtc/model/stats/rtc_inbound_rtp_video_stream.dart';
import '../webrtc/model/stats/rtc_outbound_rtp_video_stream.dart';
import '../webrtc/peer_type.dart';
import '../webrtc/rtc_manager.dart';
import '../webrtc/rtc_media_device/rtc_media_device.dart';
import '../webrtc/rtc_media_device/rtc_media_device_notifier.dart';
import '../webrtc/rtc_track/rtc_track.dart';
import '../webrtc/sdp/editor/sdp_editor_impl.dart';
import '../webrtc/sdp/policy/sdp_policy.dart';
import '../ws/ws.dart';
import 'call_connect_options.dart';
import 'call_events.dart';
import 'call_reject_reason.dart';
import 'call_type.dart';
import 'permissions/permissions_manager.dart';
import 'session/call_session.dart';
import 'session/call_session_factory.dart';
import 'session/dynascale_manager.dart';
import 'state/call_state_notifier.dart';

typedef OnCallPermissionRequest = void Function(
Expand Down
5 changes: 4 additions & 1 deletion packages/stream_video/lib/src/call/call_connect_options.dart
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import 'package:equatable/equatable.dart';

import '../../stream_video.dart';
import '../models/models.dart';
import '../webrtc/media/media_constraints.dart';
import '../webrtc/rtc_media_device/rtc_media_device.dart';
import '../webrtc/rtc_track/rtc_track.dart';

class CallConnectOptions with EquatableMixin {
const CallConnectOptions({
Expand Down
5 changes: 4 additions & 1 deletion packages/stream_video/lib/src/call/call_events.dart
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
import 'package:equatable/equatable.dart';

import '../../stream_video.dart';
import '../call_state.dart';
import '../coordinator/models/coordinator_events.dart';
import '../models/models.dart';
import '../sfu/data/events/sfu_events.dart';
import '../sfu/data/models/sfu_audio_level.dart';
import '../sfu/data/models/sfu_call_grants.dart';
import '../sfu/data/models/sfu_connection_info.dart';
import '../sfu/data/models/sfu_track_type.dart';
import '../sfu/sfu_extensions.dart';
import '../shared_emitter.dart';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
import 'package:meta/meta.dart';

import '../../../stream_video.dart';
import '../../../open_api/video/coordinator/api.dart';
import '../../call_state.dart';
import '../../coordinator/coordinator_client.dart';
import '../../logger/impl/tagged_logger.dart';
import '../../models/models.dart';
import '../../utils/none.dart';
import '../../utils/result.dart';
import '../call.dart';
import '../state/call_state_notifier.dart';

typedef GetStateOrNull = CallState? Function();
Expand Down
13 changes: 12 additions & 1 deletion packages/stream_video/lib/src/call/session/call_session.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,32 +14,43 @@ import '../../../protobuf/video/sfu/event/events.pb.dart' as sfu_events;
import '../../../protobuf/video/sfu/models/models.pb.dart' as sfu_models;
import '../../../protobuf/video/sfu/models/models.pbenum.dart';
import '../../../protobuf/video/sfu/signal_rpc/signal.pb.dart' as sfu;
import '../../../stream_video.dart';
import '../../../version.g.dart';
import '../../disposable.dart';
import '../../errors/video_error.dart';
import '../../errors/video_error_composer.dart';
import '../../extensions/thermal_status_ext.dart';
import '../../logger/impl/tagged_logger.dart';
import '../../models/models.dart';
import '../../platform_detector/platform_detector.dart';
import '../../sfu/data/events/sfu_events.dart';
import '../../sfu/data/models/sfu_call_state.dart';
import '../../sfu/data/models/sfu_error.dart';
import '../../sfu/data/models/sfu_model_mapper_extensions.dart';
import '../../sfu/data/models/sfu_subscription_details.dart';
import '../../sfu/data/models/sfu_track_type.dart';
import '../../sfu/sfu_client.dart';
import '../../sfu/ws/sfu_ws.dart';
import '../../shared_emitter.dart';
import '../../utils/debounce_buffer.dart';
import '../../utils/none.dart';
import '../../utils/result.dart';
import '../../webrtc/media/media_constraints.dart';
import '../../webrtc/model/rtc_model_mapper_extensions.dart';
import '../../webrtc/model/rtc_tracks_info.dart';
import '../../webrtc/model/stats/rtc_printable_stats.dart';
import '../../webrtc/model/stats/rtc_stats.dart';
import '../../webrtc/peer_connection.dart';
import '../../webrtc/peer_type.dart';
import '../../webrtc/rtc_manager.dart';
import '../../webrtc/rtc_manager_factory.dart';
import '../../webrtc/rtc_media_device/rtc_media_device.dart';
import '../../webrtc/rtc_media_device/rtc_media_device_notifier.dart';
import '../../webrtc/rtc_track/rtc_track.dart';
import '../../webrtc/sdp/editor/sdp_editor.dart';
import '../../ws/ws.dart';
import '../state/call_state_notifier.dart';
import 'call_session_config.dart';
import 'dynascale_manager.dart';

const _tag = 'SV:CallSession';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,18 @@ import 'dart:async';
import 'package:rxdart/rxdart.dart';

import '../../../protobuf/video/sfu/signal_rpc/signal.pb.dart' as sfu;
import '../../../stream_video.dart';
import '../../extensions/call_participant_state_ext.dart';
import '../../logger/impl/tagged_logger.dart';
import '../../models/models.dart';
import '../../sfu/data/models/sfu_model_mapper_extensions.dart';
import '../../sfu/data/models/sfu_subscription_details.dart';
import '../../sfu/data/models/sfu_track_type.dart';
import '../../sfu/sfu_client.dart';
import '../../utils/debounce_buffer.dart';
import '../../utils/none.dart';
import '../../utils/result.dart';
import '../../webrtc/model/rtc_model_mapper_extensions.dart';
import '../../webrtc/model/rtc_video_dimension.dart';
import '../state/call_state_notifier.dart';

class IncomingVideoSettings {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
import 'package:collection/collection.dart';
import 'package:state_notifier/state_notifier.dart';

import '../../../../stream_video.dart';
import '../../../call_state.dart';
import '../../../errors/video_error.dart';
import '../../../logger/impl/tagged_logger.dart';
import '../../../models/call_received_data.dart';
import '../../../models/models.dart';
import '../../../sfu/data/models/sfu_error.dart';
import '../../../utils/none.dart';
import '../../../utils/result.dart';
import '../../call_connect_options.dart';

final _logger = taggedLogger(tag: 'SV:CoordNotifier');

Expand Down
4 changes: 3 additions & 1 deletion packages/stream_video/lib/src/call_state.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@ import 'package:collection/collection.dart';
import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';

import '../stream_video.dart';
import 'call/call_type.dart';
import 'models/models.dart';
import 'webrtc/rtc_media_device/rtc_media_device.dart';

/// Represents the call's state.
@immutable
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';

import '../../../stream_video.dart';
import '../../models/models.dart';

@immutable
abstract class CoordinatorModel with EquatableMixin {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,25 @@ import 'package:uuid/uuid.dart';

import '../../../../open_api/video/coordinator/api.dart' as open;
import '../../../composed_version.dart';
import '../../../stream_video.dart';
import '../../../open_api/video/coordinator/api.dart';
import '../../errors/video_error.dart';
import '../../errors/video_error_composer.dart';
import '../../latency/latency_service.dart';
import '../../location/location_service.dart';
import '../../logger/impl/tagged_logger.dart';
import '../../models/call_received_data.dart';
import '../../models/models.dart';
import '../../retry/retry_policy.dart';
import '../../shared_emitter.dart';
import '../../state_emitter.dart';
import '../../token/token.dart';
import '../../token/token_manager.dart';
import '../../utils/none.dart';
import '../../utils/result.dart';
import '../../utils/standard.dart';
import '../coordinator_client.dart';
import '../models/coordinator_connection_state.dart';
import '../models/coordinator_events.dart';
import '../models/coordinator_models.dart';
import 'coordinator_ws.dart';
import 'open_api_extensions.dart';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import 'package:collection/collection.dart';

import '../../../../open_api/video/coordinator/api.dart' as open;
import '../../../stream_video.dart';
import '../../../open_api/video/coordinator/api.dart';
import '../../errors/video_error.dart';
import '../../logger/stream_log.dart';
import '../../models/models.dart';
import '../../utils/standard.dart';

extension MemberExt on open.MemberResponse {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:tart/tart.dart';
import 'package:web_socket_channel/web_socket_channel.dart';

import '../../stream_video.dart';
import '../../open_api/video/coordinator/api.dart';
import 'video_error.dart';

/// TODO
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';

import '../../stream_video.dart';
import '../call/call_events.dart';
import 'models.dart';

@immutable
class StreamClosedCaption with EquatableMixin {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';

import '../../stream_video.dart';
import 'models.dart';

@immutable
class CallReceivedData with EquatableMixin {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import '../../stream_video.dart';
import '../sfu/data/models/sfu_subscription_details.dart';
import '../sfu/data/models/sfu_track_type.dart';
import '../webrtc/model/rtc_video_dimension.dart';

class SubscriptionChange {
SubscriptionChange.set({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';
import 'package:rxdart/rxdart.dart';

import '../../stream_video.dart';
import '../coordinator/coordinator_client.dart';
import '../stream_video.dart';

part 'call_kit_events.dart';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
import '../../../../protobuf/video/sfu/event/events.pb.dart' as sfu_events;
import '../../../../protobuf/video/sfu/models/models.pb.dart' as sfu_models;
import '../../../../stream_video.dart';
import '../../../webrtc/model/rtc_video_dimension.dart';
import '../models/sfu_audio_level.dart';
import '../models/sfu_audio_sender.dart';
import '../models/sfu_call_grants.dart';
import '../models/sfu_call_state.dart';
import '../models/sfu_codec.dart';
import '../models/sfu_connection_info.dart';
import '../models/sfu_connection_quality.dart';
import '../models/sfu_error.dart';
import '../models/sfu_goaway_reason.dart';
import '../models/sfu_model_mapper_extensions.dart';
import '../models/sfu_participant.dart';
import '../models/sfu_publish_options.dart';
import '../models/sfu_track_type.dart';
import '../models/sfu_video_layer_setting.dart';
import '../models/sfu_video_sender.dart';
import 'sfu_events.dart';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:meta/meta.dart';

import '../../../../stream_video.dart';
import 'sfu_codec.dart';
import 'sfu_track_type.dart';

@immutable
class SfuAudioSender {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import 'package:equatable/equatable.dart';

import '../../../../stream_video.dart';
import '../../../webrtc/model/rtc_video_dimension.dart';
import 'sfu_track_type.dart';

class SfuSubscriptionDetails with EquatableMixin {
const SfuSubscriptionDetails({
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:equatable/equatable.dart';
import '../../../../stream_video.dart';
import 'sfu_codec.dart';

import 'sfu_track_type.dart';
import 'sfu_video_layer_setting.dart';

class SfuVideoSender with EquatableMixin {
Expand Down
4 changes: 3 additions & 1 deletion packages/stream_video/lib/src/sfu/sfu_extensions.dart
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import 'package:collection/collection.dart';

import '../../stream_video.dart';
import '../call_state.dart';
import '../models/models.dart';
import '../utils/string.dart';
import 'data/models/sfu_participant.dart';

extension SfuParticipantX on SfuParticipant {
Expand Down
4 changes: 3 additions & 1 deletion packages/stream_video/lib/src/token/token.dart
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import 'package:equatable/equatable.dart';
import 'package:jose/jose.dart';

import '../../stream_video.dart';
import '../errors/video_error_composer.dart';
import '../logger/impl/tagged_logger.dart';
import '../models/models.dart';
import '../utils/result.dart';
import '../utils/standard.dart';

/// A function which can be used to request a Stream Video API token from your
Expand Down
4 changes: 3 additions & 1 deletion packages/stream_video/lib/src/token/token_manager.dart
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
import 'package:async/async.dart' as async;
import 'package:meta/meta.dart';

import '../../stream_video.dart';
import '../logger/impl/tagged_logger.dart';
import '../utils/cancelable_operation.dart';
import '../utils/future.dart';
import '../utils/result.dart';
import 'token.dart';

const _emptyUserId = 'stream:none';

Expand Down
Loading

0 comments on commit 11f1ca6

Please sign in to comment.