Doug Horn | 1427b6a | 2018-12-11 13:19:16 -0800 | [diff] [blame] | 1 | // Copyright 2018 The Fuchsia Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | library fuchsia.process; |
| 6 | |
| 7 | using fuchsia.ldsvc; |
| 8 | using zx; |
| 9 | |
| 10 | const uint32 MAX_RESOLVE_NAME = 2048; |
| 11 | |
| 12 | [Discoverable, Layout = "Simple"] |
| 13 | interface Resolver { |
| 14 | // Resolves the given |name| to an |executable| and an shared library loader. |
| 15 | // |
| 16 | // If present, the |executable| is suitable for use as the |executable| |
| 17 | // property of |LaunchInfo|. If present, the |ldsvc| is suitable for use as |
| 18 | // the PA_LDSVC_LOADER handle when launching the process. |
| 19 | // |
| 20 | // For example, the resolver might locate the given |name| inside a package |
| 21 | // and return the executable binary from the package as well as a shared |
| 22 | // library loader scoped to that package. |
| 23 | 1: Resolve(string:MAX_RESOLVE_NAME name) -> (zx.status status, |
| 24 | handle<vmo>? executable, |
| 25 | fuchsia.ldsvc.Loader? ldsvc); |
| 26 | }; |