]> Creatis software - gdcm.git/blob - Example/TestValidate.cxx
Fix mistypings
[gdcm.git] / Example / TestValidate.cxx
1 /*=========================================================================
2                                                                                 
3   Program:   gdcm
4   Module:    $RCSfile: TestValidate.cxx,v $
5   Language:  C++
6   Date:      $Date: 2007/05/23 14:18:04 $
7   Version:   $Revision: 1.4 $
8                                                                                 
9   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
10   l'Image). All rights reserved. See Doc/License.txt or
11   http://www.creatis.insa-lyon.fr/Public/Gdcm/License.html for details.
12                                                                                 
13      This software is distributed WITHOUT ANY WARRANTY; without even
14      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15      PURPOSE.  See the above copyright notices for more information.
16                                                                                 
17 =========================================================================*/
18 #include "gdcmFile.h"
19 #include "gdcmValidator.h"
20
21
22 int main(int argc, char *argv[])
23 {
24   if( argc < 2 )
25   {
26     std::cerr << "ouh les cornes / shame on you / !inocente!" << std::endl;
27     return 1;
28   }
29
30    const char *filename = argv[1];
31
32    GDCM_NAME_SPACE::File *input =  GDCM_NAME_SPACE::File::New( );
33    input->SetFileName(filename);
34    input->Load();
35    GDCM_NAME_SPACE::Validator *v = GDCM_NAME_SPACE::Validator::New();
36    v->SetInput( input );
37
38    return 0;
39 }
40