Class DistanceDemo

java.lang.Object
dk.alexandra.fresco.demo.DistanceDemo
All Implemented Interfaces:
dk.alexandra.fresco.framework.Application<BigInteger,dk.alexandra.fresco.framework.builder.numeric.ProtocolBuilderNumeric>, dk.alexandra.fresco.framework.builder.Computation<BigInteger,dk.alexandra.fresco.framework.builder.numeric.ProtocolBuilderNumeric>

public class DistanceDemo extends Object implements dk.alexandra.fresco.framework.Application<BigInteger,dk.alexandra.fresco.framework.builder.numeric.ProtocolBuilderNumeric>
A simple demo computing the distance between two secret points.
  • Constructor Summary

    Constructors
    Constructor
    Description
    DistanceDemo(int id, int x, int y)
    Construct a new DistanceDemo.
  • Method Summary

    Modifier and Type
    Method
    Description
    dk.alexandra.fresco.framework.DRes<BigInteger>
    buildComputation(dk.alexandra.fresco.framework.builder.numeric.ProtocolBuilderNumeric producer)
     
    static <ResourcePoolT extends dk.alexandra.fresco.framework.sce.resources.ResourcePool>
    void
    main(String[] args)
    Main method for DistanceDemo.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface dk.alexandra.fresco.framework.Application

    close
  • Constructor Details

    • DistanceDemo

      public DistanceDemo(int id, int x, int y)
      Construct a new DistanceDemo.
      Parameters:
      id - The party id
      x - The x coordinate
      y - The y coordinate
  • Method Details

    • buildComputation

      public dk.alexandra.fresco.framework.DRes<BigInteger> buildComputation(dk.alexandra.fresco.framework.builder.numeric.ProtocolBuilderNumeric producer)
      Specified by:
      buildComputation in interface dk.alexandra.fresco.framework.builder.Computation<BigInteger,dk.alexandra.fresco.framework.builder.numeric.ProtocolBuilderNumeric>
    • main

      public static <ResourcePoolT extends dk.alexandra.fresco.framework.sce.resources.ResourcePool> void main(String[] args) throws IOException
      Main method for DistanceDemo.
      Parameters:
      args - Arguments for the application
      Throws:
      IOException - In case of network problems