--[[----------------------------------------------------------------------------

NmbAcr.lua

--------------------------------------------------------------------------------

ADOBE CONFIDENTIAL
------------------
Copyright 2020 Adobe
All Rights Reserved.

NOTICE: All information contained herein is, and remains
the property of Adobe and its suppliers, if any. The intellectual
and technical concepts contained herein are proprietary to Adobe
and its suppliers and are protected by all applicable intellectual
property laws, including trade secret and copyright laws.
Dissemination of this information or reproduction of this material
is strictly forbidden unless prior written permission is obtained
from Adobe.

------------------------------------------------------------------------------]]

local WFPlatformInfo = require 'WFPlatformInfo'


local NmbAcr = {}

--------------------------------------------------------------------------------

function NmbAcr.setApiTable( apiTable )
	NmbAcr.WFCrInfo = assert( apiTable.WFCrInfo )
	NmbAcr.WFAcrOperations = assert( apiTable.WFAcrOperations )
	NmbAcr.WFCrContext = assert( apiTable.WFCrContext )
	NmbAcr.WFNativeVideoContext = assert( apiTable.WFNativeVideoContext )
end

--------------------------------------------------------------------------------

if WFPlatformInfo.isUnitTest() then

	local NmbAcrMocks = require 'NmbAcrMocks'
	NmbAcr.setApiTable( NmbAcrMocks.getApiTable() )

else

	if NmbAcr.WFCrInfo == nil then

		local apiTable = {
			WFCrInfo = require 'WFCrInfo',
			WFAcrOperations = require 'WFAcrOperations',
			WFCrContext = require 'WFCrContext',
			WFNativeVideoContext = require 'WFNativeVideoContext',
		}

		NmbAcr.setApiTable( apiTable )

	end

end

return NmbAcr
