Skip to content
Snippets Groups Projects
Commit 518b4b04 authored by Sébastien Blin's avatar Sébastien Blin
Browse files

misc: remove unused files

Major part seems from SFLPhone

Change-Id: Icc557d84acf96b35520a03e998b710fb553c93b1
parent a290a6f7
No related branches found
No related tags found
No related merge requests found
Showing
with 0 additions and 3114 deletions
include $(top_srcdir)/globals.mk
XSLTPROC=xsltproc --xinclude --nonet
PYTHON=python
XMLS= $(wildcard $(top_srcdir)/src/dbus/spec/*.xml)
TEMPLATES= $(wildcard doc/templates/*)
GENERATED_FILES = \
doc/spec.html \
doc/spec/index.html
doc/spec.html: $(XMLS) tools/doc-generator.xsl
@install -d tmp/doc
$(XSLTPROC) tools/doc-generator.xsl spec/all.xml > tmp/$@
mv tmp/$@ $@
doc/spec/index.html: $(XMLS) tools/doc-generator.py tools/specparser.py $(TEMPLATES)
@install -d tmp/doc
$(PYTHON) tools/doc-generator.py spec/all.xml doc/spec sflphone-spec cx.ring.Ring
doc: $(GENERATED_FILES)
clean-local:
rm -rf $(GENERATED_FILES)
rm -rf doc/spec
rm -rf tmp
SFLphone D-Bus API documentation. Generated with xsltproc.
Wiki reference: https://projects.savoirfairelinux.com/wiki/sflphone/Dbus-API
Run Makefile to generate the HTML API documentation, from the xml interfaces in *sflphone-common/src/dbus*.
The documentation is generated in *sflphone-common/doc/dbus-api/doc/spec*
<?xml version="1.0"?>
<book xmlns="http://www.devhelp.net/book" title="$spec.title" name="$name" link="index.html">
<chapters>
#for $interface in $spec.interfaces
<sub name="$interface.name" link="$interface.get_url()"/>
#end for
<sub name="Generic Types" link="generic-types.html"/>
<sub name="Errors" link="errors.html"/>
<sub name="Full Index" link="fullindex.html"/>
</chapters>
<functions>
#for $obj in $spec.everything.values() + $spec.types.values() + $spec.errors.values()
<keyword type="$obj.devhelp_name" name="$obj.get_title()" link="$obj.get_url()" #slurp
#if $obj.deprecated: deprecated="true" #slurp
/>
#end for
</functions>
</book>
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" "">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Errors</title>
<link rel="stylesheet" href="style.css" type="text/css"/>
</head>
<body>
<div class="header">
<h1>Errors</h1>
<a href="index.html">Interface Index</a>
(<a href="interfaces.html">Compact</a>)
| <a href="#summary">Summary</a>
| <a href="#errors">Errors</a>
</div>
<div class="main">
<div class="summary">
<a name="summary"></a>
<h3>Errors</h3>
<table class="summary">
#for $error in $spec.errors.values()
#if $error.deprecated
<tr class="deprecated">
#else
<tr>
#end if
<td><a href="$error.get_url()">$error.short_name</a></td>
<td>
#if $error.deprecated: (deprecated)
</td>
</tr>
#end for
</table>
</div>
<div class="outset errors error">
<a name="errors"></a>
<h1>Errors</h1>
#for $error in $spec.errors.values()
<div class="inset error">
<a name="$error.name"></a>
<span class="permalink">(<a href="$error.get_url()">Permalink</a>)</span>
<h2>
$error.short_name
</h2>
<div class="indent">
<code>$error.name</code>
</div>
$error.get_added()
$error.get_deprecated()
$error.get_docstring()
</div>
#end for
</div>
</div>
</body>
</html>
#from itertools import groupby
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" "">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Full Index</title>
<link rel="stylesheet" href="style.css" type="text/css"/>
</head>
#set $star = []
#for $item in $spec.everything.values() + $spec.errors.values() + $spec.generic_types
#echo $star.append(($item.short_name, $item))
#slurp
#end for
#echo $star.sort(key = lambda t: t[0].title())
#slurp
## one use iterators...
#set $groups = [ (l, list(g)) for l, g in (groupby($star, key = lambda t: t[0][0].upper())) ]
#set $letters = set(map(lambda t: t[0], groups))
<body>
<div class="header">
<h1>Full Index</h1>
<a href="index.html">Interface Index</a>
(<a href="interfaces.html">Compact</a>)
#for $a in map(chr, xrange(ord('A'), ord('Z')+1))
#if $a in $letters
| <a href="#$a">$a</a>
#else
| $a
#end if
#end for
</div>
<div class="main">
<table class="summary">
#for l, g in $groups
<tr><th colspan="3"><a name="$l"></a>$l</th></tr>
#for $n in $g
#if $n[1].deprecated
<tr class="deprecated">
#else
<tr>
#end if
<td>
<a href="$n[1].get_url()" title="$n[1].get_title()">$n[0]</a>
#if $n[1].deprecated: (deprecated)
</td>
<td>$n[1].get_type_name()</td>
<td>
#if $n[1].parent.__class__.__name__ == 'Interface': $n[1].parent.name
</td>
</tr>
#end for
#end for
<table>
</div>
</body>
</html>
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" "">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Generic Types</title>
<link rel="stylesheet" href="style.css" type="text/css"/>
</head>
<body>
<div class="header">
<h1>Generic Types</h1>
<a href="index.html">Interface Index</a>
(<a href="interfaces.html">Compact</a>)
| <a href="#summary">Summary</a>
| <a href="#types">Types</a>
</div>
<div class="main">
<div class="summary">
<a name="summary"></a>
<h3>Generic Types</h3>
<table class="summary">
#for $type in $spec.generic_types
#if $type.deprecated
<tr class="deprecated">
#else
<tr>
#end if
<td><a href="$type.get_url()">$type.short_name</a></td>
<td>$type.get_type_name()</td>
<td>$type.dbus_type</td>
<td>
#if $type.deprecated: (deprecated)
</td>
</tr>
#end for
</table>
</div>
<div class="outset types type">
<a name="types"></a>
<h1>Generic Types</h1>
#for $type in $spec.generic_types
<div class="inset type">
<a name="$type.name"></a>
<span class="permalink">$type.get_type_name() (<a href="$type.get_url()">Permalink</a>)</span>
<h2>
$type.short_name &mdash; $type.dbus_type
</h2>
$type.get_added()
$type.get_deprecated()
$type.get_docstring()
$type.get_breakdown()
</div>
#end for
</div>
</div>
</body>
</html>
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" "">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>$spec.title &mdash v$spec.version</title>
<link rel="stylesheet" href="style.css" type="text/css"/>
</head>
<body>
<div class="header">
<h1>$spec.title</h1>
<a href="#interfaces">Interfaces</a>
(<a href="interfaces.html">Compact</a>)
| <a href="generic-types.html">Generic Types</a>
| <a href="errors.html">Errors</a>
| <a href="fullindex.html">Full Index</a>
</div>
<div class="main">
<h3 class="version">Version $spec.version</h3>
<p class="copyrights">
#echo '<br/>'.join($spec.copyrights)
</p>
$spec.license
<a name="interfaces"></a>
<h3>Interfaces</h3>
<ul>
#def output($items)
#for $item in $items
#if $item.__class__.__name__ == 'Section'
<li class="chapter">$item.short_name</li>
$item.get_docstring()
<ul>
$output($item.items)
</ul>
#else
#if $item.causes_havoc
<li class="causes-havoc">
#elif $item.deprecated
<li class="deprecated">
#else
<li>
#end if
<a href="$item.get_url()">$item.name</a>
#if $item.causes_havoc
(unstable)
#elif $item.deprecated
(deprecated)
#end if
</li>
#end if
#end for
#end def
$output($spec.items)
</ul>
<a name="other"></a>
<h3>Other</h3>
<ul>
<li><a href="generic-types.html">Generic Types</a></li>
<li><a href="errors.html">Errors</a></li>
</ul>
</div>
</body>
</html>
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" "">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>$interface.name</title>
<link rel="stylesheet" href="style.css" type="text/css"/>
</head>
<body>
<div class="header">
<h1>Interface $interface.name</h1>
<a href="index.html">Interface Index</a>
(<a href="interfaces.html">Compact</a>)
| <a href="#summary">Summary</a>
#if $interface.docstring: | <a href="#description">Description</a>
#if $interface.methods: | <a href="#methods">Methods</a>
#if $interface.signals: | <a href="#signals">Signals</a>
#if $interface.properties: | <a href="#properties">Properties</a>
#if $interface.tpproperties: | <a href="#tpproperties">Telepathy Properties</a>
#if $interface.contact_attributes: | <a href="#contact-attributes">Contact Attributes</a>
#if $interface.handler_capability_tokens: | <a href="#handler-capability-tokens">Handler Capability Tokens</a>
#if $interface.types: | <a href="#types">Types</a>
</div>
<div class="main">
#if $interface.methods or $interface.signals or $interface.properties or $interface.types or $interface.tpproperties
<div class="summary">
<a name="summary"></a>
#if $interface.methods
<h3>Methods</h3>
<table class="summary">
#for $method in $interface.methods
#if $method.deprecated
<tr class="deprecated">
#else
<tr>
#end if
<td><a href="$method.get_url()">$method.short_name</a></td>
<td>($method.get_in_args())</td>
<td>&#8594;</td>
<td>$method.get_out_args()</td>
<td>
#if $method.deprecated: (deprecated)
</td>
</tr>
#end for
</table>
#end if
#if $interface.signals
<h3>Signals</h3>
<table class="summary">
#for $signal in $interface.signals
#if $signal.deprecated
<tr class="deprecated">
#else
<tr>
#end if
<td><a href="$signal.get_url()">$signal.short_name</a></td>
<td>($signal.get_args())</td>
<td>
#if $signal.deprecated: (deprecated)
</td>
</tr>
#end for
</table>
#end if
#if $interface.properties
<h3>Properties</h3>
<table class="summary">
#for $property in $interface.properties
#if $property.deprecated
<tr class="deprecated">
#else
<tr>
#end if
<td><a href="$property.get_url()">$property.short_name</a></td>
<td>
$property.dbus_type
#if $property.type: (<a href="$property.get_type_url()" title="$property.get_type_title()">$property.get_type().short_name</a>)
</td>
<td>$property.get_access()</td>
<td>
#if $property.deprecated: (deprecated)
</td>
</tr>
#end for
</table>
#end if
#if $interface.tpproperties
<h3>Telepathy Properties</h3>
<table class="summary">
#for $property in $interface.tpproperties
<tr class="deprecated">
<td><a href="$property.get_url()">$property.short_name</a></td>
<td>
$property.dbus_type
#if $property.type: (<a href="$property.get_type_url()" title="$property.get_type_title()">$property.get_type().short_name</a>)
</td>
</tr>
#end for
</table>
#end if
#if $interface.contact_attributes
<h3>Contact Attributes</h3>
<table class="summary">
#for $token in $interface.contact_attributes
<tr class="contact-attribute">
<td><a href="$token.get_url()">$token.name</a></td>
<td>
$token.dbus_type
#if $token.type: (<a href="$token.get_type_url()" title="$token.get_type_title()">$token.get_type().short_name</a>)
</td>
</tr>
#end for
</table>
#end if
#if $interface.handler_capability_tokens
<h3>Handler Capability Tokens</h3>
<table class="summary">
#for $token in $interface.handler_capability_tokens
<tr class="handler-capability-token">
<td><a href="$token.get_url()">$token.name</a>
#if $token.is_family
(etc.)
#end if
</td>
<td>
</td>
</tr>
#end for
</table>
#end if
#if $interface.types
<h3>Types</h3>
<table class="summary">
#for $type in $interface.types
#if type.deprecated
<tr class="deprecated">
#else
<tr>
#end if
<td><a href="$type.get_url()">$type.short_name</a></td>
<td>$type.get_type_name()</td>
<td>$type.dbus_type</td>
<td>
#if $type.deprecated: (deprecated)
</td>
</tr>
#end for
</table>
#end if
</div>
#end if
#if $interface.causes_havoc
<div class="havoc"><span class="warning">WARNING:</span>
This interface is $interface.causes_havoc and is likely to cause havoc
to your API/ABI if bindings are generated. Do not include this interface
in libraries that care about compatibility.
</div>
#end if
$interface.get_added()
$interface.get_changed()
$interface.get_deprecated()
#if $interface.requires
<div class="requires">
Objects implementing this interface must also implement:
<ul>
#for $req in $interface.get_requires()
<li><a href="$req.get_url()" title="$req.get_title()">$req.name</a></li>
#end for
</ul>
</div>
#end if
#if $interface.docstring
<a name="description"></a>
<h3>Description</h3>
$interface.get_docstring()
#end if
#if $interface.methods
<div class="outset methods method">
<a name="methods"></a>
<h1>Methods</h1>
#for $method in $interface.methods
<div class="inset method">
<a name="$method.name"></a>
<span class="permalink">(<a href="$method.get_url()">Permalink</a>)</span>
<h2>$method.short_name ($method.get_in_args()) &#8594; $method.get_out_args()</h2>
$method.get_added()
$method.get_changed()
$method.get_deprecated()
#if $method.in_args
<div class="indent">
<h3>Parameters</h3>
<ul>
#for $arg in $method.in_args
<li>
$arg.short_name &mdash; $arg.dbus_type
#if $arg.get_type(): (<a href="$arg.get_type_url()" title="$arg.get_type_title()">$arg.get_type().short_name</a>)
</li>
$arg.get_added()
$arg.get_changed()
$arg.get_deprecated()
$arg.get_docstring()
#end for
</ul>
</div>
#end if
#if $method.out_args
<div class="indent">
<h3>Returns</h3>
<ul>
#for $arg in $method.out_args
<li>
$arg.short_name &mdash; $arg.dbus_type
#if $arg.get_type(): (<a href="$arg.get_type_url()" title="$arg.get_type_title()">$arg.get_type().short_name</a>)
</li>
$arg.get_added()
$arg.get_changed()
$arg.get_deprecated()
$arg.get_docstring()
#end for
</ul>
</div>
#end if
$method.get_docstring()
#if $method.possible_errors
<hr/>
<div class="indent">
<h3>Possible Errors</h3>
<ul>
#for $error in $method.possible_errors
<li><a href="$error.get_url()" title="$error.get_title()">$error.get_error().short_name</a></li>
$error.get_added()
$error.get_changed()
$error.get_deprecated()
$error.get_docstring()
#end for
</ul>
</div>
#end if
</div>
#end for
</div>
#end if
#if $interface.signals
<div class="outset signals signal">
<a name="signals"></a>
<h1>Signals</h1>
#for $signal in $interface.signals
<div class="inset signal">
<a name="$signal.name"></a>
<span class="permalink">(<a href="$signal.get_url()">Permalink</a>)</span>
<h2>$signal.short_name ($signal.get_args())</h2>
$signal.get_added()
$signal.get_changed()
$signal.get_deprecated()
#if $signal.args
<div class="indent">
<h3>Parameters</h3>
<ul>
#for $arg in $signal.args
<li>
$arg.short_name &mdash; $arg.dbus_type
#if $arg.get_type(): (<a href="$arg.get_type_url()" title="$arg.get_type_title()">$arg.get_type().short_name</a>)
</li>
$arg.get_added()
$arg.get_changed()
$arg.get_deprecated()
$arg.get_docstring()
#end for
</ul>
</div>
#end if
$signal.get_docstring()
</div>
#end for
</div>
#end if
#if $interface.properties
<div class="outset properties property">
<a name="properties"></a>
<h1>Properties</h1>
<div>
Accessed using the org.freedesktop.DBus.Properties interface.
</div>
#for $property in $interface.properties
<div class="inset property">
<a name="$property.name"></a>
<span class="permalink">(<a href="$property.get_url()">Permalink</a>)</span>
<h2>
$property.short_name &mdash; $property.dbus_type
#if $property.type: (<a href="$property.get_type_url()" title="$property.get_type_title()">$property.get_type().short_name</a>)
</h2>
<div class="access">$property.get_access()</div>
$property.get_added()
$property.get_changed()
$property.get_deprecated()
$property.get_docstring()
</div>
#end for
</div>
#end if
#if $interface.tpproperties
<div class="outset tpproperties tpproperty">
<a name="tpproperties"></a>
<h1>Telepathy Properties</h1>
<div>
Accessed using the org.freedesktop.Telepathy.Properties interface.
</div>
#for $property in $interface.tpproperties
<div class="inset tpproperty">
<a name="$property.name"></a>
<span class="permalink">(<a href="$property.get_url()">Permalink</a>)</span>
<h2>
$property.short_name &mdash; $property.dbus_type
#if $property.type: (<a href="$property.get_type_url()" title="$property.get_type_title()">$property.get_type().short_name</a>)
</h2>
$property.get_added()
$property.get_changed()
$property.get_deprecated()
$property.get_docstring()
</div>
#end for
</div>
#end if
#if $interface.contact_attributes
<div class="outset contact-attributes">
<a name="contact-attributes"></a>
<h1>Contact Attributes</h1>
<div>
Attributes that a contact can have, accessed with the
org.freedesktop.Telepathy.Connection.Interface.Contacts interface.
</div>
#for $token in $interface.contact_attributes
<div class="inset contact-attribute">
<a name="$token.name"></a>
<span class="permalink">(<a href="$token.get_url()">Permalink</a>)</span>
<h2>
$token.name &mdash; $token.dbus_type
#if $token.type: (<a href="$token.get_type_url()" title="$token.get_type_title()">$token.get_type().short_name</a>)
</h2>
$token.get_added()
$token.get_changed()
$token.get_deprecated()
$token.get_docstring()
</div>
#end for
</div>
#end if
#if $interface.handler_capability_tokens
<div class="outset handler-capability-tokens">
<a name="handler-capability-tokens"></a>
<h1>Handler Capability Tokens</h1>
<div>
Tokens representing capabilities that a Client.Handler can have.
</div>
#for $token in $interface.handler_capability_tokens
<div class="inset handler-capability-token">
<a name="$token.name"></a>
<span class="permalink">(<a href="$token.get_url()">Permalink</a>)</span>
<h2>
$token.name
#if $token.is_family
(etc.)
#end if
</h2>
$token.get_added()
$token.get_changed()
$token.get_deprecated()
$token.get_docstring()
</div>
#end for
</div>
#end if
#if $interface.types
<div class="outset types type">
<a name="types"></a>
<h1>Types</h1>
#for $type in $interface.types
<div class="inset type">
<a name="$type.name"></a>
<span class="permalink">$type.get_type_name() (<a href="$type.get_url()">Permalink</a>)</span>
<h2>
$type.short_name &mdash; $type.dbus_type
</h2>
$type.get_added()
$type.get_changed()
$type.get_deprecated()
$type.get_docstring()
$type.get_breakdown()
</div>
#end for
</div>
#end if
</div>
</body>
</html>
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" "">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>$spec.title &mdash v$spec.version</title>
<link rel="stylesheet" href="style.css" type="text/css"/>
</head>
<body>
<div class="header">
<h1>$spec.title</h1>
<a href="index.html">Full</a>
| <a href="generic-types.html">Generic Types</a>
| <a href="errors.html">Errors</a>
| <a href="fullindex.html">Full Index</a>
</div>
<div class="main">
<b>Version $spec.version</b>
<a name="interfaces"></a>
<h3>Interfaces</h3>
<ul>
#for $interface in $spec.interfaces
#if $interface.causes_havoc
<li class="causes-havoc">
#elif $interface.deprecated
<li class="deprecated">
#else
<li>
#end if
<a href="$interface.get_url()">$interface.name</a>
#if $interface.causes_havoc
(unstable)
#elif $interface.deprecated
(deprecated)
#end if
</li>
#end for
</ul>
<a name="other"></a>
<h3>Other</h3>
<ul>
<li><a href="generic-types.html">Generic Types</a></li>
<li><a href="errors.html">Errors</a></li>
</ul>
</div>
</body>
</html>
html, body,
h1, h2 {
font-family: "Georgia";
margin: 0;
padding: 0;
}
h3 {
margin-top: 2pt;
margin-bottom: 2pt;
}
ul {
margin: 1ex;
margin-left: 1.5em;
padding: 0;
}
hr {
border-style: none;
color: #cccccc;
background-color: #cccccc;
height: 1px;
}
div.header {
position: fixed;
height: 4em;
background-color: AliceBlue;
width: 100%;
margin: 0;
padding: 0.5ex;
border-bottom: 1px solid black;
top: 0;
left: 0;
z-index: 1;
}
div.header h1 {
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
}
div.main {
margin-top: 5em;
margin-left: 1ex;
margin-right: 1ex;
margin-bottom: 1ex;
}
div.main a[name] {
position: relative;
top: -4.5em;
}
div.outset {
padding: 1ex;
margin-top: 1ex;
margin-bottom: 1ex;
}
div.inset {
background-color: white;
margin-top: 1ex;
margin-bottom: 1ex;
padding: 0.5ex;
}
div.indent {
margin-left: 1em;
}
div.methods {
background-color: #fcaf3e;
}
div.method {
border: 1px solid #f57900;
}
div.signals {
background-color: #729fcf;
}
div.signal {
border: 1px solid #3465a4;
}
div.properties {
background-color: #ad7fa8;
}
div.property {
border: 1px solid #75507b;
}
div.tpproperties {
background-color: #999999;
}
div.tpproperty {
border: 1px solid #333333;
}
div.contact-attributes {
background-color: #ccccff;
border: 1px solid #9999cc;
}
div.contact-attribute {
border: 1px solid #9999cc;
}
div.handler-capability-tokens {
background-color: #339933;
border: 1px solid #228822;
}
div.handler-capability-token {
border: 1px solid #228822;
}
div.types {
background-color: #e9b96e;
}
div.type {
border: 1px solid #c17d11;
}
div.errors {
background-color: #ef2929;
}
div.error {
border: 1px solid #cc0000;
}
div.access {
font-weight: bold;
margin-left: 1ex;
}
div.summary {
padding: 0.5ex;
background-color: #eeeeec;
border: 1px solid #d3d7cf;
}
table.summary {
margin: 1ex;
font-size: small;
}
table.summary td {
padding-right: 1ex;
}
li.chapter {
margin-top: 1ex;
font-weight: bold;
}
li.causes-havoc {
font-style: italic;
}
li.deprecated,
li.deprecated a,
table.summary tr.deprecated td,
table.summary tr.deprecated td a {
color: gray;
}
div.requires,
div.docstring {
margin: 1ex;
}
div.added {
border-left: 2px solid #4e9a06;
margin: 1ex;
padding-left: 1ex;
}
div.added span.version {
color: #4e9a06;
font-weight: bold;
}
div.changed {
border-left: 2px solid #8f5902;
margin: 1ex;
padding-left: 1ex;
}
div.changed span.version {
color: #8f5902;
font-weight: bold;
}
div.deprecated,
div.havoc {
border-left: 2px solid #a40000;
margin: 1ex;
padding-left: 1ex;
}
div.deprecated span.version,
span.warning {
color: #a40000;
font-weight: bold;
}
div.rationale {
border-left: 2px solid gray;
margin: 1ex;
padding-left: 1ex;
}
span.permalink {
float: right;
font-size: x-small;
}
.license {
clear: both;
border: 1px solid #dedede;
font-style: italic;
padding: 15px;
}
.copyrights {
clear: both;
float: right;
}
<tp:spec
xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0"
xmlns:xi="http://www.w3.org/2001/XInclude">
<tp:title>Jami D-Bus Interface Specification</tp:title>
<tp:version>2.3.0</tp:version>
<tp:copyright>Copyright ©2005-2022 Savoir-faire Linux Inc</tp:copyright>
<tp:license xmlns="http://www.w3.org/1999/xhtml">
<p>This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.</p>
<p>This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.</p>
<p>You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.</p>
</tp:license>
<tp:section name="Instances Manager">
<tp:docstring xmlns="http://www.w3.org/1999/xhtml">
<p>
An Instance Manager to handle multiple clients connections. Count the number of clients actually registered to the core. When initializing your client, you need to register it against the core by using this interface.
</p>
</tp:docstring>
<xi:include href="cx.ring.Ring.Instance.xml"/>
</tp:section>
<tp:section name="Call Manager">
<tp:docstring xmlns="http://www.w3.org/1999/xhtml">
<p>
A Call Manager to handle call-related features.
</p>
</tp:docstring>
<xi:include href="cx.ring.Ring.CallManager.xml"/>
</tp:section>
<tp:section name="Configuration Manager">
<tp:docstring xmlns="http://www.w3.org/1999/xhtml">
<p>
A Configuration Manager to handle account configuration, user preferences, ...
</p>
</tp:docstring>
<xi:include href="cx.ring.Ring.ConfigurationManager.xml"/>
</tp:section>
<xi:include href="generic-types.xml"/>
</tp:spec>
../../../src/client/dbus/callmanager-introspec.xml
\ No newline at end of file
../../../src/client/dbus/configurationmanager-introspec.xml
\ No newline at end of file
<?xml version="1.0" ?>
<tp:errors xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0" namespace="org.freedesktop.Telepathy.Error">
<tp:error name="Network Error">
<tp:docstring>
Raised when there is an error reading from or writing to the network.
</tp:docstring>
</tp:error>
<tp:error name="Not Implemented">
<tp:docstring>
Raised when the requested method, channel, etc is not available on this connection.
</tp:docstring>
</tp:error>
<tp:error name="Invalid Argument">
<tp:docstring>
Raised when one of the provided arguments is invalid.
</tp:docstring>
</tp:error>
<tp:error name="Not Available">
<tp:docstring>
Raised when the requested functionality is temporarily unavailable.
</tp:docstring>
</tp:error>
<tp:error name="Permission Denied">
<tp:docstring>
The user is not permitted to perform the requested operation.
</tp:docstring>
</tp:error>
<tp:error name="Disconnected">
<tp:docstring>
The connection is not currently connected and cannot be used.
This error may also be raised when operations are performed on a
Connection for which
<tp:dbus-ref namespace="org.freedesktop.Telepathy.Connection">StatusChanged</tp:dbus-ref>
has signalled status Disconnected for reason None.
<tp:rationale>
The second usage corresponds to None in the
<tp:type>Connection_Status_Reason</tp:type> enum; if a better reason
is available, the corresponding error should be used instead.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Invalid Handle">
<tp:docstring>
The handle specified is unknown on this channel or connection.
</tp:docstring>
</tp:error>
<tp:error name="Channel.Banned">
<tp:docstring>
You are banned from the channel.
</tp:docstring>
</tp:error>
<tp:error name="Channel.Full">
<tp:docstring>
The channel is full.
</tp:docstring>
</tp:error>
<tp:error name="Channel.Invite Only">
<tp:docstring>
The requested channel is invite-only.
</tp:docstring>
</tp:error>
<tp:error name="Not Yours">
<tp:docstring xmlns="http://www.w3.org/1999/xhtml">
<p>The requested channel or other resource already exists, and another
user interface in this session is responsible for it.</p>
<p>User interfaces SHOULD handle this error unobtrusively, since it
indicates that some other user interface is already processing the
channel.</p>
</tp:docstring>
</tp:error>
<tp:error name="Cancelled">
<tp:docstring>
Raised by an ongoing request if it is cancelled by user request before
it has completed, or when operations are performed on an object which
the user has asked to close (for instance, a Connection where the user
has called Disconnect, or a Channel where the user has called Close).
<tp:rationale>
The second form can be used to correspond to the Requested member in
the <tp:type>Connection_Status_Reason</tp:type> enum, or to
to represent the situation where disconnecting a Connection,
closing a Channel, etc. has been requested by the user but this
request has not yet been acted on, for instance because the
service will only act on the request when it has finished processing
an event queue.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Authentication Failed">
<tp:docstring>
Raised when authentication with a service was unsuccessful.
<tp:rationale>
This corresponds to Authentication_Failed in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Encryption Not Available">
<tp:docstring>
Raised if a user request insisted that encryption should be used,
but encryption was not actually available.
<tp:rationale>
This corresponds to part of Encryption_Error in the
<tp:type>Connection_Status_Reason</tp:type> enum. It's been separated
into a distinct error here because the two concepts that were part
of EncryptionError seem to be things that could reasonably appear
differently in the UI.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Encryption Error">
<tp:docstring>
Raised if encryption appears to be available, but could not actually be
used (for instance if SSL/TLS negotiation fails).
<tp:rationale>
This corresponds to part of Encryption_Error in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Not Provided">
<tp:docstring>
Raised if the server did not provide a SSL/TLS certificate. This error
MUST NOT be used to represent the absence of a client certificate
provided by the Telepathy connection manager.
<tp:rationale>
This corresponds to Cert_Not_Provided in the
<tp:type>Connection_Status_Reason</tp:type> enum. That error
explicitly applied only to server SSL certificates, so this one
is similarly limited; having the CM present a client certificate
is a possible future feature, but it should have its own error
handling.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Untrusted">
<tp:docstring>
Raised if the server provided a SSL/TLS certificate signed by an
untrusted certifying authority. This error SHOULD NOT be used to
represent a self-signed certificate: see the Self Signed error for that.
<tp:rationale>
This corresponds to Cert_Untrusted in the
<tp:type>Connection_Status_Reason</tp:type> enum, with a clarification
to avoid ambiguity.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Expired">
<tp:docstring>
Raised if the server provided an expired SSL/TLS certificate.
<tp:rationale>
This corresponds to Cert_Expired in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Not Activated">
<tp:docstring>
Raised if the server provided an SSL/TLS certificate that will become
valid at some point in the future.
<tp:rationale>
This corresponds to Cert_Not_Activated in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Fingerprint Mismatch">
<tp:docstring>
Raised if the server provided an SSL/TLS certificate that did not have
the expected fingerprint.
<tp:rationale>
This corresponds to Cert_Fingerprint_Mismatch in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Hostname Mismatch">
<tp:docstring>
Raised if the server provided an SSL/TLS certificate that did not match
its hostname.
<tp:rationale>
This corresponds to Cert_Hostname_Mismatch in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Self Signed">
<tp:docstring>
Raised if the server provided an SSL/TLS certificate that is self-signed
and untrusted.
<tp:rationale>
This corresponds to Cert_Hostname_Mismatch in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Cert.Invalid">
<tp:docstring>
Raised if the server provided an SSL/TLS certificate that is
unacceptable in some way that does not have a more specific error.
<tp:rationale>
This corresponds to Cert_Other_Error in the
<tp:type>Connection_Status_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Not Capable">
<tp:docstring>
Raised when requested functionality is unavailable due to contact
not having required capabilities.
</tp:docstring>
</tp:error>
<tp:error name="Offline">
<tp:docstring>
Raised when requested functionality is unavailable because a contact is
offline.
<tp:rationale>
This corresponds to Offline in the
<tp:type>Channel_Group_Change_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Channel.Kicked">
<tp:docstring>
Used to represent a user being ejected from a channel by another user,
for instance being kicked from a chatroom.
<tp:rationale>
This corresponds to Kicked in the
<tp:type>Channel_Group_Change_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Busy">
<tp:docstring>
Used to represent a user being removed from a channel because of a
"busy" indication. This error SHOULD NOT be used to represent a server
or other infrastructure being too busy to process a request - for that,
see ServerBusy.
<tp:rationale>
This corresponds to Busy in the
<tp:type>Channel_Group_Change_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="No Answer">
<tp:docstring>
Used to represent a user being removed from a channel because they did
not respond, e.g. to a StreamedMedia call.
<tp:rationale>
This corresponds to No_Answer in the
<tp:type>Channel_Group_Change_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Does Not Exist">
<tp:docstring>
Raised when the requested user does not, in fact, exist.
<tp:rationale>
This corresponds to Invalid_Contact in the
<tp:type>Channel_Group_Change_Reason</tp:type> enum, but can also be
used to represent other things not existing (like chatrooms, perhaps).
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Terminated">
<tp:docstring>
Raised when a channel is terminated for an unspecified reason. In
particular, this error SHOULD be used whenever normal termination of
a 1-1 StreamedMedia call by the remote user is represented as a D-Bus
error name.
<tp:rationale>
This corresponds to None in the
<tp:type>Channel_Group_Change_Reason</tp:type> enum.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Connection Refused">
<tp:docstring>
Raised when a connection is refused.
</tp:docstring>
</tp:error>
<tp:error name="Connection Failed">
<tp:docstring>
Raised when a connection can't be established.
</tp:docstring>
</tp:error>
<tp:error name="Connection Lost">
<tp:docstring>
Raised when a connection is broken.
</tp:docstring>
</tp:error>
<tp:error name="Already Connected">
<tp:docstring>
Raised when the user attempts to connect to an account but they are
already connected (perhaps from another client or computer), and the
protocol or account settings do not allow this.
<tp:rationale>
XMPP can have this behaviour if the user chooses the same resource
in both clients (it is server-dependent whether the result is
AlreadyConnected on the new connection, ConnectionReplaced on the
old connection, or two successful connections).
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Connection Replaced">
<tp:docstring>
Raised by an existing connection to an account if it is replaced by
a new connection (perhaps from another client or computer).
<tp:rationale>
In MSNP, when connecting twice with the same Passport, the new
connection "wins" and the old one is automatically disconnected.
XMPP can also have this behaviour if the user chooses the same
resource in two clients (it is server-dependent whether the result is
AlreadyConnected on the new connection, ConnectionReplaced on the
old connection, or two successful connections).
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Registration Exists">
<tp:docstring>
Raised during in-band registration if the server indicates that the
requested account already exists.
</tp:docstring>
</tp:error>
<tp:error name="Service Busy">
<tp:docstring xmlns="http://www.w3.org/1999/xhtml">
Raised if a server or some other piece of infrastructure cannot process
the request, e.g. due to resource limitations. Clients MAY try again
later.
<tp:rationale>
This is not the same error as Busy, which indicates that a
<em>user</em> is busy.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:error name="Resource Unavailable">
<tp:docstring>
Raised if a request cannot be satisfied because a process local to the
user has insufficient resources. Clients MAY try again
later.
<tp:rationale>
For instance, the <tp:dbus-ref
namespace="org.freedesktop.Telepathy">ChannelDispatcher</tp:dbus-ref>
might raise this error for some or all channel requests if it has
detected that there is not enough free memory.
</tp:rationale>
</tp:docstring>
</tp:error>
<tp:copyright>Copyright © 2005-2009 Collabora Limited</tp:copyright>
<tp:copyright>Copyright © 2005-2009 Nokia Corporation</tp:copyright>
<tp:license xmlns="http://www.w3.org/1999/xhtml">
<p>This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.</p>
<p>This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.</p>
<p>You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.</p>
</tp:license>
</tp:errors>
<tp:generic-types
xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0">
<tp:simple-type name="Unix_Timestamp" type="u">
<tp:docstring>An unsigned 32-bit integer representing time as the number
of seconds elapsed since the Unix epoch
(1970-01-01T00:00:00Z)</tp:docstring>
</tp:simple-type>
<tp:simple-type name="Unix_Timestamp64" type="x">
<tp:docstring>An signed 64-bit integer representing time as the number
of seconds elapsed since the Unix epoch
(1970-01-01T00:00:00Z); negative for times before the epoch</tp:docstring>
<tp:rationale>The Text interface is the only user of Unix_Timestamp so
far, and we'd like to be Y2038 compatible in future
interfaces.</tp:rationale>
</tp:simple-type>
<tp:simple-type name="DBus_Bus_Name" type="s"
array-name="DBus_Bus_Name_List">
<tp:docstring>A string representing a D-Bus bus name - either a well-known
name like "org.freedesktop.Telepathy.MissionControl" or a unique name
like ":1.123"</tp:docstring>
</tp:simple-type>
<tp:simple-type name="DBus_Well_Known_Name" type="s"
array-name="DBus_Well_Known_Name_List">
<tp:docstring>A string representing a D-Bus well-known
name like "org.freedesktop.Telepathy.MissionControl".</tp:docstring>
</tp:simple-type>
<tp:simple-type name="DBus_Unique_Name" type="s"
array-name="DBus_Unique_Name_List">
<tp:docstring>A string representing a D-Bus unique name, such as
":1.123"</tp:docstring>
</tp:simple-type>
<tp:simple-type name="DBus_Interface" type="s"
array-name="DBus_Interface_List">
<tp:docstring>An ASCII string representing a D-Bus interface - two or more
elements separated by dots, where each element is a non-empty
string of ASCII letters, digits and underscores, not starting with
a digit. The maximum total length is 255 characters. For example,
"org.freedesktop.DBus.Peer".</tp:docstring>
</tp:simple-type>
<tp:simple-type name="DBus_Error_Name" type="s">
<tp:docstring>An ASCII string representing a D-Bus error. This is
syntactically the same as a <tp:type>DBus_Interface</tp:type>, but the
meaning is different.</tp:docstring>
</tp:simple-type>
<tp:simple-type name="DBus_Signature" type="s">
<tp:docstring>A string representing a D-Bus signature
(the 'g' type isn't used because of poor interoperability, particularly
with dbus-glib)</tp:docstring>
</tp:simple-type>
<tp:simple-type name="DBus_Member" type="s">
<tp:docstring>An ASCII string representing a D-Bus method, signal
or property name - a non-empty string of ASCII letters, digits and
underscores, not starting with a digit, with a maximum length of 255
characters. For example, "Ping".</tp:docstring>
</tp:simple-type>
<tp:simple-type name="DBus_Qualified_Member" type="s"
array-name="DBus_Qualified_Member_List">
<tp:docstring>A string representing the full name of a D-Bus method,
signal or property, consisting of a DBus_Interface, followed by
a dot, followed by a DBus_Member. For example,
"org.freedesktop.DBus.Peer.Ping".</tp:docstring>
</tp:simple-type>
<tp:mapping name="Qualified_Property_Value_Map"
array-name="Qualified_Property_Value_Map_List">
<tp:docstring>A mapping from strings representing D-Bus
properties (by their namespaced names) to their values.</tp:docstring>
<tp:member type="s" name="Key" tp:type="DBus_Qualified_Member">
<tp:docstring>
A D-Bus interface name, followed by a dot and a D-Bus property name.
</tp:docstring>
</tp:member>
<tp:member type="v" name="Value">
<tp:docstring>
The value of the property.
</tp:docstring>
</tp:member>
</tp:mapping>
<tp:mapping name="String_Variant_Map" array-name="String_Variant_Map_List">
<tp:docstring>A mapping from strings to variants representing extra
key-value pairs.</tp:docstring>
<tp:member type="s" name="Key"/>
<tp:member type="v" name="Value"/>
</tp:mapping>
<tp:mapping name="String_String_Map" array-name="String_String_Map_List">
<tp:docstring>A mapping from strings to strings representing extra
key-value pairs.</tp:docstring>
<tp:member type="s" name="Key"/>
<tp:member type="s" name="Value"/>
</tp:mapping>
<tp:struct name="Socket_Address_IP" array-name="Socket_Address_IP_List">
<tp:docstring>An IP address and port.</tp:docstring>
<tp:member type="s" name="Address">
<tp:docstring>Either a dotted-quad IPv4 address literal as for
<tp:type>Socket_Address_IPv4</tp:type>, or an RFC2373 IPv6 address
as for <tp:type>Socket_Address_IPv6</tp:type>.
</tp:docstring>
</tp:member>
<tp:member type="q" name="Port">
<tp:docstring>The TCP or UDP port number.</tp:docstring>
</tp:member>
</tp:struct>
<tp:struct name="Socket_Address_IPv4">
<tp:docstring>An IPv4 address and port.</tp:docstring>
<tp:member type="s" name="Address">
<tp:docstring>A dotted-quad IPv4 address literal: four ASCII decimal
numbers, each between 0 and 255 inclusive, e.g.
"192.168.0.1".</tp:docstring>
</tp:member>
<tp:member type="q" name="Port">
<tp:docstring>The TCP or UDP port number.</tp:docstring>
</tp:member>
</tp:struct>
<tp:struct name="Socket_Address_IPv6">
<tp:docstring>An IPv6 address and port.</tp:docstring>
<tp:member type="s" name="Address">
<tp:docstring>An IPv6 address literal as specified by RFC2373
section 2.2, e.g. "2001:DB8::8:800:200C:4171".</tp:docstring>
</tp:member>
<tp:member type="q" name="Port">
<tp:docstring>The TCP or UDP port number.</tp:docstring>
</tp:member>
</tp:struct>
<tp:struct name="Socket_Netmask_IPv4">
<tp:docstring>An IPv4 network or subnet.</tp:docstring>
<tp:member type="s" name="Address">
<tp:docstring>A dotted-quad IPv4 address literal: four ASCII decimal
numbers, each between 0 and 255 inclusive, e.g.
"192.168.0.1".</tp:docstring>
</tp:member>
<tp:member type="y" name="Prefix_Length">
<tp:docstring>The number of leading bits of the address that must
match, for this netmask to be considered to match an
address.</tp:docstring>
</tp:member>
</tp:struct>
<tp:struct name="Socket_Netmask_IPv6">
<tp:docstring>An IPv6 network or subnet.</tp:docstring>
<tp:member type="s" name="Address">
<tp:docstring>An IPv6 address literal as specified by RFC2373
section 2.2, e.g. "2001:DB8::8:800:200C:4171".</tp:docstring>
</tp:member>
<tp:member type="y" name="Prefix_Length">
<tp:docstring>The number of leading bits of the address that must
match, for this netmask to be considered to match an
address.</tp:docstring>
</tp:member>
</tp:struct>
</tp:generic-types>
../../../src/client/dbus/instance-introspec.xml
\ No newline at end of file
../../../src/client/dbus/presencemanager-introspec.xml
\ No newline at end of file
<!-- Generate a Devhelp index from the Telepathy specification.
The master copy of this stylesheet is in the Telepathy spec repository -
please make any changes there.
Copyright (C) 2006-2008 Collabora Limited
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:tp="http://telepathy.freedesktop.org/wiki/DbusSpec#extensions-v0">
<xsl:template match="/">
<book xmlns="http://www.devhelp.net/book" title="Telepathy Specification"
name="telepathy-spec" link="spec.html">
<xsl:text>&#x000a;</xsl:text>
<chapters>
<xsl:text>&#x000a;</xsl:text>
<xsl:apply-templates select="//interface" />
</chapters>
<xsl:text>&#x000a;</xsl:text>
<functions>
<xsl:text>&#x000a;</xsl:text>
<xsl:apply-templates select="//method" />
<xsl:apply-templates select="//signal" />
<xsl:apply-templates select="//property" />
<xsl:apply-templates select="//tp:enum" />
<xsl:apply-templates select="//tp:simple-type" />
<xsl:apply-templates select="//tp:mapping" />
<xsl:apply-templates select="//tp:flags" />
<xsl:apply-templates select="//tp:struct" />
</functions>
<xsl:text>&#x000a;</xsl:text>
</book>
</xsl:template>
<xsl:template match="interface">
<xsl:text> </xsl:text>
<sub xmlns="http://www.devhelp.net/book" name="{@name}"
link="{concat('spec.html#', @name)}" />
<xsl:text>&#x000a;</xsl:text>
</xsl:template>
<xsl:template match="method">
<xsl:text> </xsl:text>
<keyword type="function" xmlns="http://www.devhelp.net/book" name="{@name}"
link="spec.html#{../@name}.{@name}" />
<xsl:text>&#x000a;</xsl:text>
</xsl:template>
<xsl:template match="signal | property">
<xsl:text> </xsl:text>
<keyword type="" xmlns="http://www.devhelp.net/book" name="{@name}"
link="spec.html#{../@name}.{@name}" />
<xsl:text>&#x000a;</xsl:text>
</xsl:template>
<xsl:template match="tp:simple-type">
<xsl:text> </xsl:text>
<keyword type="typedef" xmlns="http://www.devhelp.net/book" name="{@name}"
link="spec.html#type-{@name}" />
<xsl:text>&#x000a;</xsl:text>
</xsl:template>
<xsl:template match="tp:enum | tp:flags">
<xsl:text> </xsl:text>
<keyword type="enum" xmlns="http://www.devhelp.net/book" name="{@name}"
link="spec.html#type-{@name}" />
<xsl:text>&#x000a;</xsl:text>
</xsl:template>
<xsl:template match="tp:mapping | tp:struct">
<xsl:text> </xsl:text>
<keyword type="struct" xmlns="http://www.devhelp.net/book" name="{@name}"
link="spec.html#type-{@name}" />
<xsl:text>&#x000a;</xsl:text>
</xsl:template>
</xsl:stylesheet>
#!/usr/bin/env python
#
# doc-generator.py
#
# Generates HTML documentation from the parsed spec using Cheetah templates.
#
# Copyright (C) 2009 Collabora Ltd.
#
# This library is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or (at
# your option) any later version.
#
# This library is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
# for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with this library; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# Authors: Davyd Madeley <davyd.madeley@collabora.co.uk>
#
import sys
import os
import os.path
import shutil
try:
from Cheetah.Template import Template
except ImportError, e:
print >> sys.stderr, e
print >> sys.stderr, "Install `python-cheetah'?"
sys.exit(-1)
import specparser
program, spec_file, output_path, project, namespace = sys.argv
template_path = os.path.join(os.path.dirname(program), '../doc/templates')
# make the output path
try:
os.mkdir(output_path)
except OSError:
pass
# copy in the CSS
shutil.copy(os.path.join(template_path, 'style.css'), output_path)
def load_template(filename):
try:
file = open(os.path.join(template_path, filename))
template_def = file.read()
file.close()
except IOError, e:
print >> sys.stderr, "Could not load template file `%s'" % filename
print >> sys.stderr, e
sys.exit(-1)
return template_def
spec = specparser.parse(spec_file, namespace)
# write out HTML files for each of the interfaces
# Not using render_template here to avoid recompiling it n times.
namespace = {}
template_def = load_template('interface.html')
t = Template(template_def, namespaces = [namespace])
for interface in spec.interfaces:
namespace['interface'] = interface
# open the output file
out = open(os.path.join(output_path, '%s.html' % interface.name), 'w')
print >> out, unicode(t).encode('utf-8')
out.close()
def render_template(name, namespaces, target=None):
if target is None:
target = name
namespace = { 'spec': spec }
template_def = load_template(name)
t = Template(template_def, namespaces=namespaces)
out = open(os.path.join(output_path, target), 'w')
print >> out, unicode(t).encode('utf-8')
out.close()
namespaces = { 'spec': spec }
render_template('generic-types.html', namespaces)
render_template('errors.html', namespaces)
render_template('interfaces.html', namespaces)
render_template('fullindex.html', namespaces)
dh_namespaces = { 'spec': spec, 'name': project }
render_template('devhelp.devhelp2', dh_namespaces,
target=('%s.devhelp2' % project))
# write out the TOC last, because this is the file used as the target in the
# Makefile.
render_template('index.html', namespaces)
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment