XdmfReader.cpp 2.42 KB
Newer Older
Kenneth Leiter's avatar
Kenneth Leiter committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
/*****************************************************************************/
/*                                    XDMF                                   */
/*                       eXtensible Data Model and Format                    */
/*                                                                           */
/*  Id : XdmfReader.cpp                                                      */
/*                                                                           */
/*  Author:                                                                  */
/*     Kenneth Leiter                                                        */
/*     kenneth.leiter@arl.army.mil                                           */
/*     US Army Research Laboratory                                           */
/*     Aberdeen Proving Ground, MD                                           */
/*                                                                           */
/*     Copyright @ 2011 US Army Research Laboratory                          */
/*     All Rights Reserved                                                   */
/*     See Copyright.txt for details                                         */
/*                                                                           */
/*     This software is distributed WITHOUT ANY WARRANTY; without            */
/*     even the implied warranty of MERCHANTABILITY or FITNESS               */
/*     FOR A PARTICULAR PURPOSE.  See the above copyright notice             */
/*     for more information.                                                 */
/*                                                                           */
/*****************************************************************************/
23

24
#include "XdmfItemFactory.hpp"
25
#include "XdmfReader.hpp"
26
#include "XdmfError.hpp"
27

28
shared_ptr<XdmfReader>
29
XdmfReader::New()
30
{
31
  shared_ptr<XdmfReader> p(new XdmfReader());
32
  return p;
33 34
}

35
XdmfReader::XdmfReader() :
36
  XdmfCoreReader(XdmfItemFactory::New())
37 38 39 40 41 42
{
}

XdmfReader::~XdmfReader()
{
}
43

44 45
// Implemented to make SWIG wrapping work correctly
// (typemaps to return specific subclass instances of XdmfItems)
46
shared_ptr<XdmfItem>
47
XdmfReader::read(const std::string & filePath) const
48
{
49
  return XdmfCoreReader::read(filePath);
50
}
51

52
std::vector<shared_ptr<XdmfItem> >
53 54
XdmfReader::read(const std::string & filePath,
                 const std::string & xPath) const
55
{
56
  return XdmfCoreReader::read(filePath, xPath);
57
}