]> git.proxmox.com Git - ceph.git/blame - ceph/src/rocksdb/port/port_dirent.h
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / src / rocksdb / port / port_dirent.h
CommitLineData
7c673cae 1// Copyright (c) 2011-present, Facebook, Inc. All rights reserved.
11fdf7f2
TL
2// This source code is licensed under both the GPLv2 (found in the
3// COPYING file in the root directory) and Apache 2.0 License
4// (found in the LICENSE.Apache file in the root directory).
7c673cae
FG
5//
6// Copyright (c) 2011 The LevelDB Authors. All rights reserved.
7// Use of this source code is governed by a BSD-style license that can be
8// found in the LICENSE file. See the AUTHORS file for names of contributors.
9//
10// See port_example.h for documentation for the following types/functions.
11
11fdf7f2 12#pragma once
7c673cae
FG
13
14#ifdef ROCKSDB_PLATFORM_POSIX
15#include <dirent.h>
16#include <sys/types.h>
17#elif defined(OS_WIN)
18
f67539c2 19namespace ROCKSDB_NAMESPACE {
7c673cae
FG
20namespace port {
21
22struct dirent {
23 char d_name[_MAX_PATH]; /* filename */
24};
25
26struct DIR;
27
28DIR* opendir(const char* name);
29
30dirent* readdir(DIR* dirp);
31
32int closedir(DIR* dirp);
33
34} // namespace port
35
36using port::dirent;
37using port::DIR;
38using port::opendir;
39using port::readdir;
40using port::closedir;
41
f67539c2 42} // namespace ROCKSDB_NAMESPACE
7c673cae
FG
43
44#endif // OS_WIN