VTK  9.3.1
Classes | Macros | Enumerations | Functions
vtkResourceParser.h File Reference
#include "vtkIOCoreModule.h"
#include "vtkObject.h"
#include "vtkResourceStream.h"
#include "vtkSmartPointer.h"
#include <array>
#include <cstdint>
#include <cstdlib>
#include <functional>
#include <limits>
#include <memory>
#include <string>
#include <type_traits>
Include dependency graph for vtkResourceParser.h:

Go to the source code of this file.

Classes

class  vtkResourceParser
 Helper class to perform formatted input from vtkResourceStream. More...
 
struct  vtkResourceParser::ReadToResult< It >
 Structure returned by Read*To functions. More...
 

Macros

#define DECLARE_PARSE_EXTERN_TEMPLATE(type)
 

Enumerations

enum  vtkParseResult : std::int32_t {
  vtkParseResult::Error = -1, vtkParseResult::Ok = 0, vtkParseResult::EndOfStream = 1, vtkParseResult::EndOfLine = 2,
  vtkParseResult::Limit = 3
}
 Result of a vtkResouceParser parsing operation. More...
 

Functions

 DECLARE_PARSE_EXTERN_TEMPLATE (char)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (signed char)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (unsigned char)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (short)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (int)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (long)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (unsigned long long)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (float)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (double)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (bool)
 
 DECLARE_PARSE_EXTERN_TEMPLATE (std::string)
 

Macro Definition Documentation

#define DECLARE_PARSE_EXTERN_TEMPLATE (   type)
Value:
extern template VTKIOCORE_EXPORT vtkParseResult \
vtkResourceParser::vtkParserContext::Parse<type>(type&, const PredicateType& discardPred)

Definition at line 535 of file vtkResourceParser.h.

Enumeration Type Documentation

enum vtkParseResult : std::int32_t
strong

Result of a vtkResouceParser parsing operation.

This enumeration gives information about what the parsing operation did. When doing basic parsing, you may just need to check result != vtkParseResult::Ok.

For more complex parsing, you can configure the parser to stop on newlines

Enumerator
Error 
Ok 
EndOfStream 
EndOfLine 
Limit 

Definition at line 32 of file vtkResourceParser.h.

Function Documentation

DECLARE_PARSE_EXTERN_TEMPLATE ( char  )
DECLARE_PARSE_EXTERN_TEMPLATE ( signed  char)
DECLARE_PARSE_EXTERN_TEMPLATE ( unsigned  char)
DECLARE_PARSE_EXTERN_TEMPLATE ( short  )
DECLARE_PARSE_EXTERN_TEMPLATE ( int  )
DECLARE_PARSE_EXTERN_TEMPLATE ( long  )
DECLARE_PARSE_EXTERN_TEMPLATE ( unsigned long  long)
DECLARE_PARSE_EXTERN_TEMPLATE ( float  )
DECLARE_PARSE_EXTERN_TEMPLATE ( double  )
DECLARE_PARSE_EXTERN_TEMPLATE ( bool  )
DECLARE_PARSE_EXTERN_TEMPLATE ( std::string  )