3
0
mirror of https://github.com/Qortal/AT.git synced 2025-01-30 19:02:14 +00:00
Commit Graph

13 Commits

Author SHA1 Message Date
catbref
e522fb312d Improved test support:
* pom.xml now builds JavaDoc, sources and test JARs
* more descriptive output from test classes to aid debugging
* actually add/collate AT-generated transactions to test blockchain for analysis
* test block period changed from 10 minutes to 1 minute
* 'quiet' logger aded that doesn't emit DEBUG log entries
2021-11-20 15:22:50 +00:00
catbref
0a16696352 New OpCodes:
SLP_DAT addr: fixed to work as advertised
SLP_VAL value: sleeps for <value> blocks
SHL_VAL addr value: left-shifts the contents of addr by value bits
SHR_VAL addr value: right-shifts the contents of addr by value bits

EXT_FUN_VAL func value: pass a value to a function instead of fetching via addr
This allows new functions GET_A_DAT to take data segment address,
instead of convoluted GET_A_IND which requires an address stored in the data segment (like a pointer).

New FunctionCodes:
GET_A_DAT, GET_B_DAT, SET_A_DAT, SET_B_DAT (see above)
UNSIGNED_COMPARE_A_WITH_B, SIGNED_COMPARE_A_WITH_B

Add branch offset bounds checking to OpCode.calcOffset method (throws if out of bounds). Added test to cover.

Tidied up JavaDoc, which is now also generated by pom.xml!
Added JavaDoc comments to OpCodeParam enum entries.
Corrected some inaccurate descriptions.
Converted obsolete <tt> tags to <code>.
Fixed some invalid HTML, converted raw characters like &, <, >, etc. to HTML entites like &amp;, &gt; and &rarr;

Bumped version to 1.4.0
2021-11-13 15:32:10 +00:00
catbref
f78ee39d8b v1.3.8: reduce byte array copying 2020-09-25 12:43:31 +01:00
catbref
2884b586d6 Try to reduce byte arrays being created/copied wherever possible. Also bump to v1.3.7 due to interface changes. 2020-08-12 14:07:56 +01:00
catbref
facb9c213f Convert logging to lambda-based to reduce CPU load if logging disabled, also bump to v1.3.6 as interface changed 2020-08-12 14:06:56 +01:00
catbref
2b28cbe07b Bump to v1.3.5 2020-06-18 16:33:35 +01:00
catbref
3c17db0c46 Bump to version v1.3.4 2020-04-14 17:25:35 +01:00
catbref
d9338f31d3 More visibility tightening. Bump to v1.3.3 due to some method signature changes. 2020-04-09 12:59:23 +01:00
catbref
36008bdeac Fix constructing MachineState from creationBytes. Bump to v1.3.2 2020-04-09 09:38:48 +01:00
catbref
3e0699f399 Fix constructing MachineState from creationBytes. Bump to v1.3.1
NOTE: this constructor's args have changed from:
  public MachineState(byte[] creationBytes)
to:
  public MachineState(API api, byte[] creationBytes)

The bug was miscalculating 'expectedLength'.

Added unit test to cover above.

Also added unit test to cover branching backwards.

Bumped version to 1.3.1 and also fixed pom.xml so it's possible
to call 'mvn clean package' from command line without errors.
2020-04-08 16:53:17 +01:00
catbref
b8311c36ea Bump to version 1.3 2020-04-08 08:15:45 +01:00
catbref
00fd8b040d Updated for Java 11 & other improvements
API:
Added sample AT-emitted transaction types (payment/message).
Maximum number of steps per execution round no longer hard-coded.
API.putTransactionAfterTimestampInA() sets A to zero if no more transactions.
API.putMessageFromTransactionInAIntoB sets B to zero if not a message transaction.
Added some convenience methods.

MachineState:
Added support for minimum activation amount.
Added static method for packing AT into "creation bytes".
No need to store unchanging code in per-height AT state data.

Added support for multiple blockchains to "Timestamp".

General improvements based on Sonarlint suggestions.
General improvements to comments.
Replaced deprecated Byte/Short/Integer/Long constructor call with corresponding .valueOf() call.
Replaced some string concatenations with StringBuilder.

Moved Java-related .gitignore from root to /Java/

Removed .classpath and .project, and added same to .gitignore

Added info on how to add CIYAM AT JAR to other projects.

Updated pom.xml:
Bumped version to 1.2
Bumped Java version from 1.8 to 11
Bumped BouncyCastle from 1.60 to 1.64

Added more tests.
2019-11-20 11:06:57 +00:00
catbref
f0e031599d Initial upload of Java re-implementation
Note that this is unfinished, requiring fee-per-opcode support
and some refactoring.
2018-09-27 13:59:43 +01:00