summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRaul Gutierrez Segales <raul.gutierrez.segales@collabora.co.uk>2011-03-05 15:03:23 (GMT)
committerTravis Reitter <travis.reitter@collabora.co.uk>2011-03-09 19:16:43 (GMT)
commite821ccd5a700e9391967e3a3d7cc8b56789a8e6d (patch)
tree296d7860489025961f41120ed7f093ebe7a659dd
parent8a519d5a49a4e0cba5e33285cabb6510945c579b (diff)
downloadfolks-e821ccd5a700e9391967e3a3d7cc8b56789a8e6d.tar.gz
folks-e821ccd5a700e9391967e3a3d7cc8b56789a8e6d.tar.xz
Add to_string () method to RoleOwner
-rw-r--r--NEWS2
-rw-r--r--folks/role-owner.vala11
2 files changed, 13 insertions, 0 deletions
diff --git a/NEWS b/NEWS
index 4b87a41..660e2a9 100644
--- a/NEWS
+++ b/NEWS
@@ -16,6 +16,7 @@ Bugs fixed:
* Bug 641210 — Add interface for postal addresses
* Bug 643956 — Use the correct signal name for postal addresses
* Bug 643954 — Add to_string () to PostalAddress class
+* Bug 643955 — Add to_string () to RoleOwner class
API changes:
* Add RoleOwner interface
@@ -25,6 +26,7 @@ API changes:
* Add PostalAddressOwner.uid as a convenience for backends
* Add PostalAddress.equal()
* Add PostalAddress.to_string()
+* Add RoleOwner.to_string()
Overview of changes from libfolks 0.3.5 to libfolks 0.3.6
=========================================================
diff --git a/folks/role-owner.vala b/folks/role-owner.vala
index f58b07c..5e9e9c1 100644
--- a/folks/role-owner.vala
+++ b/folks/role-owner.vala
@@ -93,6 +93,17 @@ public class Folks.Role : Object
{
return r.organisation_name.hash () + r.title.hash ();
}
+
+ /**
+ * Formatted version of this role.
+ *
+ * @since 0.3.UNRELEASED
+ */
+ public string to_string ()
+ {
+ var str = _("Title: %s , Organisation: %s");
+ return str.printf (this.title, this.organisation_name);
+ }
}
/**