diff --git a/src/name-component.cpp b/src/name-component.cpp
index a045766..75d9cfa 100644
--- a/src/name-component.cpp
+++ b/src/name-component.cpp
@@ -142,18 +142,68 @@
   return os.str();
 }
 
+
+bool
+Component::isNumber() const
+{
+  return (value_size() == 1 || value_size() == 2 ||
+          value_size() == 4 || value_size() == 8);
+}
+
+bool
+Component::isNumberWithMarker(uint8_t marker) const
+{
+  return (!empty() && value()[0] == marker &&
+          (value_size() == 2 || value_size() == 3 ||
+           value_size() == 5 || value_size() == 9));
+}
+
+bool
+Component::isVersion() const
+{
+  return isNumberWithMarker(VERSION_MARKER);
+}
+
+bool
+Component::isSegment() const
+{
+  return isNumberWithMarker(SEGMENT_MARKER);
+}
+
+bool
+Component::isSegmentOffset() const
+{
+  return isNumberWithMarker(SEGMENT_OFFSET_MARKER);
+}
+
+bool
+Component::isTimestamp() const
+{
+  return isNumberWithMarker(TIMESTAMP_MARKER);
+}
+
+bool
+Component::isSequenceNumber() const
+{
+  return isNumberWithMarker(SEQUENCE_NUMBER_MARKER);
+}
+
+
 uint64_t
 Component::toNumber() const
 {
-  /// \todo Check if Component is of tlv::NumberComponent type
+  if (!isNumber())
+    throw Error("Name component does not have nonNegativeInteger value");
+
   return readNonNegativeInteger(*this);
 }
 
 uint64_t
 Component::toNumberWithMarker(uint8_t marker) const
 {
-  if (empty() || value()[0] != marker)
-    throw Error("Name component does not have the requested marker");
+  if (!isNumberWithMarker(marker))
+    throw Error("Name component does not have the requested marker "
+                "or the value is not a nonNegativeInteger");
 
   Buffer::const_iterator valueBegin = value_begin() + 1;
   return tlv::readNonNegativeInteger(value_size() - 1, valueBegin, value_end());
diff --git a/src/name-component.hpp b/src/name-component.hpp
index 7213f9a..ea68084 100644
--- a/src/name-component.hpp
+++ b/src/name-component.hpp
@@ -255,6 +255,59 @@
   std::string
   toUri() const;
 
+  ////////////////////////////////////////////////////////////////////////////////
+
+  /**
+   * @brief Check if the component is nonNegativeInteger
+   * @see http://named-data.net/doc/ndn-tlv/tlv.html#non-negative-integer-encoding
+   */
+  bool
+  isNumber() const;
+
+  /**
+   * @brief Check if the component is NameComponentWithMarker per NDN naming conventions
+   * @see http://named-data.net/doc/tech-memos/naming-conventions.pdf
+   */
+  bool
+  isNumberWithMarker(uint8_t marker) const;
+
+  /**
+   * @brief Check if the component is version per NDN naming conventions
+   * @see http://named-data.net/doc/tech-memos/naming-conventions.pdf
+   */
+  bool
+  isVersion() const;
+
+  /**
+   * @brief Check if the component is segment number per NDN naming conventions
+   * @see http://named-data.net/doc/tech-memos/naming-conventions.pdf
+   */
+  bool
+  isSegment() const;
+
+  /**
+   * @brief Check if the component is segment offset per NDN naming conventions
+   * @see http://named-data.net/doc/tech-memos/naming-conventions.pdf
+   */
+  bool
+  isSegmentOffset() const;
+
+  /**
+   * @brief Check if the component is timestamp per NDN naming conventions
+   * @see http://named-data.net/doc/tech-memos/naming-conventions.pdf
+   */
+  bool
+  isTimestamp() const;
+
+  /**
+   * @brief Check if the component is sequence number per NDN naming conventions
+   * @see http://named-data.net/doc/tech-memos/naming-conventions.pdf
+   */
+  bool
+  isSequenceNumber() const;
+
+  ////////////////////////////////////////////////////////////////////////////////
+
   /**
    * @brief Interpret this name component as nonNegativeInteger
    *
@@ -333,6 +386,8 @@
   uint64_t
   toSequenceNumber() const;
 
+  ////////////////////////////////////////////////////////////////////////////////
+
   /**
    * @brief Create a component encoded as nonNegativeInteger
    *
