Utils Namespace | Extending Qt Creator Manual

Extending Qt Creator Manual | Utils Namespace

Extending Qt Creator Manual 4.6.2

# Utils Namespace

Header: | #include <Utils>

## Namespaces

namespace | FadingIndicator
namespace | Icons
namespace | Internal
namespace | Memory
namespace | Ui

## Classes

class | BasicSmallStringLiteral
class | BasicSmallStringVector
class | ConsoleProcessPrivate
class | ElfProgramHeader
class | ElfSectionHeader
class | EventCode
class | ExecuteOnDestruction
class | Link
class | ObjectPool
class | ScopedSwap
class | SizedArray
class | SmallStringView
class | TreeModel
class | TypedTreeItem
class | View
class | functionTakesArgument
class | functionTraits

## Types

enum | ActivationMode { DoubleClickActivation, SingleClickActivation, PlatformDefaultActivation }
enum | ApplyMode { ImmediateApply, DeferedApply }
enum | DebugSymbolsType { UnknownSymbols, NoSymbols, LinkedSymbols, BuildIdSymbols, PlainSymbols, FastSymbols }
enum | ElfClass { Elf_ELFCLASS32, Elf_ELFCLASS64 }
enum | ElfEndian { Elf_ELFDATANONE, Elf_ELFDATA2LSB, Elf_ELFDATA2MSB, Elf_ELFDATANUM }
enum | ElfMachine { Elf_EM_386, Elf_EM_ARM, Elf_EM_X86_64 }
enum | ElfProgramHeaderType { Elf_PT_NULL, Elf_PT_LOAD, Elf_PT_DYNAMIC, Elf_PT_INTERP, ..., Elf_PT_NUM }
enum | ElfSectionHeaderType { Elf_SHT_NULL, Elf_SHT_PROGBITS, Elf_SHT_SYMTAB, Elf_SHT_STRTAB, ..., Elf_SHT_SYMTAB_SHNDX }
enum | ElfType { Elf_ET_NONE, Elf_ET_REL, Elf_ET_EXEC, Elf_ET_DYN, Elf_ET_CORE }
enum | FileDeletedPromptAnswer { FileDeletedClose, FileDeletedCloseAll, FileDeletedSaveAs, FileDeletedSave }
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
typedef | FileNameList
enum | HighlightingItemRole { LineNumber, StartColumn, Length, Foreground, Background, User }
typedef | MacroExpanderProvider
typedef | MacroExpanderProviders
enum | MapReduceOption { Ordered, Unordered }
enum | MimeMatchMode { MatchDefault, MatchExtension, MatchContent }
enum | MimeStartupPhase { BeforeInitialize, PluginsLoading, PluginsInitializing, PluginsDelayedInitializing, UpAndRunning }
enum | OsType { OsTypeWindows, OsTypeLinux, OsTypeMac, OsTypeOtherUnix, OsTypeOther }
enum | OutputFormat { NormalMessageFormat, ErrorMessageFormat, LogMessageFormat, DebugFormat, ..., NumberOfFormats }
typedef | PathString
typedef | PathString
typedef | PathString
typedef | PathString
typedef | PathStringVector
typedef | PathStringVector
enum | ProgressIndicatorSize { Small, Medium, Large }
enum | ReloadPromptAnswer { ReloadCurrent, ReloadAll, ReloadSkipCurrent, ReloadNone, ReloadNoneAndDiff, CloseCurrent }
typedef | ScopedBoolSwap
typedef | SmallString
typedef | SmallString
typedef | SmallStringLiteral
typedef | SmallStringLiteral
typedef | SmallStringVector
typedef | SmallStringVector
typedef | StringViewVector
typedef | StringViewVector
enum | WinDLLVersionType { WinDLLFileVersion, WinDLLProductVersion }

## Functions

Utils::Q_DECL_IMPORT | addMimeTypes(const int &id, const int &data)
Utils::Q_DECL_IMPORT | addMimeTypes(const QString &id, const int &data)
Utils::Q_DECL_IMPORT | addMimeTypes(const QString &id, const QByteArray &data)
bool | allOf(const T &container, F predicate)
bool | anyOf(const T &container, F predicate)
bool | anyOf(const T &container, R (S::*)() const predicate)
bool | anyOf(const T &container, R S::*member)
int & | asConst(T &)
void | asConst(const T &&)
T * | checkEventType(int *ev)
int | compare(Utils::SmallStringView first, Utils::SmallStringView second)
bool | contains(const T &container, F function)
bool | contains(const C<T, Args...> &container, typename T::element_type *other)
bool | contains(const T &container, R (S::*)() const function)
bool | contains(const C<T, Args...> &container, R (S::*)() const function)
int | count(const T &container, F predicate)
decltype(auto) | equal(R (S::*)() const function, T value)
decltype(auto) | equal(R S::*member, T value)
auto | equalTo(Type &&value)
void | erase(T &container, F predicate)
int * | findOr(const int, int)
void | fromSettings(const int &postFix, const int &category, const int *s, SettingsClassT *obj)
auto | greaterEqualThan(Type &&value)
auto | greaterThan(Type &&value)
Utils::Q_DECL_IMPORT | is64BitWindowsBinary(const int &binary)
Utils::Q_DECL_IMPORT | is64BitWindowsSystem()
auto | lessEqualThan(Type &&value)
auto | lessThan(Type &&value)
int | map(ForwardIterator, ForwardIterator, MapFunction &&, Utils::MapReduceOption, int *, int, int)
int | map(Container &&, MapFunction &&, Utils::MapReduceOption, int *, int)
int | mapReduce(ForwardIterator, ForwardIterator, InitFunction &&, MapFunction &&, ReduceFunction &&, CleanUpFunction &&, Utils::MapReduceOption, int *, int, int)
int | mapReduce(Container &&, InitFunction &&, MapFunction &&, ReduceFunction &&, CleanUpFunction &&, Utils::MapReduceOption, int *, int)
int | mapReduce(ForwardIterator, ForwardIterator, MapFunction &&, State &&, ReduceFunction &&, Utils::MapReduceOption, int *, int, int)
int | mapReduce(Container &&, MapFunction &&, State &&, ReduceFunction &&, Utils::MapReduceOption, int *, int)
int | mapped(int, int, int &&, Utils::MapReduceOption, int *, int, int)
int | mapped(int &&, int &&, Utils::MapReduceOption, int *, int)
int | mappedReduced(int, int, int &&, int &&, int &&, Utils::MapReduceOption, int *, int, int)
int | mappedReduced(int &&, int &&, int &&, int &&, Utils::MapReduceOption, int *, int)
Utils::Q_DECL_IMPORT | parseUsedPortFromNetstatOutput(const int &line)
Utils::Q_DECL_IMPORT | parseUsedPortFromNetstatOutput(const QByteArray &line)
Utils::Q_DECL_IMPORT | readMultiLineString(const int &value, int *out)
Utils::Q_DECL_IMPORT | readMultiLineString(const int &value, class QString *out)
int | reverseCompare(Utils::SmallStringView first, Utils::SmallStringView second)
int | runAsync(int *, int, Function &&, Args &&...)
int | runAsync(int, Function &&, Args &&...)
int | runAsync(QThreadPool *, int, Function &&, Args &&...)
Utils::Q_DECL_IMPORT | setCreatorTheme(Utils::Theme *theme)
Utils::Q_DECL_IMPORT | setGlobPatternsForMimeType(const Utils::MimeType &mimeType, const class QStringList &patterns)
Utils::Q_DECL_IMPORT | setMagicRulesForMimeType(const Utils::MimeType &mimeType, const int)
Utils::Q_DECL_IMPORT | setMagicRulesForMimeType(const Utils::MimeType &mimeType, const int &rules)
Utils::Q_DECL_IMPORT | setMimeStartupPhase(Utils::MimeStartupPhase)
Utils::Q_DECL_IMPORT | setThemeApplicationPalette()
void | toSettings(const int &postFix, const int &category, int *s, const SettingsClassT *obj)
Utils::Q_DECL_IMPORT | unCommentSelection(int *edit, const int &definiton = ...)
auto | unequalTo(Type &&value)
T | withNTFSPermissions(const int &task)
Utils::Q_DECL_IMPORT | writeAssertLocation(const char *msg)
bool | operator!=(const int &p1, const int &p2)
bool | operator!=(Utils::SmallStringView first, Utils::SmallStringView second)
bool | operator!=(const Utils::Port &p1, const Utils::Port &p2)
bool | operator!=(const Utils::ProcessHandle &p1, const Utils::ProcessHandle &p2)
Utils::SmallString | operator+(Utils::SmallStringView first, Utils::SmallStringView second)
Utils::SmallString | operator+(Utils::SmallStringView first, const char (&)[Size] second = Size)
Utils::SmallString | operator+(const char (&)[Size] first = Size, Utils::SmallStringView second)
bool | operator<(const int &p1, const int &p2)
bool | operator<(Utils::SmallStringView first, Utils::SmallStringView second)
bool | operator<(const Utils::Port &p1, const Utils::Port &p2)
int & | operator<<(int &, const BasicSmallString<Size> &)
int & | operator<<(int &, const String &)
std::ostream & | operator<<(std::ostream &out, const BasicSmallString<Size> &string = Size)
std::ostream & | operator<<(std::ostream &out, Utils::SmallStringView string)
int & | operator<<(int &, const BasicSmallStringVector<String> &)
int | operator<<(int, const BasicSmallStringVector<String> &)
std::ostream & | operator<<(std::ostream &out, const BasicSmallStringVector<String> &textVector)
std::ostream & | operator<<(std::ostream &out, SizedArray<T, MaxSize> array)
QDebug & | operator<<(QDebug &debug, const String &string)
QDebug | operator<<(QDebug debug, const BasicSmallStringVector<String> &stringVector)
bool | operator<=(const int &p1, const int &p2)
bool | operator<=(const Utils::Port &p1, const Utils::Port &p2)
bool | operator==(const int &p1, const int &p2)
bool | operator==(Utils::SmallStringView first, Utils::SmallStringView second)
bool | operator==(const Utils::Port &p1, const Utils::Port &p2)
bool | operator==(const Utils::ProcessHandle &p1, const Utils::ProcessHandle &p2)
bool | operator>(const int &p1, const int &p2)
bool | operator>(Utils::SmallStringView first, Utils::SmallStringView second)
bool | operator>(const Utils::Port &p1, const Utils::Port &p2)
bool | operator>=(const int &p1, const int &p2)
bool | operator>=(const Utils::Port &p1, const Utils::Port &p2)
int & | operator>>(int &, BasicSmallString<Size> &)
int & | operator>>(int &, BasicSmallStringVector<String> &)

