Package net.solarnetwork.node.service
Interface LocationService
public interface LocationService
API for managing locations.
- Version:
- 2.1
- Author:
- matt
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionCollection<net.solarnetwork.domain.datum.GeneralLocationSourceMetadata> findLocationMetadata(String query, String sourceId, Set<String> tags) Query for general location metadata.net.solarnetwork.domain.datum.GeneralLocationSourceMetadatagetLocationMetadata(Long locationId, String sourceId) Get a specific general location metadata.net.solarnetwork.domain.LocationGet the node's own location details from SolarNetwork.voidupdateNodeLocation(net.solarnetwork.domain.Location location) Update the node's own location details in SolarNetwork.
-
Field Details
-
UNKNOWN_SOURCE
An unknown source, which is always available.- See Also:
-
UNKNOWN_LOCATION
An unknown location, which is always available for the UNKNOWN source.- See Also:
-
-
Method Details
-
findLocationMetadata
Collection<net.solarnetwork.domain.datum.GeneralLocationSourceMetadata> findLocationMetadata(String query, String sourceId, Set<String> tags) Query for general location metadata.- Parameters:
query- the query textsourceId- an optional source ID to limit the results totags- the optional tags- Returns:
- the matching location metadata, never null
- Since:
- 1.1
-
getLocationMetadata
net.solarnetwork.domain.datum.GeneralLocationSourceMetadata getLocationMetadata(Long locationId, String sourceId) Get a specific general location metadata.- Parameters:
locationId- the location IDsourceId- the source ID- Returns:
- the location metadata, or null if not found
- Since:
- 1.1
-
updateNodeLocation
void updateNodeLocation(net.solarnetwork.domain.Location location) Update the node's own location details in SolarNetwork.This is meant to support updating a node's own GPS coordinates. Other location properties may or may not be supported.
- Parameters:
location- the location details to update- Since:
- 1.2
-
getNodeLocation
net.solarnetwork.domain.Location getNodeLocation()Get the node's own location details from SolarNetwork.- Returns:
- the location, if available
- Since:
- 2.1
-