Class Reference
IRIS for UNIX 2019.2
InterSystems: The power behind what matters   
Documentation  Search
  [%SYS] >  [%iKnow] >  [Matching] >  [Formats] >  [RegularExpression]
Private  Storage   

class %iKnow.Matching.Formats.RegularExpression extends Format

This class implements Regular Expression matching as an implementation for %iKnow.Matching.Formats.Format, leveraging the ICU implementation in %Regex.Matcher. This implementation does not support matched word indicators, scattered match detection or anything but boolean match scores. Also, it will only verify within entities and therefore never find matches that cross an entity boundary.

Format parameters:

  1. regular expression (%String, mandatory): the regular expression to pass to the %Regex.Matcher object.
  2. replacement string (%String, default ""): if supplied, formatOutput will be populated by running this replacement string against the text and expression pair
  3. replace all (%Boolean, default 1): if set to 0, formatOutput will contain the result of ReplaceFirst() rather than ReplaceAll() when using replace functionality

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
1 1


Summary

Properties
DomainId Matcher

Methods
%AddToSaveSet %ClassIsLatestVersion %ClassName %ConstructClone
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Extends
%GetParameter %IsA %IsModified %New
%NormalizeObject %ObjectModified %OriginalNamespace %PackageName
%RemoveFromSaveSet %SerializeObject %SetModified %ValidateObject
Finalize HasMatchAll MatchAll MatchAllHashes
MatchSingle TestParams


Properties

• property Matcher as %Regex.Matcher;

Methods

• method MatchSingle(string As %String, formatParams As %List, Output matchScore As %Numeric, Output matchedWordBits, Output isScattered As %Boolean, Output formatOutput) as %Status

Implementations of this method check whether an individual string complies with the format this class represents, returning a matchScore (0..1) and optional matchedWordBits, isScattered and formatOutput through output parameters.



Copyright (c) 2019 by InterSystems Corporation. Cambridge, Massachusetts, U.S.A. All rights reserved. Confidential property of InterSystems Corporation.