ekiga r5943 - in trunk/lib/engine/addressbook: call-history evolution ldap skel



Author: jpuydt
Date: Mon Jan 28 06:10:05 2008
New Revision: 5943
URL: http://svn.gnome.org/viewvc/ekiga?rev=5943&view=rev

Log:
Little api change for get_status in Ekiga::Book (made it const)

Modified:
   trunk/lib/engine/addressbook/call-history/history-book.cpp
   trunk/lib/engine/addressbook/call-history/history-book.h
   trunk/lib/engine/addressbook/evolution/evolution-book.cpp
   trunk/lib/engine/addressbook/evolution/evolution-book.h
   trunk/lib/engine/addressbook/ldap/ldap-book.cpp
   trunk/lib/engine/addressbook/ldap/ldap-book.h
   trunk/lib/engine/addressbook/skel/book-impl.h
   trunk/lib/engine/addressbook/skel/book.h

Modified: trunk/lib/engine/addressbook/call-history/history-book.cpp
==============================================================================
--- trunk/lib/engine/addressbook/call-history/history-book.cpp	(original)
+++ trunk/lib/engine/addressbook/call-history/history-book.cpp	Mon Jan 28 06:10:05 2008
@@ -146,6 +146,12 @@
   return std::set<std::string> ();
 }
 
+const std::string
+History::Book::get_status () const
+{
+  return ""; // nothing special here
+}
+
 void
 History::Book::set_search_filter (std::string /*filter*/)
 {

Modified: trunk/lib/engine/addressbook/call-history/history-book.h
==============================================================================
--- trunk/lib/engine/addressbook/call-history/history-book.h	(original)
+++ trunk/lib/engine/addressbook/call-history/history-book.h	Mon Jan 28 06:10:05 2008
@@ -67,6 +67,8 @@
 
     const std::set<std::string> existing_groups () const;
 
+    const std::string get_status () const;
+
     void set_search_filter (std::string);
 
     /* more specific api */

Modified: trunk/lib/engine/addressbook/evolution/evolution-book.cpp
==============================================================================
--- trunk/lib/engine/addressbook/evolution/evolution-book.cpp	(original)
+++ trunk/lib/engine/addressbook/evolution/evolution-book.cpp	Mon Jan 28 06:10:05 2008
@@ -268,6 +268,11 @@
   refresh ();
 }
 
+const std::string
+Evolution::Book::get_status () const
+{
+  return status;
+}
 
 void
 Evolution::Book::refresh ()

Modified: trunk/lib/engine/addressbook/evolution/evolution-book.h
==============================================================================
--- trunk/lib/engine/addressbook/evolution/evolution-book.h	(original)
+++ trunk/lib/engine/addressbook/evolution/evolution-book.h	Mon Jan 28 06:10:05 2008
@@ -75,6 +75,8 @@
 
     void set_search_filter (std::string search_filter);
 
+    const std::string get_status () const;
+
     void refresh ();
 
     /* those are private, but need to be called from C code */
@@ -99,6 +101,7 @@
     EBookView *view;
     Wrapper *self;
 
+    std::string status;
     std::string search_filter;
   };
 

Modified: trunk/lib/engine/addressbook/ldap/ldap-book.cpp
==============================================================================
--- trunk/lib/engine/addressbook/ldap/ldap-book.cpp	(original)
+++ trunk/lib/engine/addressbook/ldap/ldap-book.cpp	Mon Jan 28 06:10:05 2008
@@ -304,6 +304,12 @@
   refresh ();
 }
 
+const std::string
+OPENLDAP::Book::get_status () const
+{
+  return status;
+}
+
 void
 OPENLDAP::Book::refresh ()
 {

Modified: trunk/lib/engine/addressbook/ldap/ldap-book.h
==============================================================================
--- trunk/lib/engine/addressbook/ldap/ldap-book.h	(original)
+++ trunk/lib/engine/addressbook/ldap/ldap-book.h	Mon Jan 28 06:10:05 2008
@@ -80,6 +80,8 @@
 
     void set_search_filter (std::string search_string);
 
+    const std::string get_status () const;
+
     void refresh ();
 
     void remove ();
@@ -121,6 +123,7 @@
     struct ldap *ldap_context;
     unsigned int patience;
 
+    std::string status;
     std::string search_filter;
 
     Ekiga::Runtime & runtime;

Modified: trunk/lib/engine/addressbook/skel/book-impl.h
==============================================================================
--- trunk/lib/engine/addressbook/skel/book-impl.h	(original)
+++ trunk/lib/engine/addressbook/skel/book-impl.h	Mon Jan 28 06:10:05 2008
@@ -130,16 +130,6 @@
      */
     void remove_contact (ContactType &contact);
 
-
-    /** Get the current status.
-     * This function is purely virtual and should be implemented by
-     * the descendant of the Ekiga::Book, ie BookImpl or one
-     * of its descendant.
-     */
-    std::string get_status ();
-
-    std::string status;
-
   };
 
 /**
@@ -223,12 +213,4 @@
   remove_object (contact);
 }
 
-
-template<typename ContactType>
-std::string
-Ekiga::BookImpl<ContactType>::get_status ()
-{
-  return status;
-}
-
 #endif

Modified: trunk/lib/engine/addressbook/skel/book.h
==============================================================================
--- trunk/lib/engine/addressbook/skel/book.h	(original)
+++ trunk/lib/engine/addressbook/skel/book.h	Mon Jan 28 06:10:05 2008
@@ -87,7 +87,7 @@
      * the descendant of the Ekiga::Book, ie BookImpl or one
      * of its descendant.
      */
-    virtual std::string get_status () = 0;
+    virtual const std::string get_status () const = 0;
 
 
     /*



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]