74 return (
nm == other.
nm 211 return ((
d == other.
d || *
d == *other.
d)
212 && val == other.
val);
257 d->len = fieldLength;
429 {
return val.isNull(); }
522 #ifndef QT_NO_DEBUG_STREAM 525 #ifndef Q_BROKEN_DEBUG_STREAM 532 dbg.
nospace() <<
", required: " 542 qWarning(
"This compiler doesn't support streaming QSqlField to QDebug");
578 d->autoval = autoVal;
The QVariant class acts like a union for the most common Qt data types.
The QDebug class provides an output stream for debugging information.
void qAtomicDetach(T *&d)
This is a helper for the detach method of implicitly shared classes.
void setType(QVariant::Type type)
Set's the field's variant type to type.
void setRequiredStatus(RequiredStatus status)
Sets the required status of this field to required.
bool isValid() const
Returns true if the field's variant type is valid; otherwise returns false.
#define QT_END_NAMESPACE
This macro expands to.
bool isNull() const
Returns true if this is a NULL variant, false otherwise.
The QAtomicInt class provides platform-independent atomic operations on integers. ...
void setReadOnly(bool readOnly)
Sets the read only flag of the field's value to readOnly.
QDebug & nospace()
Clears the stream's internal flag that records whether the last character was a space and returns a r...
QSqlFieldPrivate(const QString &name, QVariant::Type type)
void setName(const QString &name)
Sets the name of the field to name.
QSqlField::RequiredStatus req
void setPrecision(int precision)
Sets the field's precision.
void setDefaultValue(const QVariant &value)
Sets the default value used for this field to value.
bool isReadOnly() const
Returns true if the field's value is read-only; otherwise returns false.
The QString class provides a Unicode character string.
static const char * typeToName(Type type)
Converts the enum representation of the storage type, typ, to its string representation.
QVariant defaultValue() const
Returns the field's default value (which may be NULL).
QString name() const
Returns the name of the field.
~QSqlField()
Destroys the object and frees any allocated resources.
void setGenerated(bool gen)
Sets the generated state.
bool isAutoValue() const
Returns true if the value is auto-generated by the database, for example auto-increment primary key v...
#define QT_BEGIN_NAMESPACE
This macro expands to.
RequiredStatus
Specifies whether the field is required or optional.
QDebug operator<<(QDebug dbg, const QSqlField &f)
QSqlFieldPrivate(const QSqlFieldPrivate &other)
void clear()
Clears the value of the field and sets it to NULL.
void setLength(int fieldLength)
Sets the field's length to fieldLength.
Q_CORE_EXPORT void qWarning(const char *,...)
Type
This enum type defines the types of variable that a QVariant can contain.
QVariant::Type type() const
Returns the field's type as stored in the database.
int precision() const
Returns the field's precision; this is only meaningful for numeric types.
int length() const
Returns the field's length.
bool operator==(const QSqlFieldPrivate &other) const
bool isNull() const
Returns true if the field's value is NULL; otherwise returns false.
int typeID() const
Returns the type ID for the field.
void qAtomicAssign(T *&d, T *x)
This is a helper for the assignment operators of implicitly shared classes.
bool operator==(const QSqlField &other) const
Returns true if the field is equal to other; otherwise returns false.
The QSqlField class manipulates the fields in SQL database tables and views.
void setAutoValue(bool autoVal)
Marks the field as an auto-generated value if autoVal is true.
QDebug & space()
Writes a space character to the debug stream and returns a reference to the stream.
#define Q_UNUSED(x)
Indicates to the compiler that the parameter with the specified name is not used in the body of a fun...
QSqlField(const QString &fieldName=QString(), QVariant::Type type=QVariant::Invalid)
Constructs an empty field called fieldName of variant type type.
bool isGenerated() const
Returns true if the field is generated; otherwise returns false.
QSqlField & operator=(const QSqlField &other)
Sets the field equal to other.
void setValue(const QVariant &value)
Sets the value of the field to value.
RequiredStatus requiredStatus() const
Returns true if this is a required field; otherwise returns false.
void setSqlType(int type)