Open 3D Engine AzToolsFramework API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
AzToolsFramework::Prefab::PrefabOverridePublicInterface Class Referenceabstract

Public Member Functions

 AZ_RTTI (PrefabOverridePublicInterface, "{19F080A2-BDD7-476F-AA50-C1581401FC81}")
 
virtual bool AreOverridesPresent (AZ::EntityId entityId, AZStd::string_view relativePathFromEntity={})=0
 
virtual AZStd::optional< OverrideType > GetEntityOverrideType (AZ::EntityId entityId)=0
 
virtual AZStd::optional< OverrideType > GetComponentOverrideType (const AZ::EntityComponentIdPair &entityComponentIdPair)=0
 
virtual bool RevertOverrides (AZ::EntityId entityId, AZStd::string_view relativePathFromEntity={})=0
 
virtual bool RevertComponentOverrides (const AZ::EntityComponentIdPair &entityComponentIdPair)=0
 

Member Function Documentation

◆ AreOverridesPresent()

virtual bool AzToolsFramework::Prefab::PrefabOverridePublicInterface::AreOverridesPresent ( AZ::EntityId  entityId,
AZStd::string_view  relativePathFromEntity = {} 
)
pure virtual

Checks whether overrides are present on the given entity id. The prefab that creates the overrides is identified by the class implmenting this interface based on certain selections in the editor. eg: the prefab currently being edited.

Parameters
entityIdThe id of the entity to check for overrides.
relativePathFromEntityThe relative path from the entity. This can be used to query about overrides on components and their properties
Returns
true if overrides are present on the given entity id.

◆ GetComponentOverrideType()

virtual AZStd::optional< OverrideType > AzToolsFramework::Prefab::PrefabOverridePublicInterface::GetComponentOverrideType ( const AZ::EntityComponentIdPair &  entityComponentIdPair)
pure virtual

Gets the override type on the given component. The prefab that creates the overrides is identified by the class implmenting this interface based on certain selections in the editor. eg: the prefab currently being edited.

Parameters
entityComponentIdPairThe entityId and componentId for which to get the override type.
Returns
an override type if an override exists on the given component.

◆ GetEntityOverrideType()

virtual AZStd::optional< OverrideType > AzToolsFramework::Prefab::PrefabOverridePublicInterface::GetEntityOverrideType ( AZ::EntityId  entityId)
pure virtual

Gets the override type on the given entity id. The prefab that creates the overrides is identified by the class implmenting this interface based on certain selections in the editor. eg: the prefab currently being edited.

Parameters
entityIdThe id of the entity for which to get the override type.
Returns
an override type if an override exists on the given entity id.

◆ RevertComponentOverrides()

virtual bool AzToolsFramework::Prefab::PrefabOverridePublicInterface::RevertComponentOverrides ( const AZ::EntityComponentIdPair &  entityComponentIdPair)
pure virtual

Revert overrides on the given component. Returns false if no overrides are present on the component.

Parameters
entityComponentIdPairThe entityId and componentId on which overrides should be reverted.
Returns
Whether overrides are successfully reverted on the component.

◆ RevertOverrides()

virtual bool AzToolsFramework::Prefab::PrefabOverridePublicInterface::RevertOverrides ( AZ::EntityId  entityId,
AZStd::string_view  relativePathFromEntity = {} 
)
pure virtual

Revert overrides on the entity matching the entity id. Returns false if no overrides are present on the entity.

Parameters
entityIdThe id of the entity on which overrides should be reverted.
relativePathFromEntityThe relative path from the entity. This can be used to revert overrides on properties.
Returns
Whether overrides are successfully reverted on the entity.

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