Eneboo - Documentación para desarrolladores
Métodos públicos | Atributos protegidos | Amigas
Referencia de la Clase QSObject

#include <qsobject.h>

Diagrama de herencias de QSObject
Global QSArray QSBoolean QSNull QSNumber QSString QSUndefined QuickScriptVariant

Lista de todos los miembros.

Métodos públicos

 QSObject ()
 QSObject (const QSClass *c)
 QSObject (const QSClass *c, QSShared *s)
 QSObject (const QSObject &)
QSObjectoperator= (const QSObject &)
bool operator== (const QSObject &a) const
 ~QSObject ()
bool isValid () const
void invalidate ()
bool isDefined () const
QString typeName () const
ValueType valueType () const
const QSClassobjectType () const
void setType (QSClass *c)
bool isA (const QSClass *c) const
bool isA (const char *s) const
bool isObject () const
bool isNull () const
bool isUndefined () const
bool isNumber () const
bool isString () const
bool isBoolean () const
bool isFunction () const
bool isPrimitive () const
bool equals (const QSObject &other) const
bool strictEquals (const QSObject &other) const
QSCompareResult compareTo (const QSObject &other) const
QSEnvenv () const
QSObject toPrimitive (const QSClass *preferred=0) const
bool toBoolean () const
double toNumber () const
QVariant toVariant (QVariant::Type t) const
double round () const
int toInteger () const
int toInt32 () const
unsigned int toUInt32 () const
unsigned short toUInt16 () const
QString toString () const
QSObject getQualified (const QString &name) const
QSObject get (const QString &p) const
bool hasProperty (const QString &p) const
void put (const QString &p, const QSObject &v)
bool deleteProperty (const QString &p)
void put (const QString &p, double d)
void put (const QString &p, int i)
void put (const QString &p, unsigned int u)
bool isExecutable () const
QSObject executeCall (QSObject *thisV, const QSList *args)
QSObject execute (const QSList &args)
QSObject invoke (const QSMember &mem, const QSList &args)
QSObject fetchValue (const QSMember &mem)
void write (const QSMember &mem, const QSObject &val)
void mark ()
const QSClassresolveMember (const QString &name, QSMember *mem, const QSClass *owner=0, int *offset=0) const
int iVal () const
void setVal (int v)
double dVal () const
void setVal (double v)
bool bVal () const
void setVal (bool v)
QString sVal () const
void setVal (const QString &v)
void * oVal () const
void setVal (void *v)
QSSharedshVal () const
void setVal (QSShared *s)
QString debugString () const

Atributos protegidos

const QSClassclss

Amigas

class QSStringClass
class QSEnv

Documentación del constructor y destructor

QSObject::QSObject ( )

Constructor.

QSObject::QSObject ( const QSClass c)
QSObject::QSObject ( const QSClass c,
QSShared s 
)

Takes ownership of s

QSObject::QSObject ( const QSObject o)

Copy constructor.

QSObject::~QSObject ( )

Destructor.


Documentación de las funciones miembro

bool QSObject::bVal ( ) const [inline]
QSCompareResult QSObject::compareTo ( const QSObject other) const
QString QSObject::debugString ( ) const
Ver también:
Imp::debugString
bool QSObject::deleteProperty ( const QString p)

The internal [[Delete]] method. Removes the specified property from the object.

Parámetros:
pProperty name.
Devuelve:
True if the property was deleted successfully or didn't exist in the first place. False if the DontDelete attribute was set.
double QSObject::dVal ( ) const [inline]
QSEnv * QSObject::env ( ) const

Returns the environment this object belongs to.

bool QSObject::equals ( const QSObject other) const

Returns true if this object equals . In the case that this object does not know how to compare itself to other, other will try to compare itself to this.

QSObject QSObject::execute ( const QSList args)
QSObject QSObject::executeCall ( QSObject thisV,
const QSList args 
)

Execute function implemented via the Function::execute() method.

Note: check availability via implementsCall() beforehand.

Parámetros:
thisVObject serving as the 'this' value.
argsPointer to the list of arguments or null.
Devuelve:
Result of the function call.
QSObject QSObject::fetchValue ( const QSMember mem)
QSObject QSObject::get ( const QString p) const

The internal [[Get]] method.

Devuelve:
The value of property p.
QSObject QSObject::getQualified ( const QString name) const
bool QSObject::hasProperty ( const QString p) const

The internal [[HasProperty]] method.

Parámetros:
pProperty name.
Devuelve:
Boolean value indicating whether the object already has a member with the given name p.
QSObject::invalidate ( ) [inline]

Returns true if this object is valid i.e. has a type and data attached. Return false otherwise.

Invalidates this object.

