DriveRpcClient class
Issues OmnyDrive RPCs over a SessionMode.drive RemoteSession.
Requests are written as framed DriveMessages on the session's stdin and
matched to their replies on stdout by a monotonic correlation id, so several
requests may be in flight at once. Inbound bytes immediately replenish the
node's send window, keeping large reads flowing under the channel's credit
limit.
Constructors
- DriveRpcClient(RemoteSession _session)
-
Wraps an already-open drive
session.
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
-
close(
) → Future< void> - Closes the session and fails any in-flight requests.
-
delete(
String path) → Future< void> -
Deletes
pathunder the served root. -
gitClone(
String url, {String? branch, int? depth, bool bare = false}) → Future< String> -
Clones
urlinto the served root, returning the resulting head SHA. -
gitHead(
) → Future< String> - Returns the current git head SHA of the served root.
-
gitSync(
{required String url, required String direction, required String baseline}) → Future< Map< String, dynamic> > -
Synchronizes the served git tree in
directionfrombaseline. Returns the raw reply header (head,applied, optionalpublishedBranch/conflict). -
manifest(
) → Future< Map< String, dynamic> > - Fetches the served directory manifest as a JSON map.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
read(
String path) → Future< Uint8List> -
Reads the bytes of
pathunder the served root. -
toString(
) → String -
A string representation of this object.
inherited
-
write(
String path, List< int> bytes) → Future<void> -
Writes
bytestopathunder the served root.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited