TinyURDF 1.0.0
A Modern C++ Library for Parsing and Visualizing URDF Model Files
Loading...
Searching...
No Matches
urdf_parser.h
Go to the documentation of this file.
1#ifndef INCLUDE_TINYURDF_URDF_PARSER_H_
2#define INCLUDE_TINYURDF_URDF_PARSER_H_
3
4// Copyright 2025 Wissem CHIHA
5
6#include <string>
7#include <memory>
8#include <iostream>
9
10#include <tinyxml2/tinyxml2.h>
11
12#include "model.h"
13#include "version.h"
14#include "version_parser.h"
15#include "parser_base.h"
16#include "model_parser.h"
17
23class URDFParser : public ParserBase<Model>{
24public:
25 URDFParser();
26 void parse(const std::string& filename);
27 void parse(const char* filename);
28 void parse(const tinyxml2::XMLElement* xml) override;
29 std::shared_ptr<Model> get() override;
30 void print(std::ostream& os) override;
31 bool isA(const char* name) override;
32 bool empty() const override;
33 void clear() override;
34 const char* getTypename() override;
36private:
37 std::shared_ptr<Model> model_;
38};
39#endif // TINYURDF_URDF_PARSER_H_
Definition parser_base.h:16
main user high level interface for parsing URDF files
Definition urdf_parser.h:23
void print(std::ostream &os) override
Definition urdf_parser.cc:72
void parse(const std::string &filename)
Definition urdf_parser.cc:8
void clear() override
Definition urdf_parser.cc:87
const char * getTypename() override
Definition urdf_parser.cc:92
URDFParser()
Definition urdf_parser.cc:3
bool empty() const override
Definition urdf_parser.cc:82
bool isA(const char *name) override
Definition urdf_parser.cc:77
~URDFParser()
Definition urdf_parser.cc:97
std::shared_ptr< Model > get() override
Definition urdf_parser.cc:67