[haiku-commits] haiku: hrev47403 - docs/user/storage headers/os/storage

  • From: jscipione@xxxxxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Thu, 19 Jun 2014 03:18:38 +0200 (CEST)

hrev47403 adds 2 changesets to branch 'master'
old head: b885e90eb96c5c2b629c81d35b7f9970db239995
new head: 8d39283b71339382e6cc9891371213ac80fed2c0
overview: http://cgit.haiku-os.org/haiku/log/?qt=range&q=8d39283+%5Eb885e90

----------------------------------------------------------------------------

5efee6d: NodeMonitor: Revert enums back to #defines
  
  While enums are presented much more clearly in the docs and the values didn't
  change this apparently caused some issues so we're going back to using 
#defines.
  
  Also update the docs changing the \var tags to \def tag and putting the 
description
  in a \brief tag.

8d39283: While I'm at it fix tiny style issue I missed

                                     [ John Scipione <jscipione@xxxxxxxxx> ]

----------------------------------------------------------------------------

3 files changed, 52 insertions(+), 52 deletions(-)
docs/user/storage/NodeMonitor.dox | 78 ++++++++++++++++++-----------------
headers/os/storage/Node.h         |  2 +-
headers/os/storage/NodeMonitor.h  | 24 +++++------

############################################################################

Commit:      5efee6dfb0f529bef8e671ca8a7c1cf6d1328a3a
URL:         http://cgit.haiku-os.org/haiku/commit/?id=5efee6d
Author:      John Scipione <jscipione@xxxxxxxxx>
Date:        Thu Jun 19 00:57:49 2014 UTC

NodeMonitor: Revert enums back to #defines

While enums are presented much more clearly in the docs and the values didn't
change this apparently caused some issues so we're going back to using #defines.

Also update the docs changing the \var tags to \def tag and putting the 
description
in a \brief tag.

----------------------------------------------------------------------------

diff --git a/docs/user/storage/NodeMonitor.dox 
b/docs/user/storage/NodeMonitor.dox
index 86e239a..0a47c96 100644
--- a/docs/user/storage/NodeMonitor.dox
+++ b/docs/user/storage/NodeMonitor.dox
@@ -9,8 +9,8 @@
  *             Clemens Zeidler, haiku@xxxxxxxxxxxxxxxxxx
  *
  * Corresponds to:
- *             headers/os/storage/NodeMonitor.h        hrev47402
- *             src/kits/storage/NodeMonitor.cpp        hrev47402
+ *             headers/os/storage/NodeMonitor.h        hrev47403
+ *             src/kits/storage/NodeMonitor.cpp        hrev47403
  */
 
 
@@ -122,99 +122,103 @@
 */
 
 
-//// The "opcode" field of the B_NODE_MONITOR notification message you get.
+// The "opcode" field of the B_NODE_MONITOR notification message you get.
 
 
 /*!
-       \var B_ENTRY_CREATED
-
-       \c B_NODE_MONITOR notification message "opcode" is set when entry is
-       created.
+       \def B_ENTRY_CREATED
+       \brief \c B_NODE_MONITOR notification message "opcode" is set when 
entry is
+              created.
 
        \since BeOS R3
 */
 
 
 /*!
-       \var B_ENTRY_REMOVED
-
-       \c B_NODE_MONITOR notification message "opcode" is set when entry is
-       removed.
+       \def B_ENTRY_REMOVED
+       \brief \c B_NODE_MONITOR notification message "opcode" is set when 
entry is
+              removed.
 
        \since BeOS R3
 */
 
 
 /*!
-       \var B_ENTRY_MOVED
-
-       \c B_NODE_MONITOR notification message "opcode" is set when entry is
-       moved.
+       \def B_ENTRY_MOVED
+       \brief \c B_NODE_MONITOR notification message "opcode" is set when 
entry is
+              moved.
 
        \since BeOS R3
 */
 
 
 /*!
-       \var B_STAT_CHANGED
+       \def B_STAT_CHANGED
+       \brief \c B_NODE_MONITOR notification message "opcode" set when stat 
info
+              changes.
 
-       \c B_NODE_MONITOR notification message "opcode" set when stat info
-       changes. More information can be found in the "fields" field.
+       More information can be found in the "fields" field.
 
        \since BeOS R3
 */
 
 
 /*!
-       \var B_ATTR_CHANGED
+       \def B_ATTR_CHANGED
+       \brief \c B_NODE_MONITOR notification message "opcode" set when 
attribute
+              changes.
 
-       \c B_NODE_MONITOR notification message "opcode" set when attribute
-       changes. More information can be found in the "cause" field.
+       More information can be found in the "cause" field.
 
        \since BeOS R3
 */
 
 
 /*!
-       \var B_DEVICE_MOUNTED
-
-       \c B_NODE_MONITOR notification message "opcode" set when device is
-       mounted.
+       \def B_DEVICE_MOUNTED
+       \brief \c B_NODE_MONITOR notification message "opcode" set when device 
is
+              mounted.
 
        \since BeOS R3
 */
 
 
 /*!
-       \var B_DEVICE_UNMOUNTED
-
-       \c B_NODE_MONITOR notification message "opcode" set when device is
-       unmounted.
+       \def B_DEVICE_UNMOUNTED
+       \brief \c B_NODE_MONITOR notification message "opcode" set when device 
is
+              unmounted.
 
        \since BeOS R3
 */
 
 
