Package net.solarnetwork.domain.datum
Class BasicObjectDatumStreamMetadata
java.lang.Object
net.solarnetwork.domain.datum.BasicDatumStreamMetadata
net.solarnetwork.domain.datum.BasicObjectDatumStreamMetadata
- All Implemented Interfaces:
Serializable,DatumStreamMetadata,ObjectDatumStreamMetadata
public class BasicObjectDatumStreamMetadata
extends BasicDatumStreamMetadata
implements ObjectDatumStreamMetadata
Basic implementation of
ObjectDatumStreamMetadata.- Since:
- 1.72
- Version:
- 1.0
- Author:
- matt
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionBasicObjectDatumStreamMetadata(UUID streamId, String timeZoneId, ObjectDatumKind kind, Long objectId, String sourceId, String[] instantaneousProperties, String[] accumulatingProperties, String[] statusProperties) Constructor.BasicObjectDatumStreamMetadata(UUID streamId, String timeZoneId, ObjectDatumKind kind, Long objectId, String sourceId, String[] instantaneousProperties, String[] accumulatingProperties, String[] statusProperties, String metaJson) Constructor.BasicObjectDatumStreamMetadata(UUID streamId, String timeZoneId, ObjectDatumKind kind, Long objectId, String sourceId, Location location, String[] instantaneousProperties, String[] accumulatingProperties, String[] statusProperties, String metaJson) Constructor. -
Method Summary
Methods inherited from class net.solarnetwork.domain.datum.BasicDatumStreamMetadata
getAccumulatingLength, getInstantaneousLength, getPropertyNames, getPropertyNamesLength, getStatusLength, getStreamId, getTimeZoneId, propertyNamesForTypeMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.solarnetwork.domain.datum.DatumStreamMetadata
getPropertyNames, getStreamId, getTimeZoneId, propertyIndex, propertyNamesForType
-
Constructor Details
-
BasicObjectDatumStreamMetadata
public BasicObjectDatumStreamMetadata(UUID streamId, String timeZoneId, ObjectDatumKind kind, Long objectId, String sourceId, String[] instantaneousProperties, String[] accumulatingProperties, String[] statusProperties) Constructor.All arguments except
streamId,objectId, andsourceIdare allowed to be null. If any array is empty, it will be treated as if it were null.- Parameters:
streamId- the stream IDtimeZoneId- the time zone IDkind- the object kindobjectId- the object IDsourceId- the source IDinstantaneousProperties- the instantaneous property namesaccumulatingProperties- the accumulating property namesstatusProperties- the status property names- Throws:
IllegalArgumentException- ifstreamIdorobjectIdorsourceIdis null
-
BasicObjectDatumStreamMetadata
public BasicObjectDatumStreamMetadata(UUID streamId, String timeZoneId, ObjectDatumKind kind, Long objectId, String sourceId, String[] instantaneousProperties, String[] accumulatingProperties, String[] statusProperties, String metaJson) Constructor.All arguments except
streamId,objectId, andsourceIdare allowed to be null. If any array is empty, it will be treated as if it were null.- Parameters:
streamId- the stream IDtimeZoneId- the time zone IDkind- the object kindobjectId- the object IDsourceId- the source IDinstantaneousProperties- the instantaneous property namesaccumulatingProperties- the accumulating property namesstatusProperties- the status property namesmetaJson- the JSON metadata- Throws:
IllegalArgumentException- ifstreamIdorobjectIdorsourceIdis null
-
BasicObjectDatumStreamMetadata
public BasicObjectDatumStreamMetadata(UUID streamId, String timeZoneId, ObjectDatumKind kind, Long objectId, String sourceId, Location location, String[] instantaneousProperties, String[] accumulatingProperties, String[] statusProperties, String metaJson) Constructor.All arguments except
streamId,objectId, andsourceIdare allowed to be null. If any array is empty, it will be treated as if it were null.- Parameters:
streamId- the stream IDtimeZoneId- the time zone IDkind- the object kindobjectId- the object IDsourceId- the source IDlocation- the locationinstantaneousProperties- the instantaneous property namesaccumulatingProperties- the accumulating property namesstatusProperties- the status property namesmetaJson- the JSON metadata- Throws:
IllegalArgumentException- ifstreamIdorobjectIdorsourceIdis null
-
-
Method Details
-
emptyMeta
public static BasicObjectDatumStreamMetadata emptyMeta(UUID streamId, String timeZoneId, ObjectDatumKind kind, Long objectId, String sourceId) Create a new metadata instance with no property names.- Parameters:
streamId- the stream IDtimeZoneId- the time zone IDkind- the object kindobjectId- the object IDsourceId- the source ID- Returns:
- the new instance
-
toString
-
hashCode
public int hashCode()- Overrides:
hashCodein classBasicDatumStreamMetadata
-
equals
- Overrides:
equalsin classBasicDatumStreamMetadata
-
getObjectId
Description copied from interface:ObjectDatumStreamMetadataGet the object ID.- Specified by:
getObjectIdin interfaceObjectDatumStreamMetadata- Returns:
- the object ID
-
getSourceId
Description copied from interface:ObjectDatumStreamMetadataGet the source ID.- Specified by:
getSourceIdin interfaceObjectDatumStreamMetadata- Returns:
- the source ID
-
getMetaJson
Description copied from interface:ObjectDatumStreamMetadataGet the optional custom JSON metadata.- Specified by:
getMetaJsonin interfaceObjectDatumStreamMetadata- Returns:
- the JSON metadata
-
getKind
Description copied from interface:ObjectDatumStreamMetadataGet the object datum kind.- Specified by:
getKindin interfaceObjectDatumStreamMetadata- Returns:
- the kind
-
getLocation
Description copied from interface:ObjectDatumStreamMetadataGet the object location.- Specified by:
getLocationin interfaceObjectDatumStreamMetadata- Returns:
- the location
-