BornAgain  1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
dataloader_utils.h File Reference

Defines class CLASS? More...

Include dependency graph for dataloader_utils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 gui2
 Based on Qt example "codeeditor" Copyright (C) 2016 The Qt Company Ltd.
 
 gui2::Utils
 Collection of utility functions for running quick simulations.
 

Functions

DAREFLCORE_EXPORT std::string gui2::Utils::AddHtmlBackgroundTag (const std::string &line, const std::string &color)
 Returns string representing original 'line' wrapped in 'div' tag. More...
 
DAREFLCORE_EXPORT std::string gui2::Utils::AddHtmlColorTag (const std::string &line, const std::string &color)
 Returns string representing original 'line' wrapped in html color tag. More...
 
DAREFLCORE_EXPORT std::string gui2::Utils::AddHtmlColorTagToParts (const std::string &line, const std::vector< std::string > &parts, const std::string &color_parts, const std::string &color_rest)
 Returns string representing original 'line', where 'parts' are surrounded with color tag. More...
 
DAREFLCORE_EXPORT std::string gui2::Utils::AddHtmlDivTag (const std::string &line)
 Returns string representing original 'line' wrapped in 'div' tag. More...
 
DAREFLCORE_EXPORT GraphImportData gui2::Utils::CreateData (const std::vector< std::vector< std::string >> &text_data, const ColumnInfo &axis, const ColumnInfo &intensity)
 Creates structure from text data. More...
 
DAREFLCORE_EXPORT std::vector< std::pair< ColumnInfo, ColumnInfo > > gui2::Utils::CreateGraphInfoPairs (const std::vector< ColumnInfo > &column_info)
 Pack ColumnInfo into pairs representing {AxisType, IntensityType}. More...
 
DAREFLCORE_EXPORT accept_int_t gui2::Utils::CreateLineNumberPatternValidator (const std::string &pattern)
 Creates a callback to define if given line number satisfies line number pattern. More...
 
DAREFLCORE_EXPORT accept_string_t gui2::Utils::CreateLinePrefixValidator (const std::string &prefix_to_exclude)
 Creates a callback to define if given line has a valid content for further parsing. More...
 
DAREFLCORE_EXPORT line_splitter_t gui2::Utils::CreateSeparatorBasedSplitter (const std::string &separator)
 Creates line splitter based on separator. More...
 
DAREFLCORE_EXPORT std::vector< std::pair< int, int > > gui2::Utils::ExpandLineNumberPattern (const std::string &pattern)
 Expands string representing line number pattern to inclusive pairs of line numbers. More...
 
DAREFLCORE_EXPORT std::pair< std::vector< double >, std::vector< double > > gui2::Utils::ExtractTwoColumns (const std::vector< std::vector< std::string >> &text_data, size_t col1, size_t col2)
 Extracts double values from two columns of a string array. More...
 
DAREFLCORE_EXPORT std::vector< std::string > gui2::Utils::LoadASCIIFile (const std::string &file_name)
 Loads ASCII file, returns it in the form of vector of strings. More...
 

Detailed Description

Defines class CLASS?

Homepage:\n http://www.bornagainproject.org
License:\n GNU General Public License v3 or higher (see COPYING)
Authors
Scientific Computing Group at MLZ (see CITATION, AUTHORS)

Definition in file dataloader_utils.h.