Search in sources :

Example 1 with DatumSamples

use of net.solarnetwork.domain.datum.DatumSamples in project solarnetwork-node by SolarNetwork.

the class SimplePriceDatum method copyWithSamples.

@Override
public SimplePriceDatum copyWithSamples(DatumSamplesOperations samples) {
    DatumSamples newSamples = new DatumSamples();
    newSamples.copyFrom(samples);
    return new SimplePriceDatum(getId(), newSamples);
}
Also used : DatumSamples(net.solarnetwork.domain.datum.DatumSamples)

Example 2 with DatumSamples

use of net.solarnetwork.domain.datum.DatumSamples in project solarnetwork-node by SolarNetwork.

the class SimpleAtmosphericDatum method copyWithSamples.

@Override
public SimpleAtmosphericDatum copyWithSamples(DatumSamplesOperations samples) {
    DatumSamples newSamples = new DatumSamples();
    newSamples.copyFrom(samples);
    return new SimpleAtmosphericDatum(getId(), newSamples);
}
Also used : DatumSamples(net.solarnetwork.domain.datum.DatumSamples)

Example 3 with DatumSamples

use of net.solarnetwork.domain.datum.DatumSamples in project solarnetwork-node by SolarNetwork.

the class SimpleDatum method copyWithSamples.

@Override
public SimpleDatum copyWithSamples(DatumSamplesOperations samples) {
    SimpleDatum d = new SimpleDatum(getId(), new DatumSamples(samples));
    d.uploaded = this.uploaded;
    return d;
}
Also used : DatumSamples(net.solarnetwork.domain.datum.DatumSamples)

Example 4 with DatumSamples

use of net.solarnetwork.domain.datum.DatumSamples in project solarnetwork-node by SolarNetwork.

the class SimpleDcEnergyDatum method copyWithSamples.

@Override
public SimpleDcEnergyDatum copyWithSamples(DatumSamplesOperations samples) {
    DatumSamples newSamples = new DatumSamples();
    newSamples.copyFrom(samples);
    return new SimpleDcEnergyDatum(getId(), newSamples);
}
Also used : DatumSamples(net.solarnetwork.domain.datum.DatumSamples)

Example 5 with DatumSamples

use of net.solarnetwork.domain.datum.DatumSamples in project solarnetwork-node by SolarNetwork.

the class SimpleEnergyDatum method copyWithSamples.

@Override
public SimpleEnergyDatum copyWithSamples(DatumSamplesOperations samples) {
    DatumSamples newSamples = new DatumSamples();
    newSamples.copyFrom(samples);
    return new SimpleEnergyDatum(getId(), newSamples);
}
Also used : DatumSamples(net.solarnetwork.domain.datum.DatumSamples)

Aggregations

DatumSamples (net.solarnetwork.domain.datum.DatumSamples)205 Test (org.junit.Test)120 SimpleDatum (net.solarnetwork.node.domain.datum.SimpleDatum)74 NodeDatum (net.solarnetwork.node.domain.datum.NodeDatum)42 GeneralNodeDatum (net.solarnetwork.central.datum.domain.GeneralNodeDatum)33 Instant (java.time.Instant)30 Event (org.osgi.service.event.Event)28 BigDecimal (java.math.BigDecimal)26 ArrayList (java.util.ArrayList)25 DatumSamplesOperations (net.solarnetwork.domain.datum.DatumSamplesOperations)19 SimpleAcEnergyDatum (net.solarnetwork.node.domain.datum.SimpleAcEnergyDatum)12 Capture (org.easymock.Capture)12 DatumAuxiliaryEntity (net.solarnetwork.central.datum.v2.dao.DatumAuxiliaryEntity)11 GeneralLocationDatum (net.solarnetwork.central.datum.domain.GeneralLocationDatum)10 MqttMessage (net.solarnetwork.common.mqtt.MqttMessage)10 DatumHistory (net.solarnetwork.node.runtime.DatumHistory)10 HashMap (java.util.HashMap)9 UUID (java.util.UUID)9 GeneralDatumMetadata (net.solarnetwork.domain.datum.GeneralDatumMetadata)9 CanbusMessageConfig (net.solarnetwork.node.datum.canbus.CanbusMessageConfig)9