InspectorServer: Add is_inspectable
IPC
This commit is contained in:
parent
ee38f5241d
commit
00c8b74ab4
Notes:
sideshowbarker
2024-07-18 17:01:34 +09:00
Author: https://github.com/matthewbjones Commit: https://github.com/SerenityOS/serenity/commit/00c8b74ab42 Pull-request: https://github.com/SerenityOS/serenity/pull/7674 Issue: https://github.com/SerenityOS/serenity/issues/7456
3 changed files with 11 additions and 0 deletions
Userland/Services/InspectorServer
|
@ -81,4 +81,13 @@ Messages::InspectorServer::IdentifyResponse ClientConnection::identify(pid_t pid
|
|||
return response;
|
||||
}
|
||||
|
||||
Messages::InspectorServer::IsInspectableResponse ClientConnection::is_inspectable(pid_t pid)
|
||||
{
|
||||
auto process = InspectableProcess::from_pid(pid);
|
||||
if (!process)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -28,6 +28,7 @@ private:
|
|||
virtual Messages::InspectorServer::SetInspectedObjectResponse set_inspected_object(pid_t, u64 object_id) override;
|
||||
virtual Messages::InspectorServer::SetObjectPropertyResponse set_object_property(pid_t, u64 object_id, String const& name, String const& value) override;
|
||||
virtual Messages::InspectorServer::IdentifyResponse identify(pid_t) override;
|
||||
virtual Messages::InspectorServer::IsInspectableResponse is_inspectable(pid_t) override;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -4,4 +4,5 @@ endpoint InspectorServer
|
|||
set_inspected_object(i32 pid, u64 object_id) => (bool success)
|
||||
set_object_property(i32 pid, u64 object_id, String name, String value) => (bool success)
|
||||
identify(i32 pid) => (String json)
|
||||
is_inspectable(i32 pid) => (bool inspectable)
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue