Génère une documentation

24 ans Messages postés 231 Date d'inscription lundi 27 novembre 2000 Statut Membre Dernière intervention 7 juillet 2008 - 15 mars 2007 à 10:32
Liverion Messages postés 296 Date d'inscription mardi 22 avril 2008 Statut Membre Dernière intervention 18 août 2008 - 23 avril 2008 à 16:00
Salut tout le monde
Comment recupere la docmentation de mon code source à partir des commentaires inclus directement dans le code ?

3 réponses

leprov Messages postés 1160 Date d'inscription vendredi 23 juillet 2004 Statut Membre Dernière intervention 21 octobre 2010 17
15 mars 2007 à 12:32
dans les propriétés du projet (click droit, propriétés dans l'arboresence sur le .csproj) tu vas dans l'onglet générer et tu coche "fichier de documentation xml". Apres tu créer une documentation au meme format que la msdn a partir de la doc xml mais il me semble qu'il faut un utilitaire dédié, peut etre que la quelqu'un sera plus apte a te renseigner
0
cs_coq Messages postés 6349 Date d'inscription samedi 1 juin 2002 Statut Membre Dernière intervention 2 août 2014 101
17 mars 2007 à 12:32
Salut,

Tu peux utiliser notamment SandCastle, actuellement en CTP.
Si .NET 1.1 il reste encore possible d'utiliser le bon vieux NDoc.
Tu peux aussi jeter un oeil à la liste d'outils de la catégorie Documentation - Code commenting de SharpToolbox.

/*
coq
MVP Visual C#
CoqBlog
*/
0
Liverion Messages postés 296 Date d'inscription mardi 22 avril 2008 Statut Membre Dernière intervention 18 août 2008
23 avril 2008 à 16:00
Autre logiciel disponible : doxygen qui permet de generer en xml, html ...

pour chaque methode tu dois avoir des balises ///<summary>
                                                                      /// description breve
                                                                      ///</summary>

au minimum.

Exemple  :

namespace SimulatorClient
{
    /// <summary>
    /// Main Windows
    /// </summary>
    publicpartial class MainWindows : Form
    {
        #region Variable
        /// <summary>
        /// Variable to communicate with Nadas Server
        /// </summary>
        private NADASClass talin1 = new NADASClass();

        /// <summary>
        /// Variable to handle with the data
        /// </summary>
        private simulationData dataFromFile = new simulationData();

        /// <summary>
        /// Variable to know if the simulation is started or not
        /// </summary>
        private bool started = false;

        /// <summary>
        ///Variable to know if the simulation is paused or not
        /// </summary>
        private bool paused = false;

        #endregion

        /// <summary>
        /// Constuctor for the main Windows
        /// </summary>
        ///
        /// public MainWindows()
        /// {
        ///    InitializeComponent();
        ///    // initialize the Nadas server
        ///    NadasInitialization();
        ///    // in the beginning the simulation is stopped
        ///    started = false;
        ///    // rapidity is set at one data per second                                               
        ///    timer1.Interval = 1000;
        /// }
        /// 

        public MainWindows()
        {
            InitializeComponent();
            // initialize the Nadas server
            NadasInitialization();
            // in the beginning the simulation is stopped
            started = false;
            // rapidity is set at one data per second                                              
            timer1.Interval = 1000;
        }
        /// <summary>
        /// Function called by the speed form
        /// </summary>
        ///
        /// number of data per second
        ///

        ///
        /// if (value != 0)
        ///{
        ///    timer1.Interval = 1000 / value;
        ///    speedLabel.Text = value.ToString();
        ///}
        /// 

        public void changeSpeed(int value)
        {

            if (value != 0)
            {
                timer1.Interval= 1000 / value;
                speedLabel.Text = value.ToString();
            }
           
        }
0
Rejoignez-nous