#include <nitro/env.h>
ENVResource* ENV_SearchByMember(
ENVResourceIter* iter,
const char* memberName );
iter | The resource iterator. |
memberName |
The member name to search for. |
Returns a pointer to the resource if it was able to be obtained.
Returns a NULL if not.
This function searches for and gets a resource that has a designated member name.
Be sure to prepare a resource iterator in advance and initialize it with ENV_InitIter()
. By continuously searching with this iterator, you can successively obtain resources that match the conditions.
The member name does not include a period ("."). For example, when searching with the member name "member,"
"class.member"
"class.member.001"
"class.member.class"
all have matches, but
"class.member001"
"class.member2.member"
does not match.
(Example)
Below is an example of obtaining the resource with the specific member "memberName".
ENVResourceIter iter;
ENVResource* p;
ENV_InitIter( &iter );
while( (p = ENV_SearchByMember( &iter, "memberName" )) )
{
OS_Printf( "resource = %s\n", p->name );
}
ENV_Init, ENV_InitIter
ENV_SearchByClass, ENV_SearchByType, ENV_SearchByPartialName
ENV_GetLastResourceSetForIter
08/18/2005 Initial version.