DBusObjectPath constructor
DBusObjectPath(
- String value
Creates a new D-Bus object path with the given value
.
An exception is shown if value
is not a valid object path.
Implementation
DBusObjectPath(String value) : super(value) {
if (value != '/') {
if (value.contains(RegExp('[^a-zA-Z0-9_/]')) ||
value.contains('//') ||
!value.startsWith('/') ||
value.endsWith('/')) {
throw ArgumentError.value(value, 'value', 'Invalid object path');
}
}
}