// Copyright Epic Games, Inc. All Rights Reserved. #pragma once #include "AsyncTreeDifferences.h" #define UE_API STATETREEEDITORMODULE_API class SStateTreeView; class UStateTreeState; namespace UE::StateTree::Diff { struct FSingleDiffEntry; class FAsyncDiff : public TAsyncTreeDifferences> { public: UE_API FAsyncDiff(const TSharedRef& LeftTree, const TSharedRef& RightTree); UE_API void GetStateTreeDifferences(TArray& OutDiffEntries) const; private: UE_API void GetStatesDifferences(TArray& OutDiffEntries) const; static UE_API TAttribute>> RootNodesAttribute(TWeakPtr StateTreeView); TSharedPtr LeftView; TSharedPtr RightView; }; } // UE::StateTree::Diff template <> class TTreeDiffSpecification> { public: UE_API bool AreValuesEqual(const TWeakObjectPtr& StateTreeNodeA, const TWeakObjectPtr& StateTreeNodeB, TArray* OutDifferingProperties = nullptr) const; UE_API bool AreMatching(const TWeakObjectPtr& StateTreeNodeA, const TWeakObjectPtr& StateTreeNodeB, TArray* OutDifferingProperties = nullptr) const; UE_API void GetChildren(const TWeakObjectPtr& InParent, TArray>& OutChildren) const; bool ShouldMatchByValue(const TWeakObjectPtr&) const { return false; } bool ShouldInheritEqualFromChildren(const TWeakObjectPtr&, const TWeakObjectPtr&) const { return false; } }; #undef UE_API