blob: 80ba88f1de9a35f7d3e8fa11c2ab11294a1c0767 [file] [log] [blame]
// Copyright 2019 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <zircon/syscalls/debug.h>
#include <zircon/types.h>
#include <ostream>
#include "src/lib/fidl_codec/printer.h"
namespace fidl_codec {
// Displays a handle.
// If handle.operation == kNoHandleDisposition, only the info part of zx_handle_disposition_t is
// used and printed.
// Else, the handle comes from the write of an "etc" function (zx_channel_write_etc or write part of
// a zx_channel_call_etc). In that case, the full disposition is used to print the handle.
void DisplayHandle(const zx_handle_disposition_t& handle, PrettyPrinter& printer);
void ObjTypeName(zx_obj_type_t obj_type, PrettyPrinter& printer);
} // namespace fidl_codec