NetworkPermission class
Network permissions control network operations.
- Inheritance
-
- Object
- Permission
- NetworkPermission
Constructors
- NetworkPermission.connectTo(String host)
-
Allows connecting to the specified host.
factory
- NetworkPermission.connectToPort(String host, int port)
-
Allows connecting to the specified host and port.
factory
- NetworkPermission.listenOn(int port)
-
Allows listening on the specified port.
factory
Properties
- description → String
-
Human-readable description of what this permission allows.
no setteroverride
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- type → String
-
The type of permission (e.g., 'filesystem', 'network', 'process').
final
Methods
-
allows(
dynamic operation) → bool -
Checks if this permission allows the given operation.
override
-
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
- any → NetworkPermission
-
Allows all network operations.
final
- bind → NetworkPermission
-
Allows binding to any address/port.
final
- connect → NetworkPermission
-
Allows connecting to any host/port.
final
- listen → NetworkPermission
-
Allows listening on any port.
final