Browse Source

[2155] removed inline keywords from methods inside class definition

Yoshitaka Aharen 12 years ago
parent
commit
3f3183672b
3 changed files with 30 additions and 30 deletions
  1. 12 12
      src/bin/auth/statistics.h
  2. 4 4
      src/lib/statistics/counter.h
  3. 14 14
      src/lib/statistics/counter_dict.h

+ 12 - 12
src/bin/auth/statistics.h

@@ -62,7 +62,7 @@ public:
     /// This constructor is mostly exception free. But it may still throw
     /// a standard exception if memory allocation fails inside the method.
     ///
-    inline QRAttributes() :
+    QRAttributes() :
     req_ip_version_(0), req_transport_protocol_(0),
     req_opcode_(0),
     req_is_edns_0_(false), req_is_edns_badver_(false),
@@ -77,36 +77,36 @@ public:
     ///
     /// This method never throws an exception.
     ///
-    inline ~QRAttributes() {};
+    ~QRAttributes() {};
     /// \brief Set query opcode.
     /// \throw None
-    inline void setQueryOpCode(const int opcode) {
+    void setQueryOpCode(const int opcode) {
         req_opcode_ = opcode;
     };
     /// \brief Set IP version carrying a query.
     /// \throw None
-    inline void setQueryIPVersion(const int ip_version) {
+    void setQueryIPVersion(const int ip_version) {
         req_ip_version_ = ip_version;
     };
     /// \brief Set transport protocol carrying a query.
     /// \throw None
-    inline void setQueryTransportProtocol(const int transport_protocol) {
+    void setQueryTransportProtocol(const int transport_protocol) {
         req_transport_protocol_ = transport_protocol;
     };
     /// \brief Set query EDNS attributes.
     /// \throw None
-    inline void setQueryEDNS(const bool is_edns_0, const bool is_edns_badver) {
+    void setQueryEDNS(const bool is_edns_0, const bool is_edns_badver) {
         req_is_edns_0_ = is_edns_0;
         req_is_edns_badver_ = is_edns_badver;
     };
     /// \brief Set query DO bit.
     /// \throw None
-    inline void setQueryDO(const bool is_dnssec_ok) {
+    void setQueryDO(const bool is_dnssec_ok) {
         req_is_dnssec_ok_ = is_dnssec_ok;
     };
     /// \brief Set query TSIG attributes.
     /// \throw None
-    inline void setQuerySig(const bool is_tsig, const bool is_sig0,
+    void setQuerySig(const bool is_tsig, const bool is_sig0,
                             const bool is_badsig)
     {
         req_is_tsig_ = is_tsig;
@@ -115,22 +115,22 @@ public:
     };
     /// \brief Set zone origin.
     /// \throw None
-    inline void setOrigin(const std::string& origin) {
+    void setOrigin(const std::string& origin) {
         zone_origin_ = origin;
     };
     /// \brief Set if the answer was sent.
     /// \throw None
-    inline void answerWasSent() {
+    void answerWasSent() {
         answer_sent_ = true;
     };
     /// \brief Set if the response is truncated.
     /// \throw None
-    inline void setResponseTruncated(const bool is_truncated) {
+    void setResponseTruncated(const bool is_truncated) {
         res_is_truncated_ = is_truncated;
     };
     /// \brief Reset attributes.
     /// \throw None
-    inline void reset() {
+    void reset() {
         req_ip_version_ = 0;
         req_transport_protocol_ = 0;
         req_opcode_ = 0;

+ 4 - 4
src/lib/statistics/counter.h

@@ -46,7 +46,7 @@ public:
     /// \param items A number of counter items to hold (greater than 0)
     ///
     /// \throw isc::InvalidParameter \a items is 0
-    explicit inline Counter(const size_t items) :
+    explicit Counter(const size_t items) :
         counters_(items, InitialValue)
     {
         if (items == 0) {
@@ -57,14 +57,14 @@ public:
     /// The destructor.
     ///
     /// This method never throws an exception.
-    inline ~Counter() {};
+    ~Counter() {};
 
     /// \brief Increment a counter item specified with \a type.
     ///
     /// \param type %Counter item to increment
     ///
     /// \throw isc::OutOfRange \a type is invalid
-    inline void inc(const Counter::Type type) {
+    void inc(const Counter::Type type) {
         if (type >= counters_.size()) {
             isc_throw(isc::OutOfRange, "Counter type is out of range");
         }
@@ -77,7 +77,7 @@ public:
     /// \param type %Counter item to get the value of
     ///
     /// \throw isc::OutOfRange \a type is invalid
-    inline const Counter::Value& get(const Counter::Type type) const {
+    const Counter::Value& get(const Counter::Type type) const {
         if (type >= counters_.size()) {
             isc_throw(isc::OutOfRange, "Counter type is out of range");
         }

+ 14 - 14
src/lib/statistics/counter_dict.h

@@ -48,7 +48,7 @@ private:
     // specified at the construction of this class.
     CounterDictionary();
 public:
-    explicit inline CounterDictionary(const size_t items) :
+    explicit CounterDictionary(const size_t items) :
         items_(items)
     {
         // The number of items must not be 0
@@ -56,8 +56,8 @@ public:
             isc_throw(isc::InvalidParameter, "Items must not be 0");
         }
     };
-    inline ~CounterDictionary() {};
-    inline void addElement(const std::string& name) {
+    ~CounterDictionary() {};
+    void addElement(const std::string& name) {
         // throw if the element already exists
         if (dictionary_.count(name) != 0) {
             isc_throw(isc::InvalidParameter,
@@ -68,7 +68,7 @@ public:
         dictionary_.insert(
             DictionaryMap::value_type(name, CounterPtr(new Counter(items_))));
     };
-    inline void deleteElement(const std::string& name) {
+    void deleteElement(const std::string& name) {
         size_t result = dictionary_.erase(name);
         if (result != 1) {
             // If an element with specified name does not exist, throw
@@ -77,7 +77,7 @@ public:
                       "Element " << name << " does not exist");
         }
     };
-    inline Counter& getElement(const std::string& name) {
+    Counter& getElement(const std::string& name) {
         DictionaryMap::const_iterator i = dictionary_.find(name);
         if (i != dictionary_.end()) {
             // the key was found. return the element.
@@ -89,7 +89,7 @@ public:
                       "Element " << name << " does not exist");
         }
     };
-    inline Counter& operator[](const std::string& name) {
+    Counter& operator[](const std::string& name) {
         return (getElement(name));
     };
     /// \brief \c ConstIterator is a constant iterator that provides an
@@ -112,31 +112,31 @@ public:
             /// This constructor is mostly exception free. But it may still
             /// throw a standard exception if memory allocation fails
             /// inside the method.
-            inline ConstIterator() {}
+            ConstIterator() {}
             /// The destructor.
             ///
             /// This method never throws an exception.
-            inline ~ConstIterator() {}
+            ~ConstIterator() {}
             /// Constructor from implementation detail DictionaryMap::const_iterator
-            inline ConstIterator(
+            ConstIterator(
                 DictionaryMap::const_iterator iterator) :
                 iterator_(iterator)
             {}
 
         private:
             /// \brief An internal method to increment this iterator.
-            inline void increment() {
+            void increment() {
                 ++iterator_;
                 return;
             }
 
             /// \brief An internal method to check equality.
-            inline bool equal(const ConstIterator& other) const {
+            bool equal(const ConstIterator& other) const {
                 return (iterator_ == other.iterator_);
             }
 
             /// \brief An internal method to dereference this iterator.
-            inline const value_type& dereference() const {
+            const value_type& dereference() const {
                 return (iterator_->first);
             }
 
@@ -145,10 +145,10 @@ public:
             DictionaryMap::const_iterator iterator_;
     };
 
-    inline ConstIterator begin() const {
+    ConstIterator begin() const {
         return (CounterDictionary::ConstIterator(dictionary_.begin()));
     };
-    inline ConstIterator end() const {
+    ConstIterator end() const {
         return (CounterDictionary::ConstIterator(dictionary_.end()));
     };