Sha256: cadce0816f5292f13bf0d6251098ba2ceb5adb6091eddd3506394b3bd43aab5d

Contents?: true

Size: 1.44 KB

Versions: 18

Compression:

Stored size: 1.44 KB

Contents

#pragma once

#ifdef __cplusplus

#include "logging/RhoLog.h"
#include "common/RhoThread.h"
#include "common/IRhoClassFactory.h"

#undef DEFAULT_LOGCATEGORY
#define DEFAULT_LOGCATEGORY "RhodesApp"

namespace rho {
namespace common {

class CRhodesAppBase : public common::CRhoThread
{
public:
    DEFINE_LOGCLASS;

protected:

    static CRhodesAppBase* m_pInstance;

    String m_strRhoRootPath, m_strBlobsDirPath, m_strDBDirPath;
    String m_strHomeUrl;

    CRhodesAppBase(const String& strRootPath);
public:
    static CRhodesAppBase* Create(const String& strRootPath);
    static void Destroy();
    static CRhodesAppBase* getInstance(){ return m_pInstance; }

    String resolveDBFilesPath(const String& strFilePath);
    const String& getRhoRootPath(){return m_strRhoRootPath;}
    const String& getBlobsDirPath(){return m_strBlobsDirPath; }
    const String& getDBDirPath(){return m_strDBDirPath; }
    const String& getHomeUrl(){ return m_strHomeUrl; }

    String canonicalizeRhoUrl(const String& strUrl) ;

protected:
    virtual void run(){}

    void initAppUrls();
};

}
}

inline rho::common::CRhodesAppBase& RHODESAPPBASE(){ return *rho::common::CRhodesAppBase::getInstance(); }

#endif //__cplusplus

#ifdef __cplusplus
extern "C" {
#endif //__cplusplus

const char* rho_native_rhopath();
const char* rho_rhodesapp_getplatform();
int rho_unzip_file(const char* szZipPath);

void rho_free_callbackdata(void* pData);
	
#ifdef __cplusplus
};
#endif //__cplusplus

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
rhodes-2.2.6 platform/shared/common/RhodesAppBase.h
rhodes-2.2.6.beta.1 platform/shared/common/RhodesAppBase.h
rhodes-2.2.5 platform/shared/common/RhodesAppBase.h
rhodes-2.2.5.beta.3 platform/shared/common/RhodesAppBase.h
rhodes-2.2.5.beta.2 platform/shared/common/RhodesAppBase.h
rhodes-2.2.5.beta.1 platform/shared/common/RhodesAppBase.h
rhodes-2.2.4.beta.1 platform/shared/common/RhodesAppBase.h
rhodes-2.2.3 platform/shared/common/RhodesAppBase.h
rhodes-2.2.3.beta.1 platform/shared/common/RhodesAppBase.h
rhodes-2.2.2 platform/shared/common/RhodesAppBase.h
rhodes-2.2.2.beta.1 platform/shared/common/RhodesAppBase.h
rhodes-2.2.1 platform/shared/common/RhodesAppBase.h
rhodes-2.2.1.beta.2 platform/shared/common/RhodesAppBase.h
rhodes-2.2.1.beta.1 platform/shared/common/RhodesAppBase.h
rhodes-2.2.0 platform/shared/common/RhodesAppBase.h
rhodes-2.2.0.beta.3 platform/shared/common/RhodesAppBase.h
rhodes-2.2.0.beta.2 platform/shared/common/RhodesAppBase.h
rhodes-2.2.0.beta.1 platform/shared/common/RhodesAppBase.h