Allow clients to define a set of required and known tokens for the template verification. Tokens are expected to be qualified in braces. E.g. {url:path}
If the template does not contain the required tokens or if the format of a known token is incorrect, this method will log the error and return false.
Should call verify after creating a new template.
@param knownTokens the collection of known tokens (Strings) for a valid template. @param requiredTokens the collection of required tokens (Strings) in a valid template. @return true if the template conforms to a valid format, otherwise return false.
|
|
|
|
|
|