Class DeviceRegistrationImpl
java.lang.Object
com.flowable.engage.engine.impl.notification.push.DeviceRegistrationImpl
- All Implemented Interfaces:
DeviceRegistration
public class DeviceRegistrationImpl extends java.lang.Object implements DeviceRegistration
- Author:
- Filip Hrisafov
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
applicationId
protected java.lang.String
deviceOS
protected DeviceServiceImpl
deviceService
protected boolean
enabled
protected java.lang.String
tenantId
protected java.lang.String
token
protected java.lang.String
tokenEncoding
protected java.lang.String
userId
-
Constructor Summary
Constructors Constructor Description DeviceRegistrationImpl(DeviceServiceImpl deviceService)
-
Method Summary
Modifier and Type Method Description DeviceRegistration
applicationId(java.lang.String applicationId)
The id of the application that this device is registered for.DeviceRegistration
deviceOS(java.lang.String deviceOS)
The OS of the device.DeviceRegistration
disabled()
Register a disabled device.java.lang.String
getApplicationId()
java.lang.String
getDeviceOS()
java.lang.String
getTenantId()
java.lang.String
getToken()
java.lang.String
getTokenEncoding()
java.lang.String
getUserId()
boolean
isEnabled()
Device
register()
Perform the registration of the device.DeviceRegistration
tenantId(java.lang.String tenantId)
The id of the tenant in which this device is registered in.DeviceRegistration
token(java.lang.String token)
The token for the new device.DeviceRegistration
tokenEncoding(java.lang.String tokenEncoding)
The encoding of the token.DeviceRegistration
userId(java.lang.String userId)
The id of the user that this device is registered to.
-
Field Details
-
deviceService
-
token
protected java.lang.String token -
tokenEncoding
protected java.lang.String tokenEncoding -
enabled
protected boolean enabled -
deviceOS
protected java.lang.String deviceOS -
userId
protected java.lang.String userId -
applicationId
protected java.lang.String applicationId -
tenantId
protected java.lang.String tenantId
-
-
Constructor Details
-
Method Details
-
token
Description copied from interface:DeviceRegistration
The token for the new device. This is a mandatory field.- Specified by:
token
in interfaceDeviceRegistration
- Parameters:
token
- the token
-
tokenEncoding
Description copied from interface:DeviceRegistration
The encoding of the token. By default it isnone
.- Specified by:
tokenEncoding
in interfaceDeviceRegistration
- Parameters:
tokenEncoding
- the encoding of the token- See Also:
DeviceTokenEncodings
-
disabled
Description copied from interface:DeviceRegistration
Register a disabled device. By default an enabled device is registered.- Specified by:
disabled
in interfaceDeviceRegistration
-
deviceOS
Description copied from interface:DeviceRegistration
The OS of the device. This is a mandatory field.- Specified by:
deviceOS
in interfaceDeviceRegistration
- Parameters:
deviceOS
- the OS device- See Also:
DeviceOS
-
userId
Description copied from interface:DeviceRegistration
The id of the user that this device is registered to.- Specified by:
userId
in interfaceDeviceRegistration
- Parameters:
userId
- the id of the user
-
applicationId
Description copied from interface:DeviceRegistration
The id of the application that this device is registered for.- Specified by:
applicationId
in interfaceDeviceRegistration
- Parameters:
applicationId
- the id of the application
-
tenantId
Description copied from interface:DeviceRegistration
The id of the tenant in which this device is registered in.- Specified by:
tenantId
in interfaceDeviceRegistration
- Parameters:
tenantId
- the tenant id
-
register
Description copied from interface:DeviceRegistration
Perform the registration of the device. Make sure that the mandatory fieldsDeviceRegistration.token(String)
andDeviceRegistration.deviceOS(String)
have been set.- Specified by:
register
in interfaceDeviceRegistration
- Returns:
- the newly registered device
-
getToken
public java.lang.String getToken() -
getTokenEncoding
public java.lang.String getTokenEncoding() -
isEnabled
public boolean isEnabled() -
getDeviceOS
public java.lang.String getDeviceOS() -
getUserId
public java.lang.String getUserId() -
getApplicationId
public java.lang.String getApplicationId() -
getTenantId
public java.lang.String getTenantId()
-