File tree Expand file tree Collapse file tree
java/org/tron/core/actuator Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11package org .tron .core .actuator ;
22
3- import com .google .common .primitives .Longs ;
43import com .google .protobuf .Any ;
54import com .google .protobuf .ByteString ;
65import com .google .protobuf .InvalidProtocolBufferException ;
1615import org .tron .protos .Contract .ReceiveDescription ;
1716import org .tron .protos .Contract .ShieldedTransferContract ;
1817import org .tron .protos .Contract .SpendDescription ;
18+ import org .tron .protos .Protocol .Transaction .Result .code ;
1919
2020
2121@ Slf4j (topic = "actuator" )
@@ -26,7 +26,32 @@ public class ShieldedTransferActuator extends AbstractActuator {
2626 }
2727
2828 @ Override
29- public boolean execute (TransactionResultCapsule result ) throws ContractExeException {
29+ public boolean execute (TransactionResultCapsule ret )
30+ throws ContractExeException {
31+
32+ long fee = calcFee ();
33+
34+ try {
35+ ShieldedTransferContract strx = contract .unpack (ShieldedTransferContract .class );
36+ } catch (InvalidProtocolBufferException e ) {
37+ logger .debug (e .getMessage (), e );
38+ ret .setStatus (fee , code .FAILED );
39+ throw new ContractExeException (e .getMessage ());
40+ }
41+
42+ return false ;
43+ }
44+
45+ private boolean executeTransparentIn () {
46+
47+ return false ;
48+ }
49+
50+ private boolean executeTransparentOut () {
51+ return false ;
52+ }
53+
54+ private boolean executeShielded () {
3055 return false ;
3156 }
3257
Original file line number Diff line number Diff line change @@ -392,12 +392,12 @@ message ReceiveDescription {
392392
393393message ShieldedTransferContract {
394394 bytes transparent_from_address = 1 ; // transparent address
395- bytes from_amount = 2 ;
395+ int64 from_amount = 2 ;
396396 repeated SpendDescription spend_description = 3 ;
397397 repeated ReceiveDescription receive_description = 4 ;
398398 bytes binding_signature = 5 ;
399399 int64 value_balance = 6 ;
400400 bytes transparent_to_address = 7 ; // transparent address
401- bytes to_amount = 8 ; // the amount to transparent to_address
401+ int64 to_amount = 8 ; // the amount to transparent to_address
402402}
403403// end shielded transaction
You can’t perform that action at this time.
0 commit comments