IsMatching methods

Project: Resource File Unit

Unit: PJResFile.

Class: TPJResourceEntry

Applies to: ~>1.0

There are two overloaded IsMatching methods. They are both used to check if a resource matches the one represented by the TPJResourceEntry object on which the method is called.

Matching involves comparing the resource entries’ names, types and language ids. In the first version of the method comparison of names and / or types can be omitted.


function IsMatching(const ResType, ResName: Pchar;
  const LangID: Word = $FFFF): Boolean;

Checks if the resource entry has the given type, name and language id. The resource name and/or language id can be ignored in which case only the values provided will be matched. For example to match only a resource type use IsMatching(MyResType, nil);.

Parameters:

Returns:

True if the resources match or False if they do not.


function IsMatching(const Entry: TPJResourceEntry): Boolean;

Checks if the resource entry has the same type, name and language id as another resource entry.

Parameter:

Returns:

True if the entries type, name and language id are all the same or False if they are not.