Commit c5beb3fb authored by Clemens Krug's avatar Clemens Krug
Browse files

Basic Server/Client implementation

+ Added a server
+ Basic communication protocol
+ Basic attraction point
parent 162b0813
package de.tud.kom.p2psim.impl.topology.movement.modularosm.attraction;
import de.tud.kom.p2psim.impl.topology.PositionVector;
import de.tudarmstadt.maki.simonstrator.api.component.sensor.location.AttractionPoint;
/**
* A basic attraction point, as simple as it can get. Really just a named location
* without any checks performed.
*/
public class BasicAttractionPoint extends PositionVector implements AttractionPoint
{
private String name;
private double weight = 0;
private double radius = 0;
public BasicAttractionPoint(String name, PositionVector pos)
{
super(pos);
this.name = name;
}
@Override
public String getName() {
return name;
}
@Override
public double getWeight() {
return weight;
}
@Override
public double getRadius() {
return radius;
}
@Override
public void setWeight(double weight) {
this.weight = weight;
}
@Override
public void setRadius(double radius) {
this.radius = radius;
}
@Override
public AttractionPoint clone(String newName) {
return new BasicAttractionPoint(newName, this);
}
}
......@@ -36,7 +36,6 @@ public class ManualAssignmentStrategy implements ITransitionStrategy
@Override
public void reachedAttractionPoint(SimLocationActuator ms) {
}
@Override
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment