PlatformFeatureSupport class
Utility class for checking platform-specific feature support.
This class provides methods to check whether specific MediaSFU features are supported on the current platform and to get appropriate messages for unsupported features.
Example:
if (!PlatformFeatureSupport.isSupported(MediasfuFeature.screenboard)) {
final message = PlatformFeatureSupport.getUnsupportedMessage(MediasfuFeature.screenboard);
showAlert(message: message, type: 'danger');
return;
}
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- isAndroid → bool
-
Returns true if the current platform is Android.
no setter
- isDesktop → bool
-
Returns true if the current platform is a desktop platform (Windows, macOS, or Linux).
no setter
- isIOS → bool
-
Returns true if the current platform is iOS.
no setter
- isLinux → bool
-
Returns true if the current platform is Linux.
no setter
- isMacOS → bool
-
Returns true if the current platform is macOS.
no setter
- isMobile → bool
-
Returns true if the current platform is a mobile platform (iOS or Android).
no setter
- isScreenboardSupported → bool
-
Convenience method to check screenboard support.
no setter
-
Convenience method to check screen share support.
no setter
- isVirtualBackgroundsSupported → bool
-
Convenience method to check virtual backgrounds support.
no setter
- isWeb → bool
-
Returns true if the current platform is web.
no setter
- isWhiteboardSupported → bool
-
Convenience method to check whiteboard support.
no setter
- isWindows → bool
-
Returns true if the current platform is Windows.
no setter
- platformName → String
-
Returns the current platform name as a human-readable string.
no setter
Static Methods
-
getSupportedPlatforms(
MediasfuFeature feature) → List< String> - Returns the list of supported platforms for a given feature.
-
getUnsupportedMessage(
MediasfuFeature feature, {bool includeAlternatives = true}) → String - Returns a user-friendly message for when a feature is not supported.
-
isSupported(
MediasfuFeature feature) → bool - Checks if a specific feature is supported on the current platform.