backends \
$(NULL)
+if ENABLE_DOCS
+SUBDIRS += docs
+endif
+
ACLOCAL_AMFLAGS = -I m4
DISTCHECK_CONFIGURE_FLAGS = \
AC_SUBST(LIBFOLKS_LIBS)
# -----------------------------------------------------------
+# Documentation
+# -----------------------------------------------------------
+AC_ARG_ENABLE(docs,
+ AC_HELP_STRING([--enable-docs],[Enable documentation generation]),
+ enable_docs=$enableval, enable_docs=no)
+AM_CONDITIONAL(ENABLE_DOCS, test x$enable_docs = xyes)
+
+AS_IF([test "x$enable_docs" != xno],
+ [AC_PATH_PROG(VALADOC, valadoc, :)
+ AC_SUBST(VALADOC)
+ AS_IF([test "$VALADOC" = :],
+ [AC_MSG_ERROR([valadoc not found])])])
+
+# -----------------------------------------------------------
# Telepathy backend
# -----------------------------------------------------------
PKG_CHECK_MODULES(LIBFOLKS_TELEPATHY,
backends/Makefile
backends/telepathy/Makefile
folks/Makefile
+ docs/Makefile
])
AC_OUTPUT
Coding style checks.........: ${ENABLE_CODING_STYLE_CHECKS}
VAPI generation.............: ${enable_vapigen}
Bugreporting URL............: ${PACKAGE_BUGREPORT}
+ Documentation...............: ${enable_docs}
"
--- /dev/null
+docdir=$(datadir)/devhelp/references/folks-0.1
+innerdocdir=$(datadir)/devhelp/references/folks-0.1/folks-0.1
+imgdir=$(datadir)/devhelp/references/folks-0.1/folks-0.1/img
+
+doc_data = \
+ folks-0.1/*.css \
+ folks-0.1/*.png \
+ $(NULL)
+
+doc_DATA = \
+ folks-0.1/index.html \
+ $(doc_data) \
+ $(NULL)
+
+innerdoc_DATA = \
+ folks-0.1/folks-0.1/index.htm \
+ folks-0.1/folks-0.1/*.html \
+ $(NULL)
+
+img_DATA = \
+ folks-0.1/folks-0.1/img/*.png \
+ $(NULL)
+
+$(doc_data) $(innerdoc_DATA) $(img_DATA): folks-0.1/index.html
+
+folks-0.1/index.html:
+ $(VALADOC) -o folks-0.1/ --force -b $(top_srcdir) \
+ --pkg=gee-1.0 --pkg=gio-2.0 --pkg=gmodule-2.0 --pkg=build-conf \
+ --vapidir=$(top_srcdir)/folks \
+ $(top_srcdir)/folks/*.vala
using GLib;
+/**
+ * Interface for classes which represent aliasable contacts, such as
+ * {@link Persona} and {@link Individual}.
+ */
public interface Folks.Alias : Object
{
public abstract string alias { get; set; }
using GLib;
+/**
+ * Interface for classes which represent contacts which have an avatar
+ * (pictorial representation), such as {@link Persona} and {@link Individual}.
+ */
public interface Folks.Avatar : Object
{
public abstract File avatar { get; set; }
using BuildConf;
using Folks;
+/**
+ * A single backend to libfolks, such as Telepathy or evolution-data-server.
+ * Each backend provides {@link Persona}s which are aggregated to form
+ * {@link Individual}s.
+ */
public abstract class Folks.Backend : Object
{
public abstract string name { get; protected set; }
using GLib;
+/**
+ * Flag values for the capabilities an object implementing {@link Capabilities}
+ * could possibly have, as a bitmask.
+ */
public enum Folks.CapabilitiesFlags {
+ /**
+ * No capabilities. Mutually exclusive with the other values.
+ */
NONE = 0,
+
+ /**
+ * Audio chat support.
+ */
AUDIO = 1 << 0,
+
+ /**
+ * Video chat support.
+ */
VIDEO = 1 << 1,
+
+ /**
+ * File transfer support.
+ */
FILE_TRANSFER = 1 << 2,
+
+ /**
+ * Telepathy tubes support.
+ */
STREAM_TUBE = 1 << 3,
+
+ /**
+ * Unknown set of capabilities. Mutually exclusive with the other values.
+ */
UNKNOWN = 1 << 7,
}
+/**
+ * Interface exposing the capabilities of the {@link Persona} or
+ * {@link Individual} implementing it, such as whether they can do video chats
+ * or file transfers.
+ */
public interface Folks.Capabilities : Object
{
public abstract CapabilitiesFlags capabilities
using GLib;
+/**
+ * Interface for {@link Persona}s or {@link Individual}s which can be grouped
+ * into sets of similar objects.
+ */
public interface Folks.Groups : Object
{
public abstract HashTable<string, bool> groups { get; set; }
using Gee;
using GLib;
+/**
+ * Allows access to the {@link Individual}s which have been created through
+ * aggregation of all the {@link Persona}s provided by the various libfolks
+ * {@link Backend}s. This is the main interface for accessing libfolks.
+ */
public class Folks.IndividualAggregator : Object
{
private BackendStore backend_store;
using GLib;
using Folks;
+/**
+ * A physical person, aggregated from the various {@link Persona}s the person
+ * might have, such as their different IM addresses or vCard entries.
+ */
public class Folks.Individual : Object, Alias, Avatar, Capabilities, Groups,
Presence
{
using GLib;
using Folks;
+/**
+ * A store for {@link Persona}s.
+ */
public abstract class Folks.PersonaStore : Object
{
public abstract signal void personas_added (GLib.List<Persona> personas);
using GLib;
using Folks;
+/**
+ * Represents a "shard" of a person from a single source (a single
+ * {@link Backend}), such as an XMPP contact from Telepathy or a vCard contact
+ * from evolution-data-server. All the personas belonging to one physical person
+ * are aggregated to form a single {@link Individual} representing that person.
+ */
public abstract class Folks.Persona : Object, Alias, Avatar, Capabilities,
Presence
{
using GLib;
+/**
+ * The possible presence states an object implementing {@link Presence} could be
+ * in.
+ *
+ * These closely follow the
+ * [[http://telepathy.freedesktop.org/spec/Connection_Interface_Simple_Presence.html#Connection_Presence_Type|SimplePresence]]
+ * interface in the Telepathy specification.
+ */
public enum Folks.PresenceType {
+ /**
+ * Presence is unset. (Default.)
+ */
UNSET,
+
+ /**
+ * User is offline.
+ */
OFFLINE,
+
+ /**
+ * User is available.
+ */
AVAILABLE,
+
+ /**
+ * User is away.
+ */
AWAY,
+
+ /**
+ * User is away for an extended period.
+ */
EXTENDED_AWAY,
+
+ /**
+ * User is online but hidden.
+ */
HIDDEN,
+
+ /**
+ * User is busy.
+ */
BUSY,
+
+ /**
+ * Presence is unknown.
+ */
UNKNOWN,
+
+ /**
+ * Presence is invalid.
+ */
ERROR
}
+/**
+ * Interface for {@link Persona}s or {@link Individual}s which have a presence;
+ * their current availability, such as for chatting.
+ */
public interface Folks.Presence : Object
{
public abstract Folks.PresenceType presence_type