@Test(expected = ScriptFormatException.class) public void throwOnInvalidScriptFormat2() { VerificationScript script = new VerificationScript( Numeric.hexStringToByteArray("0123456789abcdef")); script.getSigningThreshold(); }
public int getSigningThreshold() { if (isSingleSigScript()) { return 1; } else if (isMultiSigScript()) { try { return new BinaryReader(script).readPushInteger(); } catch (DeserializationException e) { throw new RuntimeException(e); } } throw new ScriptFormatException("The signing threshold cannot be determined because this " + "script does not apply to the format of a signature verification script."); }
VerificationScript extends NeoSerializable { public int getSigningThreshold() { if (isSingleSigScript()) { return 1; } else if (isMultiSigScript()) { try { return new BinaryReader(script).readPushInteger(); } catch (DeserializationException e) { throw new RuntimeException(e); } } throw new ScriptFormatException("The signing threshold cannot be determined because this " + "script does not apply to the format of a signature verification script."); } }
VerificationScript extends NeoSerializable { public int getSigningThreshold() { if (isSingleSigScript()) { return 1; } else if (isMultiSigScript()) { try { return new BinaryReader(script).readPushInteger(); } catch (DeserializationException e) { throw new RuntimeException(e); } } throw new ScriptFormatException("The signing threshold cannot be determined because this " + "script does not apply to the format of a signature verification script."); } VerificationScript();  VerificationScript(byte[] script);  VerificationScript(ECPublicKey publicKey);  VerificationScript(List<ECPublicKey> publicKeys, int signingThreshold); }
VerificationScript extends NeoSerializable { public int getSigningThreshold() { if (isSingleSigScript()) { return 1; } else if (isMultiSigScript()) { try { return new BinaryReader(script).readPushInteger(); } catch (DeserializationException e) { throw new RuntimeException(e); } } throw new ScriptFormatException("The signing threshold cannot be determined because this " + "script does not apply to the format of a signature verification script."); } VerificationScript();  VerificationScript(byte[] script);  VerificationScript(ECPublicKey publicKey);  VerificationScript(List<ECPublicKey> publicKeys, int signingThreshold); byte[] getScript(); @Override byte[] toArray(); ScriptHash getScriptHash(); @Override int getSize(); int getSigningThreshold(); int getNrOfAccounts(); boolean isSingleSigScript(); boolean isMultiSigScript(); List<ECPublicKey> getPublicKeys(); @Override void deserialize(BinaryReader reader); @Override void serialize(BinaryWriter writer); @Override boolean equals(Object o); @Override int hashCode(); }
VerificationScript extends NeoSerializable { public int getSigningThreshold() { if (isSingleSigScript()) { return 1; } else if (isMultiSigScript()) { try { return new BinaryReader(script).readPushInteger(); } catch (DeserializationException e) { throw new RuntimeException(e); } } throw new ScriptFormatException("The signing threshold cannot be determined because this " + "script does not apply to the format of a signature verification script."); } VerificationScript();  VerificationScript(byte[] script);  VerificationScript(ECPublicKey publicKey);  VerificationScript(List<ECPublicKey> publicKeys, int signingThreshold); byte[] getScript(); @Override byte[] toArray(); ScriptHash getScriptHash(); @Override int getSize(); int getSigningThreshold(); int getNrOfAccounts(); boolean isSingleSigScript(); boolean isMultiSigScript(); List<ECPublicKey> getPublicKeys(); @Override void deserialize(BinaryReader reader); @Override void serialize(BinaryWriter writer); @Override boolean equals(Object o); @Override int hashCode();  }