## Detailed Description

The Utils namespace contains a collection of utility classes and functions for use by all plugins.

## Namespaces

### namespace Utils::FadingIndicator

### namespace Utils::Icons

### namespace Utils::Internal

### namespace Utils::Memory

### namespace Utils::Ui

## Classes

### class BasicSmallStringLiteral

### class BasicSmallStringVector

### class ConsoleProcessPrivate

### class ElfProgramHeader

### class ElfSectionHeader

### class EventCode

### class ExecuteOnDestruction

### class Link

### class ObjectPool

### class ScopedSwap

### class SizedArray

### class SmallStringView

### class TreeModel

The TreeModel class is a convienience base class for models to use in a QTreeView. More...

### class TypedTreeItem

### class View

### class functionTakesArgument

### class functionTraits

## Type Documentation

### enum Utils::ActivationMode

### enum Utils::ApplyMode

### enum Utils::DebugSymbolsType

### enum Utils::ElfClass

### enum Utils::ElfEndian

### enum Utils::ElfMachine

### enum Utils::ElfProgramHeaderType

### enum Utils::ElfSectionHeaderType

### enum Utils::ElfType

### enum Utils::FileDeletedPromptAnswer

### typedef Utils::FileNameList

### enum Utils::HighlightingItemRole

### typedef Utils::MacroExpanderProvider

### typedef Utils::MacroExpanderProviders

### enum Utils::MapReduceOption

### enum Utils::MimeMatchMode

### enum Utils::MimeStartupPhase

### enum Utils::OsType

### enum Utils::OutputFormat

### typedef Utils::PathString

### typedef Utils::PathStringVector

### enum Utils::ProgressIndicatorSize

Size of a progress indicator.

Constant | Value | Description
--- | --- | ---
`Utils::Small` | `0` | Small icon size. Useful for tool bars, status bars, rows in tree views, and so on.
`Utils::Medium` | `1` | Larger progress indicator useful for covering whole medium sized widgets.
`Utils::Large` | `2` | Very large progress indicator that can be used to cover large parts of a UI.

See also Utils::ProgressIndicator and Utils::ProgressIndicatorPainter.

### enum Utils::ReloadPromptAnswer

### typedef Utils::ScopedBoolSwap

### typedef Utils::SmallString

### typedef Utils::SmallStringLiteral

### typedef Utils::SmallStringVector

### typedef Utils::StringViewVector

### enum Utils::WinDLLVersionType

## Function Documentation

### Utils::Q_DECL_IMPORT Utils::addMimeTypes(const int &id, const int &data)

### Utils::Q_DECL_IMPORT Utils::addMimeTypes(const QString &id, const int &data)

### Utils::Q_DECL_IMPORT Utils::addMimeTypes(const QString &id, const QByteArray &data)

### bool Utils::allOf(const T &container, F predicate)

### bool Utils::anyOf(const T &container, F predicate)

### bool Utils::anyOf(const T &container, R (S::*)() const predicate)

### bool Utils::anyOf(const T &container, R S::*member)

### int &Utils::asConst(T &)

### void Utils::asConst(const T &&)

### T *Utils::checkEventType(int *ev)

### int Utils::compare(Utils::SmallStringView first, Utils::SmallStringView second)

### bool Utils::contains(const T &container, F function)

### bool Utils::contains(const C<T, Args...> &container, typename T::element_type *other)

### bool Utils::contains(const T &container, R (S::*)() const function)

### bool Utils::contains(const C<T, Args...> &container, R (S::*)() const function)

### int Utils::count(const T &container, F predicate)

### decltype(auto) Utils::equal(R (S::*)() const function, T value)

### decltype(auto) Utils::equal(R S::*member, T value)

### auto Utils::equalTo(Type &&value)

### void Utils::erase(T &container, F predicate)

### int *Utils::findOr(const int, int)

### void Utils::fromSettings(const int &postFix, const int &category, const int *s, SettingsClassT *obj)

### auto Utils::greaterEqualThan(Type &&value)

### auto Utils::greaterThan(Type &&value)

### Utils::Q_DECL_IMPORT Utils::is64BitWindowsBinary(const int &binary)

### Utils::Q_DECL_IMPORT Utils::is64BitWindowsSystem()

### auto Utils::lessEqualThan(Type &&value)

### auto Utils::lessThan(Type &&value)

### int Utils::map(ForwardIterator, ForwardIterator, MapFunction &&, Utils::MapReduceOption, int *, int, int)

### int Utils::map(Container &&, MapFunction &&, Utils::MapReduceOption, int *, int)

### int Utils::mapReduce(ForwardIterator, ForwardIterator, InitFunction &&, MapFunction &&, ReduceFunction &&, CleanUpFunction &&, Utils::MapReduceOption, int *, int, int)

### int Utils::mapReduce(Container &&, InitFunction &&, MapFunction &&, ReduceFunction &&, CleanUpFunction &&, Utils::MapReduceOption, int *, int)

### int Utils::mapReduce(ForwardIterator, ForwardIterator, MapFunction &&, State &&, ReduceFunction &&, Utils::MapReduceOption, int *, int, int)

### int Utils::mapReduce(Container &&, MapFunction &&, State &&, ReduceFunction &&, Utils::MapReduceOption, int *, int)

### int Utils::mapped(int, int, int &&, Utils::MapReduceOption, int *, int, int)

### int Utils::mapped(int &&, int &&, Utils::MapReduceOption, int *, int)

### int Utils::mappedReduced(int, int, int &&, int &&, int &&, Utils::MapReduceOption, int *, int, int)

### int Utils::mappedReduced(int &&, int &&, int &&, int &&, Utils::MapReduceOption, int *, int)

### Utils::Q_DECL_IMPORT Utils::parseUsedPortFromNetstatOutput(const int &line)

### Utils::Q_DECL_IMPORT Utils::parseUsedPortFromNetstatOutput(const QByteArray &line)

### Utils::Q_DECL_IMPORT Utils::readMultiLineString(const int &value, int *out)

### Utils::Q_DECL_IMPORT Utils::readMultiLineString(const int &value, class QString *out)

### int Utils::reverseCompare(Utils::SmallStringView first, Utils::SmallStringView second)

### int Utils::runAsync(int *, int, Function &&, Args &&...)

### int Utils::runAsync(int, Function &&, Args &&...)

### int Utils::runAsync(QThreadPool *, int, Function &&, Args &&...)

### Utils::Q_DECL_IMPORT Utils::setCreatorTheme(Utils::Theme *theme)

### Utils::Q_DECL_IMPORT Utils::setGlobPatternsForMimeType(const Utils::MimeType &mimeType, const class QStringList &patterns)

### Utils::Q_DECL_IMPORT Utils::setMagicRulesForMimeType(const Utils::MimeType &mimeType, const int)

### Utils::Q_DECL_IMPORT Utils::setMagicRulesForMimeType(const Utils::MimeType &mimeType, const int &rules)

### Utils::Q_DECL_IMPORT Utils::setMimeStartupPhase(Utils::MimeStartupPhase)

### Utils::Q_DECL_IMPORT Utils::setThemeApplicationPalette()

### void Utils::toSettings(const int &postFix, const int &category, int *s, const SettingsClassT *obj)

### Utils::Q_DECL_IMPORT Utils::unCommentSelection(int *edit, const int &definiton = ...)

### auto Utils::unequalTo(Type &&value)

### T Utils::withNTFSPermissions(const int &task)

### Utils::Q_DECL_IMPORT Utils::writeAssertLocation(const char *msg)

### bool Utils::operator!=(const int &p1, const int &p2)

### bool Utils::operator!=(Utils::SmallStringView first, Utils::SmallStringView second)

### bool Utils::operator!=(const Utils::Port &p1, const Utils::Port &p2)

### bool Utils::operator!=(const Utils::ProcessHandle &p1, const Utils::ProcessHandle &p2)

### Utils::SmallString Utils::operator+(Utils::SmallStringView first, Utils::SmallStringView second)

### Utils::SmallString Utils::operator+(Utils::SmallStringView first, const char (&)[Size] second = Size)

### Utils::SmallString Utils::operator+(const char (&)[Size] first = Size, Utils::SmallStringView second)

### bool Utils::operator<(const int &p1, const int &p2)

### bool Utils::operator<(Utils::SmallStringView first, Utils::SmallStringView second)

### bool Utils::operator<(const Utils::Port &p1, const Utils::Port &p2)

### int &Utils::operator<<(int &, const BasicSmallString<Size> &)

### int &Utils::operator<<(int &, const String &)

### std::ostream &Utils::operator<<(std::ostream &out, const BasicSmallString<Size> &string = Size)

### std::ostream &Utils::operator<<(std::ostream &out, Utils::SmallStringView string)

### int &Utils::operator<<(int &, const BasicSmallStringVector<String> &)

### int Utils::operator<<(int, const BasicSmallStringVector<String> &)

### std::ostream &Utils::operator<<(std::ostream &out, const BasicSmallStringVector<String> &textVector)

### std::ostream &Utils::operator<<(std::ostream &out, SizedArray<T, MaxSize> array)

### QDebug &Utils::operator<<(QDebug &debug, const String &string)

### QDebug Utils::operator<<(QDebug debug, const BasicSmallStringVector<String> &stringVector)

### bool Utils::operator<=(const int &p1, const int &p2)

### bool Utils::operator<=(const Utils::Port &p1, const Utils::Port &p2)

### bool Utils::operator==(const int &p1, const int &p2)

### bool Utils::operator==(Utils::SmallStringView first, Utils::SmallStringView second)

### bool Utils::operator==(const Utils::Port &p1, const Utils::Port &p2)

### bool Utils::operator==(const Utils::ProcessHandle &p1, const Utils::ProcessHandle &p2)

### bool Utils::operator>(const int &p1, const int &p2)

### bool Utils::operator>(Utils::SmallStringView first, Utils::SmallStringView second)

### bool Utils::operator>(const Utils::Port &p1, const Utils::Port &p2)

### bool Utils::operator>=(const int &p1, const int &p2)

### bool Utils::operator>=(const Utils::Port &p1, const Utils::Port &p2)

### int &Utils::operator>>(int &, BasicSmallString<Size> &)

### int &Utils::operator>>(int &, BasicSmallStringVector<String> &)