Ver también:
isValid
QSObject QSObject::invoke ( const QSMember mem,
const QSList args 
)

Invoke member function mem on this object passing args as arguments. The 'this' value will point to this object during function execution.

bool QSObject::isA ( const char *  s) const

Check whether object is of a certain type. Allows checking of host objects, too.

Parámetros:
typename (Number, Boolean etc.)
bool QSObject::isA ( const QSClass c) const

Returns TRUE if this object is an instance of the type ; FALSE otherwise.

bool QSObject::isBoolean ( ) const

Returns true if the object is a boolean

bool QSObject::isDefined ( ) const
Devuelve:
True if this objects is of any other value than Undefined.
bool QSObject::isExecutable ( ) const
bool QSObject::isFunction ( ) const

Returns true if this object is a function object

bool QSObject::isNull ( ) const

Returns true if the object is a null object

bool QSObject::isNumber ( ) const

Returns true if the object is a number

bool QSObject::isObject ( ) const

Returns true if the object is not a primitive

bool QSObject::isPrimitive ( ) const

Returns true if the object is a primitive, either a bool, number or string

bool QSObject::isString ( ) const

Returns true if the object is a string

bool QSObject::isUndefined ( ) const

Returns true if the object is a undefined

bool QSObject::isValid ( void  ) const [inline]
int QSObject::iVal ( ) const [inline]
void QSObject::mark ( )
const QSClass * QSObject::objectType ( ) const [inline]

Return the object's most specific type

QSObject & QSObject::operator= ( const QSObject o)
bool QSObject::operator== ( const QSObject a) const
void* QSObject::oVal ( ) const [inline]
void QSObject::put ( const QString p,
const QSObject v 
)
void QSObject::put ( const QString p,
double  d 
)

Convenience function for adding a Number property constructed from a double value.

void QSObject::put ( const QString p,
int  i 
)

Convenience function for adding a Number property constructed from an integer value.

void QSObject::put ( const QString p,
unsigned int  u 
)

Convenience function for adding a Number property constructed from an unsigned integer value.

const QSClass * QSObject::resolveMember ( const QString name,
QSMember mem,
const QSClass owner = 0,
int offset = 0 
) const

Tries to resolve a member named name. If it is found mem is initialized with the result and the class defining this member is returned. In case of a failed search, 0 is returned and the content of mem is undefined.

double QSObject::round ( ) const
Devuelve:
Conversion to double. 0.0 if conversion failed.
void QSObject::setType ( QSClass c)
void QSObject::setVal ( bool  v) [inline]
void QSObject::setVal ( int  v) [inline]
void QSObject::setVal ( double  v) [inline]
void QSObject::setVal ( void *  v) [inline]
void QSObject::setVal ( const QString v) [inline]
void QSObject::setVal ( QSShared s) [inline]
QSShared* QSObject::shVal ( ) const [inline]
bool QSObject::strictEquals ( const QSObject other) const
QString QSObject::sVal ( ) const [inline]
bool QSObject::toBoolean ( ) const
Devuelve:
Conversion to Boolean type.
int QSObject::toInt32 ( ) const
Devuelve:
Conversion to signed integer value.
int QSObject::toInteger ( ) const
Devuelve:
Conversion to Number type containing an integer value.
double QSObject::toNumber ( ) const
Devuelve:
Conversion to Number type.
QSObject QSObject::toPrimitive ( const QSClass preferred = 0) const

Examine the inheritance structure of this object.

Parámetros:
tName of the base class.
Devuelve:
True if object is of type t or a derived from such a type.
Conversion to primitive type (Undefined, Boolean, Number or String)
Parámetros:
preferredOptional hint. Either StringType or NumberType.
QString QSObject::toString ( ) const
Devuelve:
Conversion to String type.
unsigned short QSObject::toUInt16 ( ) const
Devuelve:
Conversion to unsigned short value.
unsigned int QSObject::toUInt32 ( ) const
Devuelve:
Conversion to unsigned integer value.
QVariant QSObject::toVariant ( QVariant::Type  t) const

Return this object's value converted to a QVariant. If this is not possible, or the object is invalid, an invalid QVariant will be returned. In case several conversion are possible t can be used to indicate the preferred type. Specifying QVariant::Invalid is good enough for most cases.

QString QSObject::typeName ( ) const
Devuelve:
the type of the object. One of the Type enums.
ValueType QSObject::valueType ( ) const
void QSObject::write ( const QSMember mem,
const QSObject val 
)

Documentación de las funciones relacionadas y clases amigas

friend class QSEnv [friend]
friend class QSStringClass [friend]

Documentación de los datos miembro

const QSClass* QSObject::clss [protected]

La documentación para esta clase fue generada a partir de los siguientes ficheros:
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'