Link Search Menu Expand Document

πŸ– Self Compare (String)

PCGEx | Filter : Self Compare (String)

Compares the string value at one index against the same attribute at another index.

-


Filter
A single filter definition

Table of content


The Self Compare (String) compares the point’ value of a single attribute against that same attribute at another index.

details/filter-ecosystem/filter-compare-string-self-lead.png

Properties


Property Description
Operand A
Operand A The attribute to read compared values from.
Comparison
Comparison How to compare A against B.
See Numeric comparisons.
Tolerance Equality tolerance for near-value comparisons.
Index
Index Mode Choose how to process the Index value as either a Pick (specific index), or an Offset applied to the currently tested point’ index.
Compare Against Type of values for the Index. Can be a per-point Attribute, or an easily overridable Constant.
Index
(Constant or Attribute)
Value to use as Index/Offset.

details/filter-ecosystem/filter-compare-self-explainer.png

Index Safety

The index safety property controls how invalid/out of bounds input values are handled.

Safety method Β 
Ignore Invalid indices will be ignored and won’t be processed further.
Tile Index is tiled (wrapped around) the context’ valid min/max range.
Clamp Index is clamped between the context’ valid min/max range.
Yoyo Index bounces back and forth between the context’ valid min/max range.

Comparison modes


Comparison Data
== Strictly equal.
!= Strictly not equal.
== (Length) String lengths are strictly equal.
!= (Length) String lengths are strictly not equal.
>= (Length) String length is equal or greater.
<= (Length) String lengths are is equal or smaller.
> (Length) String lengths is strictly greater.
< (Length) String lengths is Strictly smaller.
> (Locale) String locale is strictly greater.
In alphabetical order. (Z is greater than A)
< (Locale) String locale is strictly smaller.
In alphabetical order. (A is smaller than Z)
Contains Check if string is contained in another one.
Useful if you have solid naming conventions.
Starts With Check if the string starts with another one.
Useful for prefixes.
Ends With Check if the string ends with another one.
Useful for suffixes.