public class IPv4AddressMatchExprMacro extends Object implements ExprMacroTable.ExprMacro
Implements an expression that checks if an IPv4 address belongs to a particular subnet. Expression signatures: - long ipv4_match(string address, string subnet) - long ipv4_match(long address, string subnet) Valid "address" argument formats are: - unsigned int long (e.g., 3232235521) - IPv4 address dotted-decimal string (e.g., "198.168.0.1") The argument format for the "subnet" argument should be a literal in CIDR notation (e.g., "198.168.0.0/16"). If the "address" argument does not represent an IPv4 address then false is returned.
| Constructor and Description |
|---|
IPv4AddressMatchExprMacro() |
| Modifier and Type | Method and Description |
|---|---|
Expr |
apply(List<Expr> args) |
String |
name() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitprocessingFailed, validationFailed, validationFailed, validationHelperCheckAnyOfArgumentCount, validationHelperCheckArgIsLiteral, validationHelperCheckArgumentCount, validationHelperCheckArgumentCount, validationHelperCheckArgumentRange, validationHelperCheckLambaArgumentCount, validationHelperCheckMinArgumentCount, validationHelperCheckMinArgumentCountpublic static final String FN_NAME
public String name()
name in interface NamedFunctionpublic Expr apply(List<Expr> args)
apply in interface ExprMacroTable.ExprMacroCopyright © 2011–2022 The Apache Software Foundation. All rights reserved.