RMF
names.h
Go to the documentation of this file.
1/**
2 * \file RMF/names.h
3 * \brief Functions to check if names are valid.
4 *
5 * Copyright 2007-2022 IMP Inventors. All rights reserved.
6 *
7 */
8
9#ifndef RMF_NAMES_H
10#define RMF_NAMES_H
11
12#include <sstream>
13#include <string>
14
15#include "RMF/config.h"
16#include "types.h"
17
18RMF_ENABLE_WARNINGS
19namespace RMF {
20
21/** \name Names
22 @{ */
23/** Node and key names have to obey certain rules, such as no quotes
24 in the name. */
25
26//! Return a node name string that has been modified to obey the rules.
27RMFEXPORT std::string get_as_node_name(std::string input);
28
29//! Return true iff the string is a valid key name.
30RMFEXPORT bool get_is_valid_key_name(std::string name);
31
32//! Return true iff the string is a valid node name.
33RMFEXPORT bool get_is_valid_node_name(std::string name);
34
35/** @} */
36} /* namespace RMF */
37
38RMF_DISABLE_WARNINGS
39
40#endif /* RMF_NAMES_H */
The namespace for all functionality in the library.
std::string get_as_node_name(std::string input)
Return a node name string that has been modified to obey the rules.
bool get_is_valid_key_name(std::string name)
Return true iff the string is a valid key name.
bool get_is_valid_node_name(std::string name)
Return true iff the string is a valid node name.
Default implementation for types.h.