}
std::string __str__() const throw(INTERP_KERNEL::Exception)
- {
- return self->simpleRepr();
- }
+ {
+ return self->simpleRepr();
+ }
+
+ int __len__() const throw(INTERP_KERNEL::Exception)
+ {
+ return self->getNumberOfTS();
+ }
MEDFileField1TS *__getitem__(PyObject *elt0) const throw(INTERP_KERNEL::Exception)
{
mm.write("Pyfile17_bis.med",2)
ff=MEDFileFieldMultiTS("Pyfile17.med")
tsExpected=[[1,2],[3,4],[5,6]]
+ self.assertEqual(3,len(ff))
for pos,f1ts in enumerate(ff):
self.assertEqual(tsExpected[pos],f1ts.getTime()[:2])
self.assertEqual(type(f1ts),MEDFileField1TS)