Harmony
Scripting Interface Documentation
Attribute Class Reference

The JavaScript class encapsulating a node attribute. Obtain one from the node getAttr or getAttrList methods. More...

Public Slots

virtual String keyword ()
 Attribute keyword. More...
 
String name ()
 Attribute name. More...
 
virtual String typeName ()
 Attribute typeName. More...
 
virtual bool boolValue ()
 Fetch boolean value from Attribute at current frame. More...
 
virtual int intValue ()
 Fetch integer value from Attribute at current frame. More...
 
virtual double doubleValue ()
 Fetch double value from Attribute at current frame. More...
 
virtual String textValue ()
 Fetch String value from Attribute at current frame. More...
 
virtual ColorRGBA colorValue ()
 Fetch ColorRGBA value from Attribute at current frame. More...
 
virtual Point2d pos2dValue ()
 Fetch Point2d value from Attribute at current frame. More...
 
virtual Point3d pos3dValue ()
 Fetch Point3d value from Attribute at current frame. More...
 
virtual bool boolValueAt (double frame)
 Fetch boolean value from Attribute at the specified frame. More...
 
virtual int intValueAt (double frame)
 Fetch integer value from Attribute at the specified frame. More...
 
virtual double doubleValueAt (double frame)
 Fetch double value from Attribute at the specified frame. More...
 
virtual String textValueAt (double frame)
 Fetch String value from Attribute at the specified frame. More...
 
virtual ColorRGBA colorValueAt (double frame)
 Fetch ColorRGBA value from Attribute at the specified frame. More...
 
virtual Point2d pos2dValueAt (double frame)
 Fetch Point2d value from Attribute at the specified frame. More...
 
virtual Point3d pos3dValueAt (double frame)
 Fetch Point3d value from Attribute at the specified frame. More...
 
virtual void setValue (QObjectv)
 
virtual void setValue (int v)
 
virtual void setValue (double v)
 
virtual void setValue (bool v)
 
virtual void setValue (String &v)
 
bool hasSubAttributes ()
 

Detailed Description

The JavaScript class encapsulating a node attribute. Obtain one from the node getAttr or getAttrList methods.

This class is polymorphic and can be used to handle multiple types as long as they are compatible with the initial attribute.

Member Function Documentation

◆ boolValue

virtual bool Attribute::boolValue ( )
virtualslot

Fetch boolean value from Attribute at current frame.

Returns
bool value, or false if it cannot be casted to bool

◆ boolValueAt

virtual bool Attribute::boolValueAt ( double  frame)
virtualslot

Fetch boolean value from Attribute at the specified frame.

Parameters
frameFrame number
Returns
bool value, or false if cannot cast to bool

◆ colorValue

virtual ColorRGBA Attribute::colorValue ( )
virtualslot

Fetch ColorRGBA value from Attribute at current frame.

Returns
ColorRGBA value, or (255,255,255,255) if it cannot be casted to ColorRGBA

◆ colorValueAt

virtual ColorRGBA Attribute::colorValueAt ( double  frame)
virtualslot

Fetch ColorRGBA value from Attribute at the specified frame.

Parameters
frameFrame number
Returns
ColorRGBA value, or (255,255,255,255) if cannot cast to ColorRGBA

◆ doubleValue

virtual double Attribute::doubleValue ( )
virtualslot

Fetch double value from Attribute at current frame.

Returns
double value, or 0.0 if it cannot be casted to double

◆ doubleValueAt

virtual double Attribute::doubleValueAt ( double  frame)
virtualslot

Fetch double value from Attribute at the specified frame.

Parameters
frameFrame number
Returns
double value, or 0.0 if cannot cast to double

◆ hasSubAttributes

bool Attribute::hasSubAttributes ( )
slot

◆ intValue

virtual int Attribute::intValue ( )
virtualslot

Fetch integer value from Attribute at current frame.

Returns
int value, or 0 if it cannot be casted to int

◆ intValueAt

virtual int Attribute::intValueAt ( double  frame)
virtualslot

Fetch integer value from Attribute at the specified frame.

Parameters
frameFrame number
Returns
int value, or 0 if cannot cast to int

◆ keyword

virtual String Attribute::keyword ( )
virtualslot

Attribute keyword.

Returns
The xml keyword value or an empty String if the attribute is empty

◆ name

String Attribute::name ( )
slot

Attribute name.

Returns
The name of the attribute.

◆ pos2dValue

virtual Point2d Attribute::pos2dValue ( )
virtualslot

Fetch Point2d value from Attribute at current frame.

Returns
Point2d value, or (0,0) if it cannot be casted to Point2d

◆ pos2dValueAt

virtual Point2d Attribute::pos2dValueAt ( double  frame)
virtualslot

Fetch Point2d value from Attribute at the specified frame.

Parameters
frameFrame number
Returns
Point2d value, or (0,0) if cannot cast to Point2d

◆ pos3dValue

virtual Point3d Attribute::pos3dValue ( )
virtualslot

Fetch Point3d value from Attribute at current frame.

Returns
Point3d value, or (0,0,0) if it cannot be casted to Point3d

◆ pos3dValueAt

virtual Point3d Attribute::pos3dValueAt ( double  frame)
virtualslot

Fetch Point3d value from Attribute at the specified frame.

Parameters
frameFrame number
Returns
Point3d value, or (0,0,0) if cannot cast to Point3d

◆ setValue [1/5]

virtual void Attribute::setValue ( QObjectv  )
virtualslot

◆ setValue [2/5]

virtual void Attribute::setValue ( int  v)
virtualslot

◆ setValue [3/5]

virtual void Attribute::setValue ( double  v)
virtualslot

◆ setValue [4/5]

virtual void Attribute::setValue ( bool  v)
virtualslot

◆ setValue [5/5]

virtual void Attribute::setValue ( String &  v)
virtualslot

◆ textValue

virtual String Attribute::textValue ( )
virtualslot

Fetch String value from Attribute at current frame.

Returns
String value, or empty String if it cannot be casted to String

◆ textValueAt

virtual String Attribute::textValueAt ( double  frame)
virtualslot

Fetch String value from Attribute at the specified frame.

Parameters
frameFrame number
Returns
String value, or empty String if it cannot be casted to String

◆ typeName

virtual String Attribute::typeName ( )
virtualslot

Attribute typeName.

Returns
The typeName value associated with the attribute type or an empty String if the attribute is empty