-/*!
-       \var B_ATTR_CREATED
+// More specific info in the "cause" field of B_ATTR_CHANGED notification
+// messages.
 
-       \c B_ATTR_CHANGED notification message "cause" set when attribute is
-       created.
+
+/*!
+       \def B_ATTR_CREATED
+       \brief \c B_ATTR_CHANGED notification message "cause" set when 
attribute is
+              created.
 
        \since Haiku R1
 */
 
 
 /*!
-       \var B_ATTR_REMOVED
-
-       \c B_ATTR_CHANGED notification message "cause" set when attribute is
-       removed.
+       \def B_ATTR_REMOVED
+       \brief \c B_ATTR_CHANGED notification message "cause" set when 
attribute is
+              removed.
 
        \since Haiku R1
 */
 
 
+// More specific info in the "fields" field of B_STAT_CHANGED notification
+// messages, specifying what parts of the stat data have actually been
+// changed.
+
+
 /*!
        \var B_STAT_MODE
        \brief Set when stat mode changes.
diff --git a/headers/os/storage/NodeMonitor.h b/headers/os/storage/NodeMonitor.h
index 12d8f0b..abd3832 100644
--- a/headers/os/storage/NodeMonitor.h
+++ b/headers/os/storage/NodeMonitor.h
@@ -32,25 +32,21 @@ enum {
 // The presence and meaning of the other fields in that message specifying what
 // exactly caused the notification depend on this value.
 
-enum {
-       B_ENTRY_CREATED = 1,
-       B_ENTRY_REMOVED,
-       B_ENTRY_MOVED,
-       B_STAT_CHANGED,
-       B_ATTR_CHANGED,
-       B_DEVICE_MOUNTED,
-       B_DEVICE_UNMOUNTED
-};
+#define B_ENTRY_CREATED                1
+#define B_ENTRY_REMOVED                2
+#define B_ENTRY_MOVED          3
+#define B_STAT_CHANGED         4
+#define B_ATTR_CHANGED         5
+#define B_DEVICE_MOUNTED       6
+#define B_DEVICE_UNMOUNTED     7
 
 
 // More specific info in the "cause" field of B_ATTR_CHANGED notification
 // messages. (Haiku only)
 
-enum {
-       B_ATTR_CREATED = 1,
-       B_ATTR_REMOVED,
-//     B_ATTR_CHANGED
-};
+#define B_ATTR_CREATED         1
+#define B_ATTR_REMOVED         2
+//             B_ATTR_CHANGED is reused
 
 
 // More specific info in the "fields" field of B_STAT_CHANGED notification

############################################################################

Revision:    hrev47403
Commit:      8d39283b71339382e6cc9891371213ac80fed2c0
URL:         http://cgit.haiku-os.org/haiku/commit/?id=8d39283
Author:      John Scipione <jscipione@xxxxxxxxx>
Date:        Thu Jun 19 01:01:16 2014 UTC

While I'm at it fix tiny style issue I missed

----------------------------------------------------------------------------

diff --git a/headers/os/storage/Node.h b/headers/os/storage/Node.h
index 5b28249..3eb23fa 100644
--- a/headers/os/storage/Node.h
+++ b/headers/os/storage/Node.h
@@ -18,7 +18,7 @@ struct entry_ref;
 struct node_ref {
        node_ref();
        node_ref(dev_t device, ino_t node);
-       node_ref(const node_ref &other);
+       node_ref(const node_ref& other);
 
        bool operator==(const node_ref& other) const;
        bool operator!=(const node_ref& other) const;


Other related posts:

  • » [haiku-commits] haiku: hrev47403 - docs/user/storage headers/os/storage - jscipione