FontTableCache.h revision 51cfa1a9a96cad34675a6415fe86dfdf3f525bb6
1/*
2 **********************************************************************
3 *   Copyright (C) 2003-2007, International Business Machines
4 *   Corporation and others.  All Rights Reserved.
5 **********************************************************************
6 */
7
8#ifndef __FONTTABLECACHE_H
9
10#define __FONTTABLECACHE_H
11
12#include "layout/LETypes.h"
13
14U_NAMESPACE_USE
15
16struct FontTableCacheEntry;
17
18class FontTableCache
19{
20public:
21    FontTableCache();
22
23    virtual ~FontTableCache();
24
25    const void *find(LETag tableTag) const;
26
27protected:
28    virtual const void *readFontTable(LETag tableTag) const = 0;
29
30private:
31
32    void add(LETag tableTag, const void *table);
33
34    FontTableCacheEntry *fTableCache;
35    le_int32 fTableCacheCurr;
36    le_int32 fTableCacheSize;
37};
38
39#endif
40
41