Class Interactions
- java.lang.Object
-
- io.heraldprox.herald.sensor.DefaultSensorDelegate
-
- io.heraldprox.herald.sensor.analysis.Interactions
-
- All Implemented Interfaces:
SensorDelegate
- Direct Known Subclasses:
SocialDistance
public class Interactions extends DefaultSensorDelegate
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Interactions.InteractionsForTarget
static class
Interactions.InteractionsForTime
-
Constructor Summary
Constructors Constructor Description Interactions()
Interactions(android.content.Context context, java.lang.String filename)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
append(Encounter encounter)
static java.util.Map<java.lang.Double,TimeInterval>
reduceByProximity(java.util.List<Encounter> encounters)
static java.util.Map<java.lang.Double,TimeInterval>
reduceByProximity(java.util.List<Encounter> encounters, ProximityMeasurementUnit unit, java.lang.Double bin)
static java.util.Map<PayloadData,Interactions.InteractionsForTarget>
reduceByTarget(java.util.List<Encounter> encounters)
static java.util.List<Interactions.InteractionsForTime>
reduceByTime(java.util.List<Encounter> encounters)
static java.util.List<Interactions.InteractionsForTime>
reduceByTime(java.util.List<Encounter> encounters, TimeInterval duration)
void
remove(java.util.Date before)
void
sensor(SensorType sensor, Proximity didMeasure, TargetIdentifier fromTarget, PayloadData withPayload)
Measure proximity to target with payload data.java.util.List<Encounter>
subdata(java.util.Date start)
java.util.List<Encounter>
subdata(java.util.Date start, java.util.Date end)
-
-
-
Method Detail
-
append
public void append(@NonNull Encounter encounter)
-
subdata
@NonNull public java.util.List<Encounter> subdata(@NonNull java.util.Date start, @NonNull java.util.Date end)
-
subdata
@NonNull public java.util.List<Encounter> subdata(@NonNull java.util.Date start)
-
remove
public void remove(@NonNull java.util.Date before)
-
sensor
public void sensor(@NonNull SensorType sensor, @NonNull Proximity didMeasure, @NonNull TargetIdentifier fromTarget, @NonNull PayloadData withPayload)
Description copied from interface:SensorDelegate
Measure proximity to target with payload data. Combines didMeasure and didRead into a single convenient delegate method- Specified by:
sensor
in interfaceSensorDelegate
- Overrides:
sensor
in classDefaultSensorDelegate
-
reduceByTime
@NonNull public static java.util.List<Interactions.InteractionsForTime> reduceByTime(@NonNull java.util.List<Encounter> encounters)
-
reduceByTime
@NonNull public static java.util.List<Interactions.InteractionsForTime> reduceByTime(@NonNull java.util.List<Encounter> encounters, @NonNull TimeInterval duration)
-
reduceByTarget
@NonNull public static java.util.Map<PayloadData,Interactions.InteractionsForTarget> reduceByTarget(@NonNull java.util.List<Encounter> encounters)
-
reduceByProximity
@NonNull public static java.util.Map<java.lang.Double,TimeInterval> reduceByProximity(@NonNull java.util.List<Encounter> encounters)
-
reduceByProximity
@NonNull public static java.util.Map<java.lang.Double,TimeInterval> reduceByProximity(@NonNull java.util.List<Encounter> encounters, @NonNull ProximityMeasurementUnit unit, @NonNull java.lang.Double bin)
-
-