Skip to content

Commit

Permalink
Handled minor review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
jot2re committed Jan 24, 2018
1 parent 0515efa commit faa7e12
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* Superclass containing the common methods for the sender and
* receiver parties of correlated OT with errors.
*/
public class CoteShared {
public abstract class CoteShared {
private final int instanceId;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* Superclass containing the common variables and methods for the sender and
* receiver parties of random OT extension.
*/
public class RotSharedImpl {
public abstract class RotSharedImpl {
private final CoinTossing ct;
private final int comSecParam;
private final MessageDigest digest;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,16 @@
*/
public class Transpose {

private Transpose() {
/**
* This class is meant to only contain static helper methods.
*/
}

/**
* Transposes, in-place, a matrix represent in row-major as a list of byte
* arrays.
*
*
* @param input
* The matrix to transpose
*/
Expand Down Expand Up @@ -78,7 +84,7 @@ public static List<StrictBitVector> transpose(List<StrictBitVector> input) {
/**
* Complete the Eklundh algorithm for transposing with initial blocks of 8
* bits. That is, assuming all blocks of 8 bits have already been transposed
*
*
* @param input
* The matrix to transpose. Represented in row-major
*/
Expand All @@ -100,7 +106,7 @@ private static void doEklundh(List<byte[]> input) {

/**
* Swaps the content of two square blocks, in-place.
*
*
* @param input
* The list of arrays of which to swap
* @param row
Expand All @@ -124,7 +130,7 @@ private static void swap(List<byte[]> input, int row, int column,

/**
* Check that a matrix obeys the rules needed to do Eklundh transposing.
*
*
* @param input
* The matrix to check
*/
Expand Down Expand Up @@ -152,7 +158,7 @@ private static void doSanityCheck(List<StrictBitVector> input) {

/**
* Transpose all 8 bit squares in a square matrix, in-place.
*
*
* @param input
* The input
*/
Expand All @@ -169,7 +175,7 @@ private static void transposeAllByteBlocks(List<byte[]> input) {
/**
* Transposes 8x8 bit blocks of a row-major matrix, at positions "rowOffset",
* "columnOffset".
*
*
* @param input
* The matrix to transpose
* @param rowOffset
Expand Down Expand Up @@ -221,7 +227,7 @@ private static void transposeByteBlock(List<byte[]> input, int rowOffset,

/**
* Allocate a matrix in row-major form, as a list of byte arrays.
*
*
* @param rows
* Rows in the matrix
* @param columns
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,6 @@ public void testSquareMatrix() {
assertEquals(false, thrown);
}

@Test
public void testNewTranspose() {
// Verify that it is possible to construct a Transpose object
new Transpose();
}

@Test
public void testBigMatrix() {
boolean thrown = false;
Expand Down

0 comments on commit faa7e12

Please sign in to comment.