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 intOptionalOperatorsAtEndjava.util.ArrayList<byte[]>PushContentsjava.util.ArrayList<ScriptOperator>scriptMatch -
Constructor Summary
Constructors Constructor Description ScriptMatcher() -
Method Summary
Modifier and Type Method Description static ScriptMatchergetMatcherP2Password()static ScriptMatchergetMatcherP2PK()static ScriptMatchergetMatcherP2PKH()static ScriptMatchergetMatcherP2SH()intgetPushCount()byte[]getPushData(int Index)booleanmatch(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
-