blob: 340e7f6b92b582b1f98dff389a3d46ac501da098 [file] [log] [blame]
// Copyright 2015 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
module reaper;
import "services/reaper/transfer.mojom";
// Reaper maintains a graph of references between applications and based on that
// decides when to shut down applications.
interface Reaper {
// Generates a secret that identifies the calling application for use with
// reaper::Transfer::Complete().
GetApplicationSecret() => (uint64 secret);
// Create a new reference. A reference is composed of two nodes.Initially,
// both nodes are owned by the calling application. Node ids must be unique
// within a given application.
CreateReference(uint32 source_node, uint32 target_node);
// Drop a node. The node and containing reference both becomes invalid.
DropNode(uint32 node);
// Initiates a transfer of |node| to another application. Pass the other end
// of |transfer| to the destination application. The destination application
// should then call Complete() on |transfer| to finalize the transfer.
StartTransfer(uint32 node, Transfer& transfer);
// No-op used for creating ordering between interfaces.
Ping() => ();
};