// Copyright (c) 2024 Codemongous LLC. All Rights Reserved.

#include "SCW_FSubobjectDataHandle.h"
#include "SourcifyCoreUEWrapperModule.h"

using namespace Sourcify;

SCW_FSubobjectDataHandle::SCW_FSubobjectDataHandle(FSubobjectDataHandle* InSubobjectDataHandle) : SubobjectDataHandle(*InSubobjectDataHandle)
{

}

ISCW_FSubobjectDataPtr SCW_FSubobjectDataHandle::GetData() const
{
	return FSourcifyCoreUEWrapper::Get().Wrap(*SubobjectDataHandle.GetData());
}

ISCW_FSubobjectDataHandlePtr SCW_FSubobjectDataHandle::ToFSubobjectDataHandlePtr()
{
	return GetSharedThisAs<SCW_FSubobjectDataHandle>();
}

ISCW_FSubobjectDataHandleConstPtr SCW_FSubobjectDataHandle::ToFSubobjectDataHandlePtr() const
{
	return GetSharedThisAs<SCW_FSubobjectDataHandle>();
}

FSubobjectDataHandle& SCW_FSubobjectDataHandle::ToFSubobjectDataHandle()
{
	return SubobjectDataHandle;
}
