1
2
3
4
5
6
7 from Ganga.Utility.util import importName
8
10 for _t in valTypeList:
11 _dotMod = _t.split('.')
12 if len(_dotMod) > 1:
13 if not hasattr( val, '_proxyClass' ):
14
15 continue
16 _type = importName( '.'.join(_dotMod[0:-1]), _dotMod[-1] )
17 _val = val
18 else:
19 try:
20 _type = eval( _t )
21 except NameError:
22 logger.error( "Invalid native Python type: '%s'" % _t )
23 continue
24 _val = val
25
26 if _type is None:
27 if _val is None:
28 return True
29 else:
30 continue
31 elif isinstance( _val, _type ):
32 return True
33 return False
34