APEX Framework: ResourceProvider.h Source File

NVIDIA APEX

ResourceProvider.h
Go to the documentation of this file.
00001 /*
00002  * Copyright (c) 2008-2017, NVIDIA CORPORATION.  All rights reserved.
00003  *
00004  * NVIDIA CORPORATION and its licensors retain all intellectual property
00005  * and proprietary rights in and to this software, related documentation
00006  * and any modifications thereto.  Any use, reproduction, disclosure or
00007  * distribution of this software and related documentation without an express
00008  * license agreement from NVIDIA CORPORATION is strictly prohibited.
00009  */
00010 
00011 
00012 #ifndef RESOURCE_PROVIDER_H
00013 #define RESOURCE_PROVIDER_H
00014 
00020 #include "ApexUsingNamespace.h"
00021 
00022 namespace nvidia
00023 {
00024 namespace apex
00025 {
00026 
00027 class ResourceCallback;
00028 
00029 PX_PUSH_PACK_DEFAULT
00030 
00038 class ResourceProvider
00039 {
00040 public:
00048     virtual void        registerCallback(ResourceCallback* impl) = 0;
00049 
00053     virtual void        setResource(const char* nameSpace, const char* name, void* resource, bool incRefCount = false) = 0;
00054 
00055 
00059     virtual void        setResourceU32(const char* nameSpace, const char* name, uint32_t id, bool incRefCount = false) = 0;
00060 
00071     virtual void*       getResource(const char* nameSpace, const char* name) = 0;
00072 
00077     virtual uint32_t    releaseAllResourcesInNamespace(const char* nameSpace) = 0;
00078 
00083     virtual uint32_t    releaseResource(const char* nameSpace, const char* name) = 0;
00084 
00088     virtual bool        findRefCount(const char* nameSpace, const char* name, uint32_t& refCount) = 0;
00089 
00096     virtual void*       findResource(const char* nameSpace, const char* name) = 0;
00097 
00101     virtual uint32_t    findResourceU32(const char* nameSpace, const char* name) = 0;
00102 
00106     virtual void**      findAllResources(const char* nameSpace, uint32_t& count) = 0;
00107 
00111     virtual const char** findAllResourceNames(const char* nameSpace, uint32_t& count) = 0;
00112 
00116     virtual const char** findNameSpaces(uint32_t& count) = 0;
00117 
00121     virtual void dumpResourceTable() = 0;
00122 
00132     virtual bool isCaseSensitive() = 0;
00133 };
00134 
00135 PX_POP_PACK
00136 
00137 }
00138 } // end namespace nvidia::apex
00139 
00140 #endif // RESOURCE_PROVIDER_H

Generated on Fri Dec 15 2017 13:58:35
Copyright © 2012-2017 NVIDIA Corporation, 2701 San Tomas Expressway, Santa Clara, CA 95050 U.S.A. All rights reserved.