1 /*  This file is part of MED.
2  *
3  *  COPYRIGHT (C) 1999 - 2019  EDF R&D, CEA/DEN
4  *  MED is free software: you can redistribute it and/or modify
5  *  it under the terms of the GNU Lesser General Public License as published by
6  *  the Free Software Foundation, either version 3 of the License, or
7  *  (at your option) any later version.
8  *
9  *  MED is distributed in the hope that it will be useful,
10  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  *  GNU Lesser General Public License for more details.
13  *
14  *  You should have received a copy of the GNU Lesser General Public License
15  *  along with MED.  If not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 
19 #include "med_config.h"
20 #include <med.h>
21 #include "med_outils.h"
22 #include <string.h>
23 
24 
25 /**\ingroup MEDfamily
26   \brief \MEDfamilyInfoBrief
27   \param fid \fid
28   \param meshname \meshname
29   \param famit \famit
30   \param familyname \familyname
31   \param familynumber \familynumber
32   \param groupname \groupname
33   \retval med_err  \error
34   \details \MEDfamilyInfoDetails
35  */
36 
37 
38 med_err
MEDfamilyInfo(const med_idt fid,const char * const meshname,const int famit,char * const familyname,med_int * const familynumber,char * const groupname)39 MEDfamilyInfo(const med_idt        fid,
40 	      const char *   const meshname,
41 	      const int            famit,
42 	      char * const         familyname,
43 	      med_int *const       familynumber,
44 	      char *const          groupname)
45 {
46   char *  name = "_MEDfamilyInfo";
47   int     dummy=0;
48   med_err fret=-1;
49   med_int majeur, mineur, release;
50   MedFuncType func;
51 
52   MEDfileNumVersionRd(fid, &majeur, &mineur, &release);
53   func = _MEDversionedApi3(name,majeur,mineur,release);
54   if ( func != (MedFuncType) NULL )
55     func (dummy,
56 	  fid,
57 	  meshname,
58 	  famit,
59 	  familyname,
60 	  familynumber,
61 	  groupname,
62 	  &fret);
63 
64   return fret;
65 }
66