0.9.8.10
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
HandleCallback.cc
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2007-2015 Hypertable, Inc.
3  *
4  * This file is part of Hypertable.
5  *
6  * Hypertable is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU General Public License
8  * as published by the Free Software Foundation; either version 3
9  * of the License, or any later version.
10  *
11  * Hypertable is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
19  * 02110-1301, USA.
20  */
21 
22 #include "Common/Compat.h"
23 #include "HandleCallback.h"
24 
25 namespace Hyperspace {
26 
27  const char *EventMaskToString(uint32_t mask) {
28  if (mask == EVENT_MASK_ATTR_SET)
29  return "EVENT_MASK_ATTR_SET";
30  else if (mask == EVENT_MASK_ATTR_DEL)
31  return "EVENT_MASK_ATTR_DEL";
32  else if (mask == EVENT_MASK_CHILD_NODE_ADDED)
33  return "EVENT_MASK_CHILD_NODE_ADDED";
34  else if (mask == EVENT_MASK_CHILD_NODE_REMOVED)
35  return "EVENT_MASK_CHILD_NODE_REMOVED";
36  else if (mask == EVENT_MASK_LOCK_ACQUIRED)
37  return "EVENT_MASK_LOCK_ACQUIRED";
38  else if (mask == EVENT_MASK_LOCK_RELEASED)
39  return "EVENT_MASK_LOCK_RELEASED";
40  else if (mask == EVENT_MASK_LOCK_GRANTED)
41  return "EVENT_MASK_LOCK_GRANTED";
42  return "UNKNOWN";
43  }
44 
45 }
Hyperspace definitions
Compatibility Macros for C/C++.
const char * EventMaskToString(uint32_t mask)