Function Class | Extending Qt Creator Manual

Extending Qt Creator Manual | Function

Extending Qt Creator Manual 4.4.1

# Function Class

(QmlJS::Function)

Inherits: | QmlJS::FunctionValue

- List of all members, including inherited members

## Public Functions

| Function(ValueOwner *valueOwner)
| ~Function()
void | addArgument(const Value *argument, const QString &name = QString())
void | setOptionalNamedArgumentCount(int count)
void | setReturnValue(const Value *returnValue)
void | setVariadic(bool variadic)

## Reimplemented Public Functions

virtual const Value * | argument(int index) const override
virtual QString | argumentName(int index) const override
virtual const Function * | asFunction() const override
virtual bool | isVariadic() const override
virtual int | namedArgumentCount() const override
virtual int | optionalNamedArgumentCount() const override
virtual const Value * | returnValue() const override

- 8 public functions inherited from QmlJS::FunctionValue
- 16 public functions inherited from QmlJS::ObjectValue
- 29 public functions inherited from QmlJS::Value

## Member Function Documentation

### Function::Function(ValueOwner *valueOwner)

Default constructs an instance of Function.

### Function::~Function()

Destroys the instance of Function.

### void Function::addArgument(const Value *argument, const QString &name = QString())

### `[override virtual]` const Value *Function::argument(int index) const

### `[override virtual]` QString Function::argumentName(int index) const

### `[override virtual]` const Function *Function::asFunction() const

### `[override virtual]` bool Function::isVariadic() const

### `[override virtual]` int Function::namedArgumentCount() const

### `[override virtual]` int Function::optionalNamedArgumentCount() const

See also setOptionalNamedArgumentCount().

### `[override virtual]` const Value *Function::returnValue() const

See also setReturnValue().

### void Function::setOptionalNamedArgumentCount(int count)

See also optionalNamedArgumentCount().

### void Function::setReturnValue(const Value *returnValue)

See also returnValue().

### void Function::setVariadic(bool variadic)

See also isVariadic().