Attribute object 更多...
#include <Attribute.h>
Public 成员函数 | |
| void | Bind (const FGetter &InGetter) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| void | Bind (FGetter &&InGetter) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| template<class SourceType > | |
| void | Bind (SourceType *InUserObject, typename FGetter::template TSPMethodDelegate_Const< SourceType >::FMethodPtr InMethodPtr) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| template<class SourceType > | |
| void | Bind (TSharedRef< SourceType > InUserObject, typename FGetter::template TSPMethodDelegate_Const< SourceType >::FMethodPtr InMethodPtr) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| template<class SourceType > | |
| void | BindRaw (SourceType *InUserObject, typename FGetter::template TRawMethodDelegate_Const< SourceType >::FMethodPtr InMethodPtr) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| void | BindStatic (typename FGetter::FStaticDelegate::FFuncPtr InFuncPtr) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| template<class SourceType > | |
| void | BindUFunction (SourceType *InUserObject, const FName &InFunctionName) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| template<class SourceType > | |
| void | BindUObject (SourceType *InUserObject, typename FGetter::template TUObjectMethodDelegate_Const< SourceType >::FMethodPtr InMethodPtr) |
| Binds an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| DECLARE_DELEGATE_RetVal (ObjectType, FGetter) | |
| Attribute 'getter' delegate 更多... | |
| const ObjectType & | Get () const |
| Gets the attribute's current value. 更多... | |
| const ObjectType & | Get (const ObjectType &DefaultValue) const |
| Gets the attribute's current value. 更多... | |
| const FGetter & | GetBinding () const |
| Gets the attribute's 'getter' which can be bound or unbound 更多... | |
| bool | IdenticalTo (const TAttribute &InOther) const |
| Is this attribute identical to another TAttribute. 更多... | |
| bool | IsBound () const |
| Checks to see if this attribute has a 'getter' function bound 更多... | |
| bool | IsSet () const |
| Was this TAttribute ever assigned? | |
| template<typename OtherType > | |
| void | Set (const OtherType &InNewValue) |
| Sets the attribute's value 更多... | |
| void | Set (ObjectType &&InNewValue) |
| Sets the attribute's value 更多... | |
| TAttribute () | |
| Default constructor. | |
| template<typename OtherType > | |
| TAttribute (const OtherType &InInitialValue) | |
| Construct implicitly from an initial value 更多... | |
| TAttribute (ObjectType &&InInitialValue) | |
| Construct implicitly from moving an initial value 更多... | |
| template<class SourceType > | |
| TAttribute (SourceType *InUserObject, typename FGetter::template TSPMethodDelegate_Const< SourceType >::FMethodPtr InMethodPtr) | |
| Constructs by binding an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| template<class SourceType > | |
| TAttribute (TSharedRef< SourceType > InUserObject, typename FGetter::template TSPMethodDelegate_Const< SourceType >::FMethodPtr InMethodPtr) | |
| Constructs by binding an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
静态 Public 成员函数 | |
| static TAttribute | Create (const FGetter &InGetter) |
| Static: Creates an attribute that's pre-bound to the specified 'getter' delegate 更多... | |
| template<class SourceType > | |
| static TAttribute< ObjectType > | Create (SourceType *InUserObject, const FName &InFunctionName) |
| Creates an attribute by binding an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
| static TAttribute | Create (typename FGetter::FStaticDelegate::FFuncPtr InFuncPtr) |
| Creates an attribute by binding an arbitrary function that will be called to generate this attribute's value on demand. 更多... | |
Attribute object
|
inline |
Construct implicitly from an initial value
| InInitialValue | The value for this attribute |
|
inline |
Construct implicitly from moving an initial value
| InInitialValue |
|
inline |
Constructs by binding an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Shared Pointer to the instance of the class that contains the member function you want to bind. The attribute will only retain a weak pointer to this class. |
| InMethodPtr | Member function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
|
inline |
Constructs by binding an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Shared Pointer to the instance of the class that contains the member function you want to bind. The attribute will only retain a weak pointer to this class. |
| InMethodPtr | Member function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InGetter | The delegate object with your function binding |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InGetter | The delegate object with your function binding |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Shared Pointer to the instance of the class that contains the member function you want to bind. The attribute will only retain a weak pointer to this class. |
| InMethodPtr | Member function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Shared Pointer to the instance of the class that contains the member function you want to bind. The attribute will only retain a weak pointer to this class. |
| InMethodPtr | Member function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Instance of the class that contains the member function you want to bind. |
| InMethodPtr | Member function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InFuncPtr | Function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Instance of the class that contains the member function you want to bind. |
| InFunctionName | Member function name to bind. |
|
inline |
Binds an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Instance of the class that contains the member function you want to bind. |
| InMethodPtr | Member function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
|
inlinestatic |
Static: Creates an attribute that's pre-bound to the specified 'getter' delegate
| InGetter | Delegate to bind |
|
inlinestatic |
Creates an attribute by binding an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InUserObject | Instance of the class that contains the member function you want to bind. |
| InFunctionName | Member function name to bind. |
|
inlinestatic |
Creates an attribute by binding an arbitrary function that will be called to generate this attribute's value on demand.
After binding, the attribute will no longer have a value that can be accessed directly, and instead the bound function will always be called to generate the value.
| InFuncPtr | Member function to bind. The function's structure (return value, arguments, etc) must match IBoundAttributeDelegate's definition. |
| TAttribute< ObjectType >::DECLARE_DELEGATE_RetVal | ( | ObjectType | , |
| FGetter | |||
| ) |
Attribute 'getter' delegate
ObjectType GetValue() const
|
inline |
Gets the attribute's current value.
Assumes that the attribute is set.
|
inline |
Gets the attribute's current value.
The attribute may not be set, in which case use the default value provided. Shorthand for the boilerplate code: MyAttribute.IsSet() ? MyAttribute.Get() : DefaultValue
|
inline |
Gets the attribute's 'getter' which can be bound or unbound
|
inline |
Is this attribute identical to another TAttribute.
| InOther | The other attribute to compare with. |
|
inline |
Checks to see if this attribute has a 'getter' function bound
|
inline |
Sets the attribute's value
| InNewValue | The value to set the attribute to |
|
inline |
Sets the attribute's value
| InNewValue | The value to set the attribute to |