Search for usage in LXR

KDbLookupFieldSchemaRecordSource Class Reference

#include <KDbLookupFieldSchema.h>

Public Types

enum  Type {
  Type::None, Type::Table, Type::Query, Type::SQLStatement,
  Type::ValueList, Type::KDbFieldList

Public Member Functions

 KDbLookupFieldSchemaRecordSource (const KDbLookupFieldSchemaRecordSource &other)
QString name () const
bool operator!= (const KDbLookupFieldSchemaRecordSource &other) const
KDbLookupFieldSchemaRecordSourceoperator= (const KDbLookupFieldSchemaRecordSource &other)
bool operator== (const KDbLookupFieldSchemaRecordSource &other) const
void setName (const QString &name)
void setType (Type type)
void setTypeByName (const QString &typeName)
void setValues (const QStringList &values)
Type type () const
QString typeName () const
QStringList values () const

Detailed Description

Record source information that can be specified for the lookup field schema.


Definition at line 49 of file KDbLookupFieldSchema.h.

Member Enumeration Documentation

◆ Type

Record source type.


used for invalid schema


table as lookup record source


named query as lookup record source


anonymous query as lookup record source


a fixed list of values as lookup record source


a list of column names from a table/query will be displayed

Definition at line 53 of file KDbLookupFieldSchema.h.

Member Function Documentation

◆ name()

QString KDbLookupFieldSchemaRecordSource::name ( ) const
a string for record source: table name, query name or anonymous query provided as KDbSQL string. If recordSourceType() is a ValueList, recordSourceValues() should be used instead. If recordSourceType() is a KDbFieldList, recordSource() should return table or query name.

Definition at line 144 of file KDbLookupFieldSchema.cpp.

◆ operator!=()

bool KDbLookupFieldSchemaRecordSource::operator!= ( const KDbLookupFieldSchemaRecordSource other) const
true if this record source is not equal to other; otherwise returns false.

Definition at line 109 of file KDbLookupFieldSchema.h.

◆ operator=()

KDbLookupFieldSchemaRecordSource & KDbLookupFieldSchemaRecordSource::operator= ( const KDbLookupFieldSchemaRecordSource other)

Assigns other to this record source and returns a reference to this record source.

Definition at line 177 of file KDbLookupFieldSchema.cpp.

◆ operator==()

bool KDbLookupFieldSchemaRecordSource::operator== ( const KDbLookupFieldSchemaRecordSource other) const
true if this record source is equal to other; otherwise returns false.

Definition at line 185 of file KDbLookupFieldSchema.cpp.

◆ setName()

void KDbLookupFieldSchemaRecordSource::setName ( const QString name)

Sets record source value.

See also

Definition at line 149 of file KDbLookupFieldSchema.cpp.

◆ setType()

void KDbLookupFieldSchemaRecordSource::setType ( Type  type)

Sets record source type to type.

Definition at line 139 of file KDbLookupFieldSchema.cpp.

◆ setTypeByName()

void KDbLookupFieldSchemaRecordSource::setTypeByName ( const QString typeName)

Sets record source type by name using typeName. Accepted (case sensitive) names are "table", "query", "sql", "valuelist", "fieldlist". For other value NoType type is set.

Definition at line 161 of file KDbLookupFieldSchema.cpp.

◆ setValues()

void KDbLookupFieldSchemaRecordSource::setValues ( const QStringList values)

Sets record source values used if type() is ValueList. Using it clears name (see name()).

Definition at line 171 of file KDbLookupFieldSchema.cpp.

◆ type()

KDbLookupFieldSchemaRecordSource::Type KDbLookupFieldSchemaRecordSource::type ( ) const
record source type: table, query, anonymous; in the future it will be also fixed value list and field list. The latter is basically a list of column names of a table/query, "Field List" in MSA.

Definition at line 134 of file KDbLookupFieldSchema.cpp.

◆ typeName()

QString KDbLookupFieldSchemaRecordSource::typeName ( ) const
record source type name.
See also

Definition at line 155 of file KDbLookupFieldSchema.cpp.

◆ values()

QStringList KDbLookupFieldSchemaRecordSource::values ( ) const
record source values specified if type() is ValueList.

Definition at line 166 of file KDbLookupFieldSchema.cpp.

The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Sat Sep 30 2023 04:09:10 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.