Array unification switch
[hiphop-php.git] / hphp / hack / src / providers / decl_service_client.mli
blobb581127e105a922d2c992a43023cfc2b4d04fc31
1 (*
2 * Copyright (c) Facebook, Inc. and its affiliates.
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the "hack" directory of this source tree.
7 *)
9 (* `t` represents a decl service, i.e. something where you can make requests
10 for decls and get back answers. Often these requests will block upon IO. *)
11 type t
13 val from_raw_client :
14 Decl_ipc_ffi_externs.decl_client ->
15 bool ->
16 bool ->
17 (string * string) list ->
20 val rpc_get_fun : t -> string -> Typing_defs.fun_elt option
22 val rpc_get_class : t -> string -> Shallow_decl_defs.shallow_class option
24 val rpc_get_typedef : t -> string -> Typing_defs.typedef_type option
26 val rpc_get_record_def : t -> string -> Typing_defs.record_def_type option
28 val rpc_get_gconst : t -> string -> Typing_defs.decl_ty option
30 val rpc_get_gconst_path : t -> string -> Relative_path.t option
32 val rpc_get_fun_path : t -> string -> Relative_path.t option
34 val rpc_get_type_path_and_kind :
35 t -> string -> (Relative_path.t * Naming_types.kind_of_type) option
37 val rpc_get_fun_canon_name : t -> string -> string option
39 val rpc_get_type_canon_name : t -> string -> string option
41 val parse_and_cache_decls_in : t -> Relative_path.t -> string -> unit