dobrokot 8d57b69dee Restoring authorship annotation for <dobrokot@yandex-team.ru>. Commit 2 of 2. 3 лет назад
..
ut 9abfb1a53b Restoring authorship annotation for <yazevnul@yandex-team.ru>. Commit 2 of 2. 3 лет назад
README.md 1d2e8a8e99 Restoring authorship annotation for <cobat@yandex-team.ru>. Commit 2 of 2. 3 лет назад
registry.cpp 1d2e8a8e99 Restoring authorship annotation for <cobat@yandex-team.ru>. Commit 2 of 2. 3 лет назад
registry.h 8d57b69dee Restoring authorship annotation for <dobrokot@yandex-team.ru>. Commit 2 of 2. 3 лет назад
resource.cpp bd5ef432f5 Restoring authorship annotation for <agorodilov@yandex-team.ru>. Commit 2 of 2. 3 лет назад
resource.h 11a24635da Restoring authorship annotation for <swarmer@yandex-team.ru>. Commit 2 of 2. 3 лет назад
ya.make 4f292c7e2f Restoring authorship annotation for <cerevra@yandex-team.ru>. Commit 2 of 2. 3 лет назад

README.md

This library provides implementation to access a resource (data, file, image, etc.) by a key.

See ya make documentation, resources section for more details.

Example - adding a resource file into build:

LIBRARY()
OWNER(user1)
RESOURCE(
    path/to/file1 /key/in/program/1
    path/to/file2 /key2
)
END()

Example - access to a file content by a key:

#include <library/cpp/resource/resource.h>
int main() {
        Cout << NResource::Find("/key/in/program/1") << Endl;
        Cout << NResource::Find("/key2") << Endl;
}