2 * Copyright (C) 2010 Collabora Ltd.
3 * Copyright (C) 2011 Philip Withnall
5 * This library is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU Lesser General Public License as published by
7 * the Free Software Foundation, either version 2.1 of the License, or
8 * (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public License
16 * along with this library. If not, see <http://www.gnu.org/licenses/>.
19 * Philip Withnall <philip.withnall@collabora.co.uk>
25 * Interface exposing a {@link Persona}'s or {@link Individual}'s user-defined
26 * status as a favourite.
28 public interface Folks.FavouriteDetails : Object
31 * Whether this contact is a user-defined favourite.
33 public abstract bool is_favourite { get; set; }
36 * Change whether the contact is a user-defined favourite.
38 * It's preferred to call this rather than setting
39 * {@link FavouriteDetails.is_favourite} directly, as this method gives error
40 * notification and will only return once the favouriteness has been written
41 * to the relevant backing store (or the operation's failed).
43 * @param is_favourite `true` if the contact is a favourite; `false` otherwise
44 * @throws PropertyError if setting the favouriteness failed
47 public virtual async void change_is_favourite (bool is_favourite)
50 /* Default implementation. */
51 throw new PropertyError.NOT_WRITEABLE (
52 _("Favorite status is not writeable on this contact."));