Home | History | Annotate | Download | only in common

Lines Matching refs:Resource

19 *   06/24/02    weiv        Added support for resource sharing
37 * Resource access helpers
53 /* empty resources, returned when the resource offset is 0 */
64 * the resource is of the expected type.
156 /* get the root resource */
158 pResData->rootRes=(Resource)*pResData->pRoot;
290 res_getPublicType(Resource res) {
295 res_getString(const ResourceData *pResData, Resource res, int32_t *pLength) {
330 res_getAlias(const ResourceData *pResData, Resource res, int32_t *pLength) {
349 res_getBinary(const ResourceData *pResData, Resource res, int32_t *pLength) {
369 res_getIntVector(const ResourceData *pResData, Resource res, int32_t *pLength) {
387 res_countArrayItems(const ResourceData *pResData, Resource res) {
410 U_CAPI Resource U_EXPORT2
411 res_getTableItemByKey(const ResourceData *pResData, Resource table,
425 const Resource *p32=(const Resource *)(p+length+(~length&1));
444 return (Resource)p[length+idx];
454 U_CAPI Resource U_EXPORT2
455 res_getTableItemByIndex(const ResourceData *pResData, Resource table,
464 const Resource *p32=(const Resource *)(p+length+(~length&1));
490 return (Resource)p[length+indexR];
500 U_CAPI Resource U_EXPORT2
507 U_CAPI Resource U_EXPORT2
508 res_getArrayItem(const ResourceData *pResData, Resource array, int32_t indexR) {
514 return (Resource)p[1+indexR];
531 U_CFUNC Resource
532 res_findResource(const ResourceData *pResData, Resource r, char** path, const char** key) {
534 * iterates over a path and stops when a scalar resource is found. This
540 Resource t1 = r;
541 Resource t2;
545 /* if you come in with an empty path, you'll be getting back the same resource */
550 /* one needs to have an aggregate resource in order to search in it */
557 * resource (t1 == RES_BOGUS) or we found a scalar resource (including alias)
570 /* if the resource is a table */
576 /* if we fail to get the resource by key, maybe we got an index */
596 /* position pathP to next resource key/index */
603 /* resource bundle swapping ------------------------------------------------- */
620 * These swapping functions assume that a resource bundle always has a length
624 * array of resource items (uint32_t values) is always last.
663 /* resource table key for collation binaries: "%%CollationBin" */
672 * swap one resource item
676 const Resource *inBundle, Resource *outBundle,
677 Resource res, /* caller swaps res itself */
681 const Resource *p;
682 Resource *q;
703 /* we already swapped this resource item */
752 Resource item;
893 Resource *r;
899 r=(Resource *)pTempTable->resort;
913 Resource item;
952 const Resource *inBundle;
953 Resource rootRes;
962 /* the following integers count Resource item offsets (4 bytes each), not bytes */
981 udata_printError(ds, "ures_swap(): data format %02x.%02x.%02x.%02x (format version %02x.%02x) is not a resource bundle\n",
990 /* a resource bundle must contain at least one resource item */
998 udata_printError(ds, "ures_swap(): too few bytes (%d after header) for a resource bundle\n",
1005 inBundle=(const Resource *)((const char *)inData+headerSize);
1013 resource bundle\n");
1028 udata_printError(ds, "ures_swap(): resource top %d exceeds bundle length %d\n",
1040 Resource *outBundle=(Resource *)((char *)outData+headerSize);
1047 * We need one bit per 4 resource bundle bytes so that we can track
1048 * every possible Resource for whether we have swapped it already.
1049 * Multiple Resource words can refer to the same bundle offsets
1052 * where Resource values are stored (above keys & strings).
1090 /* allocate the temporary table for sorting resource tables */
1123 /* swap the root resource and indexes */