GDevelop Core
Core library for developing platforms and tools compatible with GDevelop.
Public Member Functions | List of all members

Describe user-friendly information about an expression or an instruction (action or condition), its parameters and the function name as well as other information for code generation. More...

#include <AbstractFunctionMetadata.h>

Inherited by gd::ExpressionMetadata, gd::InstructionMetadata, and gd::MultipleInstructionMetadata.

Public Member Functions

virtual AbstractFunctionMetadataAddParameter (const gd::String &type, const gd::String &label, const gd::String &supplementaryInformation="", bool parameterIsOptional=false)=0
 
virtual AbstractFunctionMetadataAddCodeOnlyParameter (const gd::String &type, const gd::String &supplementaryInformation)=0
 
virtual AbstractFunctionMetadataSetDefaultValue (const gd::String &defaultValue)=0
 
virtual AbstractFunctionMetadataSetParameterExtraInfo (const gd::String &defaultValue)=0
 
virtual AbstractFunctionMetadataSetParameterLongDescription (const gd::String &longDescription)=0
 
virtual AbstractFunctionMetadataSetHidden ()=0
 
virtual AbstractFunctionMetadataSetPrivate ()=0
 
virtual AbstractFunctionMetadataSetRelevantForLayoutEventsOnly ()=0
 
virtual AbstractFunctionMetadataSetRelevantForFunctionEventsOnly ()=0
 
virtual AbstractFunctionMetadataSetRelevantForAsynchronousFunctionEventsOnly ()=0
 
virtual AbstractFunctionMetadataSetRelevantForCustomObjectEventsOnly ()=0
 
virtual AbstractFunctionMetadataSetFunctionName (const gd::String &functionName)=0
 Set the function that should be called when generating the source code from events. More...
 
virtual AbstractFunctionMetadataSetIncludeFile (const gd::String &includeFile)=0
 Erase any existing include file and add the specified include. More...
 
virtual AbstractFunctionMetadataAddIncludeFile (const gd::String &includeFile)=0
 Add a file to the already existing include files.
 
virtual const std::vector< gd::String > & GetIncludeFiles () const =0
 Get the files that must be included to use the instruction.
 

Detailed Description

Describe user-friendly information about an expression or an instruction (action or condition), its parameters and the function name as well as other information for code generation.

Member Function Documentation

◆ AddCodeOnlyParameter()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::AddCodeOnlyParameter ( const gd::String type,
const gd::String supplementaryInformation 
)
pure virtual

◆ AddParameter()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::AddParameter ( const gd::String type,
const gd::String label,
const gd::String supplementaryInformation = "",
bool  parameterIsOptional = false 
)
pure virtual

◆ SetDefaultValue()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetDefaultValue ( const gd::String defaultValue)
pure virtual

◆ SetFunctionName()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetFunctionName ( const gd::String functionName)
pure virtual

Set the function that should be called when generating the source code from events.

Parameters
functionNamethe name of the function to call
Note
Shortcut for codeExtraInformation.SetFunctionName.

Implemented in gd::InstructionMetadata, gd::MultipleInstructionMetadata, and gd::ExpressionMetadata.

◆ SetHidden()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetHidden ( )
pure virtual

◆ SetIncludeFile()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetIncludeFile ( const gd::String includeFile)
pure virtual

Erase any existing include file and add the specified include.

Deprecated:
Use AddIncludeFile instead as clearing the list is more error prone.

Implemented in gd::MultipleInstructionMetadata, gd::InstructionMetadata, and gd::ExpressionMetadata.

◆ SetParameterExtraInfo()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetParameterExtraInfo ( const gd::String defaultValue)
pure virtual

◆ SetParameterLongDescription()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetParameterLongDescription ( const gd::String longDescription)
pure virtual

◆ SetPrivate()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetPrivate ( )
pure virtual

Set that the instruction is private - it can't be used outside of the object/ behavior that it is attached too.

Implemented in gd::MultipleInstructionMetadata, gd::InstructionMetadata, and gd::ExpressionMetadata.

◆ SetRelevantForAsynchronousFunctionEventsOnly()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetRelevantForAsynchronousFunctionEventsOnly ( )
pure virtual

Set that the instruction can be used in asynchronous function events.

Implemented in gd::MultipleInstructionMetadata, gd::InstructionMetadata, and gd::ExpressionMetadata.

◆ SetRelevantForCustomObjectEventsOnly()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetRelevantForCustomObjectEventsOnly ( )
pure virtual

Set that the instruction can be used in custom object events.

Implemented in gd::MultipleInstructionMetadata, gd::InstructionMetadata, and gd::ExpressionMetadata.

◆ SetRelevantForFunctionEventsOnly()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetRelevantForFunctionEventsOnly ( )
pure virtual

Set that the instruction can be used in function events.

Implemented in gd::MultipleInstructionMetadata, gd::InstructionMetadata, and gd::ExpressionMetadata.

◆ SetRelevantForLayoutEventsOnly()

virtual AbstractFunctionMetadata& gd::AbstractFunctionMetadata::SetRelevantForLayoutEventsOnly ( )
pure virtual

Set that the instruction can be used in layouts or external events.

Implemented in gd::MultipleInstructionMetadata, gd::InstructionMetadata, and gd::ExpressionMetadata.


The documentation for this class was generated from the following file: