troelsfr / gasp Goto Github PK
View Code? Open in Web Editor NEWGasp is a bridge between Doxygen and Sphinx allowing import of Doxygen doc in Sphinx.
License: MIT License
Gasp is a bridge between Doxygen and Sphinx allowing import of Doxygen doc in Sphinx.
License: MIT License
Hi :)
For the following class:
<?php
namespace Test;
/**
*
* Class dexcription
* @author john Doe
*/
class Dog {
/**
* @var string couleur du chien
*/
private $color = 'Red';
/**
* @var string om du chien
*/
protected $name;
/**
* @param $color : couleur à donner au chien
* @param string $name: Par défaur un nom bateau
*/
public function __construct($color, $name='Todor') {
$this->color = $color;
$this->name = $name;
}
/**
* Return object hello word
* @return String
*/
public function getHello(Dog $dog) {
return 'Whaff';
}
/**
* Existential question
* @return string
*/
protected function whoAmI() {
return 'a dog ?';
}
}
And corresponding doxygen xml:
doc/xml/Dog_8php.xml
<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="1.8.6">
<compounddef id="Dog_8php" kind="file">
<compoundname>Dog.php</compoundname>
<innerclass refid="classTest_1_1Dog" prot="public">Test::Dog</innerclass>
<innernamespace refid="namespaceTest">Test</innernamespace>
<briefdescription>
</briefdescription>
<detaileddescription>
</detaileddescription>
<programlisting>
<codeline lineno="1"><highlight class="normal"><?php</highlight></codeline>
<codeline lineno="2"><highlight class="normal"></highlight></codeline>
<codeline lineno="3"><highlight class="normal"></highlight><highlight class="keyword">namespace<sp/></highlight><highlight class="normal">Test;</highlight></codeline>
<codeline lineno="4"><highlight class="normal"></highlight></codeline>
<codeline lineno="10" refid="classTest_1_1Dog" refkind="compound"><highlight class="keyword">class<sp/></highlight><highlight class="normal"><ref refid="classTest_1_1Dog" kindref="compound">Dog</ref><sp/>{</highlight></codeline>
<codeline lineno="11"><highlight class="normal"></highlight></codeline>
<codeline lineno="15"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">private</highlight><highlight class="normal"><sp/>$color<sp/>=<sp/></highlight><highlight class="stringliteral">'Red'</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="16"><highlight class="normal"></highlight></codeline>
<codeline lineno="20"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">protected</highlight><highlight class="normal"><sp/>$name;</highlight></codeline>
<codeline lineno="21"><highlight class="normal"></highlight></codeline>
<codeline lineno="26"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">public</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">function</highlight><highlight class="normal"><sp/>__construct($color,<sp/>$name=</highlight><highlight class="stringliteral">'Todor'</highlight><highlight class="normal">)<sp/>{</highlight></codeline>
<codeline lineno="27"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>$this->color<sp/>=<sp/>$color;</highlight></codeline>
<codeline lineno="28"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>$this->name<sp/>=<sp/>$name;</highlight></codeline>
<codeline lineno="29"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="30"><highlight class="normal"></highlight></codeline>
<codeline lineno="35"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">public</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">function</highlight><highlight class="normal"><sp/>getHello(<ref refid="classTest_1_1Dog" kindref="compound">Dog</ref><sp/>$dog)<sp/>{</highlight></codeline>
<codeline lineno="36"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/></highlight><highlight class="stringliteral">'Whaff'</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="37"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="38"><highlight class="normal"></highlight></codeline>
<codeline lineno="43"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">protected</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">function</highlight><highlight class="normal"><sp/>whoAmI()<sp/>{</highlight></codeline>
<codeline lineno="44"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/></highlight><highlight class="stringliteral">'a<sp/>dog<sp/>?'</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="45"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="46"><highlight class="normal"><sp/></highlight></codeline>
<codeline lineno="47"><highlight class="normal">}</highlight></codeline>
</programlisting>
<location file="/home/bsevajol/projects/tests/gasp-test/Dog.php"/>
</compounddef>
</doxygen>
And sphinx rst doc:
Dog class overview
==================
.. doxygen:: class/synopsis
Test::Dog
:public:
:protected:
:private:
:all:
HTML output like (class/synopsis):
class Test::Dog
Member Description
$color
__construct
getHello
$name and whoAmI protected attribute/methods are not documented. I make something wrong or it's a bug? Thank's !
We think Gasp is neat and would like to investigate using it for Large Synoptic Survey Telescope documentation. Unfortunately, we can't legally do that until Gasp has a license.
Would you consider putting a license on this repo? See http://choosealicense.com Any open source license would make us happy.
If the code is licensed and we choose to use it on our doc stack, would you generally be receptive to pull requests from us for things like a setup.py
, etc.?
I come from Breathe and i have trouble with PHP doc generation (see here). Do i will have same trouble with Gasp ?
Hi,
pip installation of Gasp fail:
Downloading/unpacking gasp
Downloading gasp-0.4.0.tar.gz
Running setup.py (path:/tmp/pip_build_root/gasp/setup.py) egg_info for package gasp
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/tmp/pip_build_root/gasp/setup.py", line 20, in <module>
read('CHANGES.txt')
File "/tmp/pip_build_root/gasp/setup.py", line 5, in read
text = open(os.path.join(os.path.dirname(__file__), *rnames)).read()
IOError: [Errno 2] No such file or directory: '/tmp/pip_build_root/gasp/CHANGES.txt'
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/tmp/pip_build_root/gasp/setup.py", line 20, in <module>
read('CHANGES.txt')
File "/tmp/pip_build_root/gasp/setup.py", line 5, in read
text = open(os.path.join(os.path.dirname(__file__), *rnames)).read()
IOError: [Errno 2] No such file or directory: '/tmp/pip_build_root/gasp/CHANGES.txt'
----------------------------------------
Cleaning up...
CHANGES.txt
seems to be delete.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.