Package com.bradyrussell.uiscoin.script
Class ScriptMatcher
java.lang.Object
com.bradyrussell.uiscoin.script.ScriptMatcher
public class ScriptMatcher
extends java.lang.Object
ScriptMatcher is used to match and / or extract push data from scripts.
ScriptMatcher#match returns a boolean whether the script matches the matcher.
A matcher, created with ScriptMatcherBuilder, matches a script
There are default matchers provided for the default transaction types.
-
Field Summary
Fields Modifier and Type Field Description int
OptionalOperatorsAtEnd
java.util.ArrayList<byte[]>
PushContents
java.util.ArrayList<ScriptOperator>
scriptMatch
-
Constructor Summary
Constructors Constructor Description ScriptMatcher()
-
Method Summary
Modifier and Type Method Description static ScriptMatcher
getMatcherP2Password()
static ScriptMatcher
getMatcherP2PK()
static ScriptMatcher
getMatcherP2PKH()
static ScriptMatcher
getMatcherP2SH()
int
getPushCount()
byte[]
getPushData(int Index)
boolean
match(byte[] Script)
-
Field Details
-
scriptMatch
-
PushContents
public final java.util.ArrayList<byte[]> PushContents -
OptionalOperatorsAtEnd
public int OptionalOperatorsAtEnd
-
-
Constructor Details
-
ScriptMatcher
public ScriptMatcher()
-
-
Method Details
-
match
public boolean match(byte[] Script) -
getPushData
public byte[] getPushData(int Index) -
getPushCount
public int getPushCount() -
getMatcherP2PK
-
getMatcherP2PKH
-
getMatcherP2Password
-
getMatcherP2SH
-