From abb1ad8956c214c17d71573b94cdc3bb0e5beb88 Mon Sep 17 00:00:00 2001 From: Chris Beams Date: Sat, 27 Dec 2014 14:39:35 +0100 Subject: [PATCH] Fix remaining javadoc warnings As of this commit there are now warnings at the command line when running `gradle javadoc`. --- .../ethereum/core/TransactionExecutor.java | 9 ++----- .../main/java/org/ethereum/core/Wallet.java | 19 +++++++------- .../java/org/ethereum/facade/Ethereum.java | 11 +++----- .../org/ethereum/serpent/SerpentCompiler.java | 4 +-- .../serpent/SerpentToAssemblyCompiler.java | 1 - .../main/java/org/ethereum/trie/TrieImpl.java | 26 +++++-------------- .../main/java/org/ethereum/vm/Program.java | 12 +++------ .../org/ethereum/vmtrace/ProgramTrace.java | 4 +-- 8 files changed, 27 insertions(+), 59 deletions(-) diff --git a/ethereumj-core/src/main/java/org/ethereum/core/TransactionExecutor.java b/ethereumj-core/src/main/java/org/ethereum/core/TransactionExecutor.java index be739785..601de85b 100644 --- a/ethereumj-core/src/main/java/org/ethereum/core/TransactionExecutor.java +++ b/ethereumj-core/src/main/java/org/ethereum/core/TransactionExecutor.java @@ -225,13 +225,8 @@ public class TransactionExecutor { } /** - * After any contract code finish the run the certain result should take - * place, according the given circumstances - * - * @param result - * @param gasDebit - * @param senderAddress - * @param contractAddress + * After any contract code finish the run the certain result should take place, + * according to the given circumstances. */ private void applyProgramResult(ProgramResult result, BigInteger gasDebit, BigInteger gasPrice, Repository repository, byte[] senderAddress, diff --git a/ethereumj-core/src/main/java/org/ethereum/core/Wallet.java b/ethereumj-core/src/main/java/org/ethereum/core/Wallet.java index 68dce260..c4853c39 100644 --- a/ethereumj-core/src/main/java/org/ethereum/core/Wallet.java +++ b/ethereumj-core/src/main/java/org/ethereum/core/Wallet.java @@ -120,10 +120,7 @@ public class Wallet { /** * The wallet will call this method once transaction been send to the network, * once the the GET_TRANSACTION will be answered with that particular transaction - * it will be considered as received by the net - * - * @param transaction - * @return + * it will be considered as received by the net. */ public WalletTransaction addByWalletTransaction(Transaction transaction) { String hash = Hex.toHexString(transaction.getHash()); @@ -133,12 +130,14 @@ public class Wallet { return walletTransaction; } - /*********************************************************************** - * 1) the dialog put a pending transaction on the list - * 2) the dialog send the transaction to a net - * 3) wherever the transaction got in from the wire it will change to approve state - * 4) only after the approve a) Wallet state changes - * 5) After the block is received with that tx the pending been clean up + /** + *
    + *
  1. the dialog put a pending transaction on the list + *
  2. the dialog send the transaction to a net + *
  3. wherever the transaction got in from the wire it will change to approve state + *
  4. only after the approve a) Wallet state changes + *
  5. after the block is received with that tx the pending been clean up + *
*/ public WalletTransaction addTransaction(Transaction transaction) { String hash = Hex.toHexString(transaction.getHash()); diff --git a/ethereumj-core/src/main/java/org/ethereum/facade/Ethereum.java b/ethereumj-core/src/main/java/org/ethereum/facade/Ethereum.java index 5c9e186d..6cea7fb4 100644 --- a/ethereumj-core/src/main/java/org/ethereum/facade/Ethereum.java +++ b/ethereumj-core/src/main/java/org/ethereum/facade/Ethereum.java @@ -106,13 +106,10 @@ public interface Ethereum { BigInteger value, byte[] data); - /** - * - * @param transaction - submit transaction to the net, return - * option to wait for net return this transaction - * as approved - * @return - */ + /** + * @param transaction submit transaction to the net, return option to wait for net + * return this transaction as approved + */ public Future submitTransaction(Transaction transaction); diff --git a/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentCompiler.java b/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentCompiler.java index d6bb0dad..1cd5dd21 100644 --- a/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentCompiler.java +++ b/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentCompiler.java @@ -197,9 +197,7 @@ public class SerpentCompiler { } /** - * @param code - * @param init - * @return encoded bytes + * Return encoded bytes. */ public static byte[] encodeMachineCodeForVMRun(byte[] code, byte[] init) { diff --git a/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentToAssemblyCompiler.java b/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentToAssemblyCompiler.java index 596054e5..cf7e1dc3 100644 --- a/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentToAssemblyCompiler.java +++ b/ethereumj-core/src/main/java/org/ethereum/serpent/SerpentToAssemblyCompiler.java @@ -713,7 +713,6 @@ public class SerpentToAssemblyCompiler extends SerpentBaseVisitor { /** * @param hexNum should be in form '0x34fabd34....' - * @return */ private String hexStringToDecimalString(String hexNum) { String digits = hexNum.substring(2); diff --git a/ethereumj-core/src/main/java/org/ethereum/trie/TrieImpl.java b/ethereumj-core/src/main/java/org/ethereum/trie/TrieImpl.java index 97026eef..d9717346 100644 --- a/ethereumj-core/src/main/java/org/ethereum/trie/TrieImpl.java +++ b/ethereumj-core/src/main/java/org/ethereum/trie/TrieImpl.java @@ -94,10 +94,7 @@ public class TrieImpl implements Trie { **************************************/ /** - * Retrieve a value from a key as String - * - * @param key - * @return value + * Retrieve a value from a key as String. */ public byte[] get(String key) { return this.get(key.getBytes()); @@ -114,10 +111,7 @@ public class TrieImpl implements Trie { } /** - * Insert key/value pair into trie - * - * @param key - * @param value + * Insert key/value pair into trie. */ public void update(String key, String value) { this.update(key.getBytes(), value.getBytes()); @@ -137,9 +131,7 @@ public class TrieImpl implements Trie { } /** - * Delete a key/value pair from the trie - * - * @param key + * Delete a key/value pair from the trie. */ public void delete(String key) { this.update(key.getBytes(), "".getBytes()); @@ -207,8 +199,8 @@ public class TrieImpl implements Trie { } /** - * Update or add the item inside a node - * return the updated node with rlp encoded + * Update or add the item inside a node. + * @return the updated node with rlp encoded */ private Object insert(Object node, byte[] key, Object value) { @@ -345,12 +337,8 @@ public class TrieImpl implements Trie { } /** - * Helper method to retrieve the actual node - * If the node is not a list and length is > 32 - * bytes get the actual node from the db - * - * @param node - - * @return + * Helper method to retrieve the actual node. If the node is not a list and length + * is > 32 bytes get the actual node from the db. */ private Value getNode(Object node) { diff --git a/ethereumj-core/src/main/java/org/ethereum/vm/Program.java b/ethereumj-core/src/main/java/org/ethereum/vm/Program.java index 593250fa..4fdb11be 100644 --- a/ethereumj-core/src/main/java/org/ethereum/vm/Program.java +++ b/ethereumj-core/src/main/java/org/ethereum/vm/Program.java @@ -90,27 +90,21 @@ public class Program { } /** - * Last Op can only be set publicly (no getLastOp method), is used for logging - * - * @param op + * Last Op can only be set publicly (no getLastOp method), is used for logging. */ public void setLastOp(byte op) { this.lastOp = op; } /** - * Should be set only after the OP is fully executed - * - * @param op + * Should be set only after the OP is fully executed. */ public void setPreviouslyExecutedOp(byte op) { this.previouslyExecutedOp = op; } /** - * returns the last fully executed OP - * - * @return + * Returns the last fully executed OP. */ public byte getPreviouslyExecutedOp() { return this.previouslyExecutedOp; diff --git a/ethereumj-core/src/main/java/org/ethereum/vmtrace/ProgramTrace.java b/ethereumj-core/src/main/java/org/ethereum/vmtrace/ProgramTrace.java index 801783e1..25f4e8d7 100644 --- a/ethereumj-core/src/main/java/org/ethereum/vmtrace/ProgramTrace.java +++ b/ethereumj-core/src/main/java/org/ethereum/vmtrace/ProgramTrace.java @@ -23,9 +23,7 @@ public class ProgramTrace { } /** - * used for merging sub calls execution - * - * @param programTrace + * Used for merging sub calls execution. */ public void merge(ProgramTrace programTrace) {