Package net.solarnetwork.service
Interface DatumFilterService
- All Superinterfaces:
Identifiable
A service API for transforming and filtering datum samples.
- Since:
- 2.0
- Version:
- 1.0
- Author:
- matt
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringA parameter key signaling the transform is for testing purposes only, and as such should not have any persistent side-effects.Fields inherited from interface net.solarnetwork.service.Identifiable
GROUP_UID_PROPERTY, UID_PROPERTY -
Method Summary
Modifier and TypeMethodDescriptionTransform a samples instance.default StringGet a description of this transformer.Methods inherited from interface net.solarnetwork.service.Identifiable
getDisplayName, getGroupUid, getUid
-
Field Details
-
PARAM_TEST_ONLY
A parameter key signaling the transform is for testing purposes only, and as such should not have any persistent side-effects.The mere presence of this parameter should be treated as testing mode should be used. The parameter value can be anything.
- See Also:
-
-
Method Details
-
filter
DatumSamplesOperations filter(Datum datum, DatumSamplesOperations samples, Map<String, Object> parameters) Transform a samples instance.Generally this method is not meant to make changes to the passed in
samplesinstance. Rather it should apply changes to a copy ofsamplesand return the copy. If no changes are necessary then thesamplesinstance may be returned.This method may also return null to indicate the
samplesinstance should not be processed, or that there is essentially no data to associate with this particulardatum.- Parameters:
datum- the datum associated withsamplessamples- the samples object to transformparameters- optional implementation-specific parameters to pass to the transformer- Returns:
- the transformed samples instance, which may be the
samplesinstance or a new instance, or null to indicate the samples should be discarded
-
getDescription
Get a description of this transformer.This method should return a meaningful description of this service, suitable for users to see.
- Returns:
- a friendly description
-