亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? qsqlrecord.cpp

?? QT 開發環境里面一個很重要的文件
?? CPP
字號:
/******************************************************************************** Copyright (C) 1992-2006 Trolltech ASA. All rights reserved.**** This file is part of the QtSql module of the Qt Toolkit.**** This file may be used under the terms of the GNU General Public** License version 2.0 as published by the Free Software Foundation** and appearing in the file LICENSE.GPL included in the packaging of** this file.  Please review the following information to ensure GNU** General Public Licensing requirements will be met:** http://www.trolltech.com/products/qt/opensource.html**** If you are unsure which license is appropriate for your use, please** review the following information:** http://www.trolltech.com/products/qt/licensing.html or contact the** sales department at sales@trolltech.com.**** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.******************************************************************************/#include "qsqlrecord.h"#include "qdebug.h"#include "qstringlist.h"#include "qatomic.h"#include "qsqlfield.h"#include "qstring.h"#include "qvector.h"class QSqlRecordPrivate{public:    QSqlRecordPrivate();    QSqlRecordPrivate(const QSqlRecordPrivate &other);    inline bool contains(int index) { return index >= 0 && index < fields.count(); }    QString createField(int index, const QString &prefix) const;    QVector<QSqlField> fields;    QAtomic ref;};QSqlRecordPrivate::QSqlRecordPrivate(){    ref = 1;}QSqlRecordPrivate::QSqlRecordPrivate(const QSqlRecordPrivate &other): fields(other.fields){    ref = 1;}/*! \internal    Just for compat*/QString QSqlRecordPrivate::createField(int index, const QString &prefix) const{    QString f;    if (!prefix.isEmpty())        f = prefix + QLatin1Char('.');    f += fields.at(index).name();    return f;}/*!    \class QSqlRecord    \brief The QSqlRecord class encapsulates a database record.    \ingroup database    \ingroup shared    \module sql    The QSqlRecord class encapsulates the functionality and    characteristics of a database record (usually a row in a table or    view within the database). QSqlRecord supports adding and    removing fields as well as setting and retrieving field values.    The values of a record's fields' can be set by name or position    with setValue(); if you want to set a field to null use    setNull(). To find the position of a field by name use indexOf(),    and to find the name of a field at a particular position use    fieldName(). Use field() to retrieve a QSqlField object for a    given field. Use contains() to see if the record contains a    particular field name.    When queries are generated to be executed on the database only    those fields for which isGenerated() is true are included in the    generated SQL.    A record can have fields added with append() or insert(), replaced    with replace(), and removed with remove(). All the fields can be    removed with clear(). The number of fields is given by count();    all their values can be cleared (to null) using clearValues().    \sa QSqlField, QSqlQuery::record()*//*!    Constructs an empty record.    \sa isEmpty(), append(), insert()*/QSqlRecord::QSqlRecord(){    d = new QSqlRecordPrivate();}/*!    Constructs a copy of \a other.    QSqlRecord is \l{implicitly shared}. This means you can make copies    of a record in \l{constant time}.*/QSqlRecord::QSqlRecord(const QSqlRecord& other){    d = other.d;    d->ref.ref();}/*!    Sets the record equal to \a other.    QSqlRecord is \l{implicitly shared}. This means you can make copies    of a record in \l{constant time}.*/QSqlRecord& QSqlRecord::operator=(const QSqlRecord& other){    qAtomicAssign(d, other.d);    return *this;}/*!    Destroys the object and frees any allocated resources.*/QSqlRecord::~QSqlRecord(){    if (!d->ref.deref())        delete d;}/*!    \fn bool QSqlRecord::operator!=(const QSqlRecord &other) const    Returns true if this object is not identical to \a other;    otherwise returns false.    \sa operator==()*//*!    Returns true if this object is identical to \a other (i.e., has    the same fields in the same order); otherwise returns false.    \sa operator!=()*/bool QSqlRecord::operator==(const QSqlRecord &other) const{    return d->fields == other.d->fields;}/*!    Returns the value of the field located at position \a index in    the record. If \a index is out of bounds, an invalid QVariant    is returned.    \sa fieldName() isNull()*/QVariant QSqlRecord::value(int index) const{    return d->fields.value(index).value();}/*!    \overload    Returns the value of the field called \a name in the record. If    field \a name does not exist an invalid variant is returned.    \sa indexOf()*/QVariant QSqlRecord::value(const QString& name) const{    return value(indexOf(name));}/*!    Returns the name of the field at position \a index. If the field    does not exist, an empty string is returned.    \sa indexOf()*/QString QSqlRecord::fieldName(int index) const{    return d->fields.value(index).name();}/*!    Returns the position of the field called \a name within the    record, or -1 if it cannot be found. Field names are not    case-sensitive. If more than one field matches, the first one is    returned.    \sa fieldName()*/int QSqlRecord::indexOf(const QString& name) const{    QString nm = name.toUpper();    for (int i = 0; i < count(); ++i) {        if (d->fields.at(i).name().toUpper() == nm) // TODO: case-insensitive comparison            return i;    }    return -1;}#ifdef QT3_SUPPORT/*!    \obsolete    Use field() instead*/const QSqlField* QSqlRecord::fieldPtr(int index) const{    if (!d->contains(index))        return 0;    return &d->fields.at(index);}/*!    \obsolete    Use field() instead*/const QSqlField* QSqlRecord::fieldPtr(const QString& name) const{    int i = indexOf(name);    if (!d->contains(i))        return 0;    return &d->fields.at(i);}#endif //QT3_SUPPORT/*!    Returns the field at position \a index. If the position is out of    range, an empty field is returned. */QSqlField QSqlRecord::field(int index) const{    return d->fields.value(index);}/*! \overload    Returns the field called \a name. */QSqlField QSqlRecord::field(const QString &name) const{    return field(indexOf(name));}/*!    Append a copy of field \a field to the end of the record.    \sa insert() replace() remove()*/void QSqlRecord::append(const QSqlField& field){    detach();    d->fields.append(field);}/*!    Inserts the field \a field at position \a pos in the record.    \sa append() replace() remove() */void QSqlRecord::insert(int pos, const QSqlField& field){   detach();   d->fields.insert(pos, field);}/*!    Replaces the field at position \a pos with the given \a field. If    \a pos is out of range, nothing happens.    \sa append() insert() remove()*/void QSqlRecord::replace(int pos, const QSqlField& field){    if (!d->contains(pos))        return;    detach();    d->fields[pos] = field;}/*!    Removes the field at position \a pos. If \a pos is out of range,    nothing happens.    \sa append() insert() replace()*/void QSqlRecord::remove(int pos){    if (!d->contains(pos))        return;    detach();    d->fields.remove(pos);}/*!    Removes all the record's fields.    \sa clearValues() isEmpty()*/void QSqlRecord::clear(){    detach();    d->fields.clear();}/*!    Returns true if there are no fields in the record; otherwise    returns false.    \sa append() insert() clear()*/bool QSqlRecord::isEmpty() const{    return d->fields.isEmpty();}/*!    Returns true if there is a field in the record called \a name;    otherwise returns false.*/bool QSqlRecord::contains(const QString& name) const{    return indexOf(name) >= 0;}/*!    Clears the value of all fields in the record and sets each field    to null.    \sa setValue()*/void QSqlRecord::clearValues(){    detach();    int count = d->fields.count();    for (int i = 0; i < count; ++i)        d->fields[i].clear();}/*!    Sets the generated flag for the field called \a name to \a    generated. If the field does not exist, nothing happens. Only    fields that have \a generated set to true are included in the SQL    that is generated by QSqlQueryModel for example.    \sa isGenerated()*/void QSqlRecord::setGenerated(const QString& name, bool generated){    setGenerated(indexOf(name), generated);}/*!    \overload    Sets the generated flag for the field \a index to \a generated.    \sa isGenerated()*/void QSqlRecord::setGenerated(int index, bool generated){    if (!d->contains(index))        return;    detach();    d->fields[index].setGenerated(generated);}/*!    \overload    Returns true if the field \a index is null or if there is no field at    position \a index; otherwise returns false.*/bool QSqlRecord::isNull(int index) const{    return d->fields.value(index).isNull();}/*!    Returns true if the field called \a name is null or if there is no    field called \a name; otherwise returns false.    \sa setNull()*/bool QSqlRecord::isNull(const QString& name) const{    return isNull(indexOf(name));}/*!    Sets the value of field \a index to null. If the field does not exist,    nothing happens.    \sa setValue()*/void QSqlRecord::setNull(int index){    if (!d->contains(index))        return;    detach();    d->fields[index].clear();}/*!    \overload    Sets the value of the field called \a name to null. If the field    does not exist, nothing happens.*/void QSqlRecord::setNull(const QString& name){    setNull(indexOf(name));}/*!    Returns true if the record has a field called \a name and this    field is to be generated (the default); otherwise returns false.    \sa setGenerated()*/bool QSqlRecord::isGenerated(const QString& name) const{    return isGenerated(indexOf(name));}/*! \overload    Returns true if the record has a field at position \a index and this    field is to be generated (the default); otherwise returns false.    \sa setGenerated()*/bool QSqlRecord::isGenerated(int index) const{    return d->fields.value(index).isGenerated();}#ifdef QT3_SUPPORT/*!    Returns a list of all the record's field names as a string    separated by \a sep.    In the unlikely event that you used this function in Qt 3, you    can simulate it using the rest of the QSqlRecord public API.*/QString QSqlRecord::toString(const QString& prefix, const QString& sep) const{    QString pflist;    bool comma = false;    for (int i = 0; i < count(); ++i) {        if (!d->fields.value(i).isGenerated()) {            if (comma)                pflist += sep + QLatin1Char(' ');            pflist += d->createField(i, prefix);            comma = true;        }    }    return pflist;}/*!    Returns a list of all the record's field names, each having the    prefix \a prefix.    In the unlikely event that you used this function in Qt 3, you    can simulate it using the rest of the QSqlRecord public API.*/QStringList QSqlRecord::toStringList(const QString& prefix) const{    QStringList s;    for (int i = 0; i < count(); ++i) {        if (!d->fields.value(i).isGenerated())            s += d->createField(i, prefix);    }    return s;}#endif // QT3_SUPPORT/*!    Returns the number of fields in the record.    \sa isEmpty()*/int QSqlRecord::count() const{    return d->fields.count();}/*!    Sets the value of the field at position \a index to \a val. If the    field does not exist, nothing happens.    \sa setNull()*/void QSqlRecord::setValue(int index, const QVariant& val){    if (!d->contains(index))        return;    detach();    d->fields[index].setValue(val);}/*!    \overload    Sets the value of the field called \a name to \a val. If the field    does not exist, nothing happens.*/void QSqlRecord::setValue(const QString& name, const QVariant& val){    setValue(indexOf(name), val);}/*! \internal*/void QSqlRecord::detach(){    qAtomicDetach(d);}#ifndef QT_NO_DEBUG_STREAMQDebug operator<<(QDebug dbg, const QSqlRecord &r){    dbg.nospace() << "QSqlRecord(" << r.count() << ")";    for (int i = 0; i < r.count(); ++i)        dbg.nospace() << QLatin1String("\n ") << QString::fromLatin1("%1: ").arg(i, 2)                      << r.field(i);    return dbg.space();}#endif/*!    \fn int QSqlRecord::position(const QString& name) const    Use indexOf() instead.*/

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色婷婷精品大在线视频| 99久久国产综合精品麻豆| 亚洲自拍都市欧美小说| 亚洲欧洲中文日韩久久av乱码| 久久久电影一区二区三区| 久久久99免费| 国产丝袜欧美中文另类| 国产免费久久精品| 亚洲国产精品ⅴa在线观看| 国产精品女同互慰在线看| 中文一区二区在线观看| 一区在线播放视频| 亚洲欧美日韩在线| 五月天亚洲精品| 美女国产一区二区| 国产在线日韩欧美| 99re热视频精品| 欧美在线视频全部完| 欧美日韩激情在线| 精品少妇一区二区三区在线播放 | 亚洲不卡av一区二区三区| 一区二区三区.www| 日韩电影在线免费| 国产成人aaa| 欧美在线一区二区三区| 日韩精品一区二区在线| 国产精品视频免费看| 亚洲午夜电影网| 激情欧美一区二区| 99国内精品久久| 欧美肥胖老妇做爰| 国产日韩av一区| 性做久久久久久| 成人一级片网址| 欧美日本高清视频在线观看| 精品久久免费看| 亚洲欧美激情插| 经典三级视频一区| 色拍拍在线精品视频8848| 精品国产不卡一区二区三区| 国产精品不卡在线| 九九**精品视频免费播放| 99re热视频精品| 久久你懂得1024| 午夜视频在线观看一区二区| 国产ts人妖一区二区| 欧美丰满一区二区免费视频 | 99精品国产视频| 欧美一区二区啪啪| 亚洲精品高清在线| 国产一区 二区 三区一级| 91黄视频在线观看| 精品福利二区三区| 丝袜美腿亚洲一区| 97超碰欧美中文字幕| 久久综合色天天久久综合图片| 一区二区三区日韩精品视频| 成人午夜在线免费| 久久亚洲一区二区三区明星换脸| 日韩黄色小视频| 欧美性色黄大片手机版| ●精品国产综合乱码久久久久| 国产在线视频不卡二| 日韩欧美国产高清| 日本麻豆一区二区三区视频| 欧美三级电影网| 亚洲女爱视频在线| 97se亚洲国产综合自在线| 日本一区二区不卡视频| 国产成人激情av| 国产性天天综合网| 国产乱码字幕精品高清av| 日韩午夜电影在线观看| 青青草91视频| 欧美一级在线视频| 免费av成人在线| 精品久久久久久无| 韩国av一区二区三区| 久久久久久麻豆| 国产91丝袜在线播放0| 国产目拍亚洲精品99久久精品| 国产精品一区一区三区| 国产日韩欧美综合在线| 丰满亚洲少妇av| 亚洲三级在线播放| 欧洲精品一区二区| 午夜国产精品一区| 欧美成人精精品一区二区频| 激情深爱一区二区| 国产精品嫩草影院av蜜臀| 91在线免费播放| 亚洲国产视频a| 欧美一级在线免费| 懂色av中文一区二区三区| 国产精品国产成人国产三级| 91在线视频18| 免费人成在线不卡| 欧美精彩视频一区二区三区| 91在线视频免费观看| 日韩精品成人一区二区在线| 精品国产青草久久久久福利| 丁香啪啪综合成人亚洲小说 | 日韩中文字幕麻豆| 精品日韩成人av| 丰满放荡岳乱妇91ww| 亚洲一区二区三区中文字幕| 777色狠狠一区二区三区| 国产精品18久久久久久久网站| 中文字幕中文字幕中文字幕亚洲无线| 欧美中文字幕久久| 国产一区二区精品久久91| 亚洲日本在线视频观看| 欧美电影一区二区三区| 国产69精品久久99不卡| 午夜激情久久久| 国产精品久久久久久久浪潮网站| 欧美午夜精品免费| 国产成人av一区| 日韩国产成人精品| 中文字幕日韩欧美一区二区三区| 91精品国产色综合久久不卡电影 | 国产亚洲精品福利| 欧美片在线播放| 9人人澡人人爽人人精品| 美女脱光内衣内裤视频久久网站| 国产精品视频免费| 精品国精品国产| 精品视频在线免费看| 成人免费毛片aaaaa**| 九九精品视频在线看| 亚洲国产wwwccc36天堂| 一区免费观看视频| 国产亚洲一区二区三区四区 | 国产一区二三区好的| 亚洲国产视频一区二区| 一区在线观看视频| 国产亚洲va综合人人澡精品| 精品伦理精品一区| 欧美一区二区三区四区视频| 欧亚洲嫩模精品一区三区| 色综合视频一区二区三区高清| 国产成+人+日韩+欧美+亚洲| 精品无人区卡一卡二卡三乱码免费卡| 亚洲h动漫在线| 午夜在线成人av| 亚洲一线二线三线视频| 亚洲视频狠狠干| 亚洲视频狠狠干| 亚洲日本护士毛茸茸| 亚洲日本韩国一区| 日韩毛片精品高清免费| 国产精品剧情在线亚洲| 欧美国产禁国产网站cc| 国产免费成人在线视频| 国产精品乱码久久久久久| 中文字幕欧美日韩一区| 国产精品欧美经典| 亚洲日本一区二区| 亚洲美女视频一区| 一区二区三区美女视频| 亚洲五码中文字幕| 天天综合日日夜夜精品| 日本不卡高清视频| 精品一区二区三区在线播放| 国内成人精品2018免费看| 九九九精品视频| 从欧美一区二区三区| 99麻豆久久久国产精品免费| 色先锋aa成人| 欧美一区二区久久| 久久久久久久久久久久久久久99| 久久精品水蜜桃av综合天堂| 国产日本欧美一区二区| 亚洲日本va在线观看| 一区二区理论电影在线观看| 亚洲v日本v欧美v久久精品| 久久精品国内一区二区三区| 狠狠色综合播放一区二区| 高清不卡一区二区| 欧美影院精品一区| 精品免费视频.| 亚洲欧洲日产国产综合网| 亚洲一区二区三区四区五区黄 | 视频一区二区不卡| 激情图片小说一区| 色综合久久久久久久| 日韩一区二区在线看| 中文字幕欧美国产| 亚洲午夜三级在线| 国产麻豆日韩欧美久久| 一本色道a无线码一区v| 日韩精品一区在线| 夜色激情一区二区| 国产jizzjizz一区二区| 欧美日韩精品专区| 国产精品三级在线观看| 免费观看在线色综合| 色呦呦国产精品| 日本一区二区三区视频视频| 日本女人一区二区三区|