]> Creatis software - gdcm.git/blobdiff - src/gdcmArgMgr.h
Fix mistypings
[gdcm.git] / src / gdcmArgMgr.h
index bc1910af9c1aec48315b1fac10255276cc208f90..3bf350c963078c7bcfd36145c6fc54033a1afad6 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmArgMgr.h,v $
   Language:  C++
-  Date:      $Date: 2005/06/09 11:27:54 $
-  Version:   $Revision: 1.7 $
+  Date:      $Date: 2008/04/10 12:03:46 $
+  Version:   $Revision: 1.15 $
   
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
 #define  ___ARG_MGR__
 
 #include "gdcmCommon.h"
-#include <stdio.h> // for FILE
+#include <stdio.h>  // for FILE
 #include <stdlib.h> // For atof
 
-namespace gdcm
+namespace GDCM_NAME_SPACE
 {
 
 #define ID_RFILE_TEXT        "rt"
@@ -54,55 +54,61 @@ public:
    ArgMgr(int argc, char **argv);
    ~ArgMgr();
 
-   int    ArgMgrDefined           (const char *param);/* Checks if Param is defined*/
-   char  *ArgMgrValue             (const char *param);/* Returns Param value       */
-   char  *ArgMgrUnused            (void);             /* Returns a never used arg. */
-   int    ArgMgrSave              (char *);           /* Save of parameters out    */
-   int    ArgMgrUsage             (const char **usage);    /* Display program usage     */
-   int    ArgMgrPrintUnusedLabels (void);             /* Prints unused labels      */
-
-   int    ArgMgrGetInt   (const char *param, int);  /* Gets an int   (with default value)*/
-   float  ArgMgrGetFloat (const char *param, float);/* Gets a float  (with default value)*/
-   char  *ArgMgrGetString(const char *param, char*);/* Gets a string (with default value)*/
-   int    ArgMgrGetLabel (const char *param, char *, int);
+   int    ArgMgrDefined           (const char *param);  // Checks if Param is defined
+   char  *ArgMgrValue             (const char *param);  // Returns Param value 
+   const char  *ArgMgrUnused      (void);               // Returns a never used arg.
+   int    ArgMgrSave              (const char *);       // Save of parameters out
+   int    ArgMgrUsage             (const char **usage); // Display program usage 
+   int    ArgMgrPrintUnusedLabels (void);               // Prints unused labels
+
+   int    ArgMgrGetInt   (const char *param, int);  // Gets an int   (with default value)
+   float  ArgMgrGetFloat (const char *param, float);// Gets a float  (with default value)
+   const char  *ArgMgrGetString(const char *param, const char* ext = 0);// Gets a string (with default value)
+   int    ArgMgrGetLabel (const char *param, const char *, int);
   
-   int   ArgMgrWantInt   (const char *param, const char **usage);  /* Demands an int           */
-   float ArgMgrWantFloat (const char *param, const char **usage);  /* Demands a float          */
-   char *ArgMgrWantString(const char *param, const char **usage);  /* Demands a string         */
-   int   ArgMgrWantLabel (const char *param, char *, const char **usage);
+   int    ArgMgrWantInt   (const char *param, const char **usage);  // Demands an int 
+   float  ArgMgrWantFloat (const char *param, const char **usage);  // Demands a float
+   char  *ArgMgrWantString(const char *param, const char **usage);  // Demands a string
+   int    ArgMgrWantLabel (const char *param, char *, const char **usage);
 
-   int   *ArgMgrGetListOfInt   (const char *param, int *);   /* Gets a list of int       */
-   float *ArgMgrGetListOfFloat (const char *param, int *);   /* Gets a list of float     */
-   char **ArgMgrGetListOfString(const char *param, int *);   /* Gets a list of string    */
+   int   *ArgMgrGetListOfInt   (const char *param, int *);   // Gets a list of int 
+   float *ArgMgrGetListOfFloat (const char *param, int *);   // Gets a list of float
+   char **ArgMgrGetListOfString(const char *param, int *);   // Gets a list of string
 
-   int   * ArgMgrGetIntEnum     (const char *param, int *); /* Gets a list of int pairs  */
-   float * ArgMgrGetFloatEnum   (const char *param, int *); /* Gets a list of float pairs*/
+   int        *ArgMgrGetIntEnum     (const char *param, int *); // Gets a list of int pairs
+   uint16_t   *ArgMgrGetXInt16Enum  (const char *param, int *); // Gets a list of int16 pairs
+   float      *ArgMgrGetFloatEnum   (const char *param, int *); // Gets a list of float pairs
 
 private :
 
-   int    FiltreLong       (char *);
+   int    FiltreLong       (const char *);
    const char  *LoadedParam(const char *, FILE *);
-   int    ArgLoadFromFile  (char *);
+   int    ArgLoadFromFile  (const char *);
    void   ArgStdArgs       (void);
 
    // These ones are 'general purpose methods'
-   char  *maj             (char *);
-   char  *Majuscule       (const char *);
-   int IdStrCountChar     (char *chaine, int caract);
-   int *IdStrIntEnum      (char* value, int *number);
-   float *IdStrFloatEnum  (char* value, int *number);
+   char  *maj       (char *);
+   char  *Majuscule (const char *);
+
+   int       IdStrCountChar  (char *chaine,int caract);
+   int      *IdStrIntEnum    (char *value, int *number);
+   uint16_t *IdStrXInt16Enum (char *value, int *number);
+   float    *IdStrFloatEnum  (char *value, int *number);
 
 // --------------- Attributes ------------------------------
 
 private :
 
-   const char *ArgParamOut;    /* Output File Name for param */
+   const char *ArgParamOut;    // Output File Name for param
 
-   char *ArgUsed;              /* Used Arguments             */
-   char *ArgLab[ARGMAXCOUNT];  /* Arguments Labels           */
-   char *ArgStr[ARGMAXCOUNT];  /* Arguments 'strings'        */
-   int   ArgCount;             /* Number of arguments passed */
+   char *ArgUsed;              // Used Arguments 
+   char **ArgLab; //[ARGMAXCOUNT];  // Arguments Labels
+   char **ArgStr; //[ARGMAXCOUNT];  // Arguments 'strings'
+   int   ArgCount;             // Number of arguments passed 
    char *Appel;                
+
+   ArgMgr(const ArgMgr&); // Not implemented
+   void operator=(const ArgMgr&); // Not implemented
 };
 } // end namespace gdcm