public class Device extends NameEntityWithVersion
Entity.EntityBuilder<C extends Entity,B extends Entity.EntityBuilder<C,B>>| Modifier and Type | Field and Description |
|---|---|
static String |
A1_PREFIX
The default serial number prefix for aptiv A1 devices.
|
static int |
A1_PRODUCT_ID
The default Product ID for A1 devices.
|
protected LocalDateTime |
activeFrom
The date the device is active from.
|
protected LocalDateTime |
activeTo
The date that the device is active to.
|
protected String |
comment
Free text field where any user information can be stored and referenced for this entity.
|
static int |
CUSTOM_DEVICE_PRODUCT_ID
The default product Id for third-party devices.
|
protected Map<String,Object> |
customFeatures
The custom features for this device and their values.
|
protected List<PropertyValue> |
customProperties
The set of dynamic, user created, custom properties.
|
static Float |
DEFAULT_MAX_NO_LOG_SECONDS |
protected DeviceFlags |
deviceFlags
The device features which have been enabled whether the feature is in use (e.g.
|
protected List<DevicePlanBillingInfo> |
devicePlanBillingInfo
The
DevicePlanBillingInfo that has been purchased for this device. |
protected List<DevicePlan> |
devicePlans
Geotab DevicePlan that has been purchased for this device.
|
protected DeviceType |
deviceType
Specifies the GO or Custom
DeviceType. |
static String |
GO_DRIVE_PREFIX
The default serial number prefix for GoDrive mobile devices.
|
static int |
GO_DRIVE_PRODUCT_ID
The default product Id for GoDrive mobile devices.
|
static int |
GO_MAX_PRODUCT_ID
The maximum Product ID for Go devices.
|
static Map<String,Integer> |
GO_PREFIX_TO_PRODUCT_ID_MAPPING
Prefix to product id mapping.
|
static String |
GO10_PREFIX
The default serial number prefix for Go10 devices.
|
static int |
GO10_PRODUCT_ID
The default Product ID for Go9 devices.
|
static String |
GO2_PREFIX
The default serial number prefix for Go2 devices.
|
static int |
GO2_PRODUCT_ID
The default product Id for Go2 devices.
|
static String |
GO3_PREFIX
The default serial number prefix for Go3 devices.
|
static int |
GO3_PRODUCT_ID
The default product Id for Go3 devices.
|
static String |
GO4_PREFIX
The default serial number prefix for Go4 devices (pre Go4v3).
|
static int |
GO4_PRODUCT_ID
The default product Id for Go4 devices (pre Go4v3).
|
static String |
GO4_V3_PREFIX
The default serial number prefix for Go4v3 devices.
|
static int |
GO4_V3_PRODUCT_ID
The default product Id for Go4v3 devices.
|
static String |
GO5_PREFIX
The default serial number prefix for Go5 devices.
|
static int |
GO5_PRODUCT_ID
The default product Id for Go5 devices.
|
static String |
GO6_PREFIX
The default serial number prefix for Go6 devices.
|
static int |
GO6_PRODUCT_ID
The default Product ID for Go6 devices.
|
static String |
GO7_PREFIX
The default serial number prefix for Go7 devices.
|
static int |
GO7_PRODUCT_ID
The default Product ID for Go7 devices.
|
static String |
GO8_PREFIX
The default serial number prefix for Go8 devices.
|
static int |
GO8_PRODUCT_ID
The default Product ID for Go8 devices.
|
static int |
GO8_PRODUCT_ID_NO_GPS
The default Product ID for Go8 devices without a gps.
|
static String |
GO9_PREFIX
The default serial number prefix for Go9 devices.
|
static int |
GO9_PRODUCT_ID
The default Product ID for Go9 devices.
|
static int |
GO9_PRODUCT_ID_NO_GPS
The default Product ID for Go9 devices without a gps.
|
static String |
GO9B_PREFIX
The default serial number prefix for Go9 devices.
|
static int |
GO9B_PRODUCT_ID
The default Product ID for Go9b devices.
|
protected List<Group> |
groups
The list of
Group(s) the device belongs to. |
static int |
HISTORIC_MAX
The maximum id value for devices that are archived.
|
static int |
HISTORIC_MIN
The minimum id value for devices that are archived.
|
static String |
HISTORIC_SERIAL_NUMBER
The default serial number of historic devices.
|
protected LocalDateTime |
ignoreDownloadsUntil
The date that tells the system at what moment should it start checking the device status and warn if there is no
new data.
|
static LocalDateTime |
MAX_DATE |
protected Float |
maxSecondsBetweenLogs
The maximum allowed time between logs when the ignition is on in seconds.
|
protected List<MediaFile> |
mediaFiles
The list of
MediaFile for this asset. |
static LocalDateTime |
MIN_DATE |
protected Float |
minSecondsBetweenLogs
The minimum allowable value for maxSecondsBetweenLogs.
|
static int |
OLD_GEOTAB_PRODUCT_ID |
protected Integer |
productId
The product id.
|
protected String |
serialNumber
The Serial Number of the device.
|
protected Duration |
timeToDownload
Gets or sets the expected time between downloads, i.e.
|
protected String |
timeZoneId
The IANA time zone Id of the device used to determine local work times.
|
static String |
U1_PREFIX
The default serial number prefix for A1 devices.
|
static int |
U1_PRODUCT_ID
The default Product ID for U1 devices.
|
static int |
UNTRACKED_ASSET_HARDWARE_ID
The default Hardware Id for untracked assets.
|
static int |
UNTRACKED_ASSET_PRODUCT_ID
The default Product ID for untracked assets.
|
protected WorkTime |
workTime
The
WorkTime rules to apply to the device. |
| Constructor and Description |
|---|
Device() |
| Modifier and Type | Method and Description |
|---|---|
static DeviceType |
deviceTypeFromProductId(int productId)
Maps the given productId to a
DeviceType. |
static Device |
fromProductId(int productId)
Get the correct Device object from the given product Id.
|
static Device |
fromSerialNumber(String serialNumber)
Returns the correct type of device for the given serial number.
|
boolean |
isNoGpsDevice()
Determine if a device is NoGps Device by its productId.
|
void |
populateDefaults()
Set default values for the
Device instance. |
static String |
prefixFromDeviceType(int productId)
Returns the string prefix of the given product ID.
|
static int |
productIdFromSerialNumber(String serialNumber)
Returns the product id from its serial number.
|
addExtraProperty, getExtraProperties, isSystemEntitypublic static final Float DEFAULT_MAX_NO_LOG_SECONDS
public static final LocalDateTime MAX_DATE
public static final LocalDateTime MIN_DATE
public static final String HISTORIC_SERIAL_NUMBER
public static final int HISTORIC_MIN
public static final int HISTORIC_MAX
public static final int CUSTOM_DEVICE_PRODUCT_ID
public static final int GO_DRIVE_PRODUCT_ID
public static final String GO_DRIVE_PREFIX
public static final int GO2_PRODUCT_ID
public static final String GO2_PREFIX
public static final int GO3_PRODUCT_ID
public static final String GO3_PREFIX
public static final int GO4_PRODUCT_ID
public static final String GO4_PREFIX
public static final int GO4_V3_PRODUCT_ID
public static final String GO4_V3_PREFIX
public static final int GO5_PRODUCT_ID
public static final String GO5_PREFIX
public static final int GO6_PRODUCT_ID
public static final String GO6_PREFIX
public static final int GO7_PRODUCT_ID
public static final String GO7_PREFIX
public static final int GO8_PRODUCT_ID
public static final String GO8_PREFIX
public static final int GO8_PRODUCT_ID_NO_GPS
public static final int GO9_PRODUCT_ID
public static final String GO9_PREFIX
public static final int GO9B_PRODUCT_ID
public static final String GO9B_PREFIX
public static final int GO10_PRODUCT_ID
public static final String GO10_PREFIX
public static final String A1_PREFIX
public static final int A1_PRODUCT_ID
public static final String U1_PREFIX
public static final int U1_PRODUCT_ID
public static final int GO9_PRODUCT_ID_NO_GPS
public static final int GO_MAX_PRODUCT_ID
public static final int UNTRACKED_ASSET_PRODUCT_ID
public static final int UNTRACKED_ASSET_HARDWARE_ID
public static final int OLD_GEOTAB_PRODUCT_ID
public static final Map<String,Integer> GO_PREFIX_TO_PRODUCT_ID_MAPPING
protected DeviceType deviceType
DeviceType.protected Integer productId
protected String serialNumber
protected LocalDateTime ignoreDownloadsUntil
protected Duration timeToDownload
protected WorkTime workTime
WorkTime rules to apply to the device. Default [WorkTimeStandardHours].protected List<DevicePlan> devicePlans
protected List<DevicePlanBillingInfo> devicePlanBillingInfo
DevicePlanBillingInfo that has been purchased for this device.protected String timeZoneId
protected Float minSecondsBetweenLogs
protected Float maxSecondsBetweenLogs
protected LocalDateTime activeFrom
protected LocalDateTime activeTo
protected String comment
protected DeviceFlags deviceFlags
protected Map<String,Object> customFeatures
CustomFeatures property will be removed completely in a future version of the SDK. CustomFeatures property is only used by AutoHos, for which GoDevice#autoHos property was added. Backward compatibility for CustomFeatures is ensured: autoHos property takes precedence over customFeatures when both are set, otherwise customFeatures.
protected List<PropertyValue> customProperties
public static DeviceType deviceTypeFromProductId(int productId)
DeviceType.productId - The device product Id.DeviceTypepublic static int productIdFromSerialNumber(String serialNumber)
serialNumber - The serial number.public static String prefixFromDeviceType(int productId)
productId - Internal product Id for a serial numberpublic boolean isNoGpsDevice()
public static Device fromSerialNumber(String serialNumber)
serialNumber - The serial number for the device. For example, GV-001-000-0000.Device object that corresponds to the serial number providedpublic void populateDefaults()
Device instance.public static Device fromProductId(int productId)
productId - Product id.Copyright © 2023. All rights reserved.