public interface PhoneServiceLocal extends PhoneService, org.cyclos.impl.CRUDServiceLocal<Phone,PhoneDTO,PhoneData,PhoneDataParams>
| Modifier and Type | Method and Description |
|---|---|
void |
appendValidations(Property<?,?> parentProperty,
org.cyclos.impl.utils.validation.Validator validator,
PhoneDTO dto,
Group group,
PhoneNature nature)
Appends phone validations to the given validator
|
boolean |
canManagePhones(User user)
Returns if the logged user can manage the user phones
|
boolean |
canSetPrivate(User user)
Returns true if the logged user can change the private setting of the given users' phones
|
Phone |
getDefaultPhone(PhoneNature type,
User user)
Returns the default phone (landline or mobile) for the given user, or null if none found
|
boolean |
isVerificationCodeSentAndNotExpired(MobilePhone mobile)
Returns whether there is a valid verification code sent for the given mobile phone
|
java.util.List<Phone> |
listByUser(User user)
Returns the visible phones of the given user.
|
Phone |
loadByRawNumber(User user,
java.lang.String rawNumber)
Loads a given user's number by its raw number
|
java.lang.String |
normalizeNumber(ConfigurationAccessor configuration,
java.lang.String rawNumber)
Normalizes a phone number for the given configuration
|
void |
verifyAndEnableForSms(MobilePhone phone)
Marks the given phone as verified and enabled for SMS
|
getPhoneListData, markAsEnabledForSms, sendVerificationCode, verifyfind, findAll, getEntityClass, newEntity, remove, removeAll, toDTO, toEntity, validategetData, getDataForNew, load, remove, removeAll, savevoid appendValidations(Property<?,?> parentProperty, org.cyclos.impl.utils.validation.Validator validator, PhoneDTO dto, Group group, PhoneNature nature) throws FrameworkException
FrameworkExceptionboolean canManagePhones(User user)
boolean canSetPrivate(User user)
Phone getDefaultPhone(PhoneNature type, User user) throws FrameworkException
FrameworkExceptionboolean isVerificationCodeSentAndNotExpired(MobilePhone mobile)
java.util.List<Phone> listByUser(User user) throws FrameworkException
FrameworkExceptionPhone loadByRawNumber(User user, java.lang.String rawNumber)
java.lang.String normalizeNumber(ConfigurationAccessor configuration, java.lang.String rawNumber) throws FrameworkException
FrameworkExceptionvoid verifyAndEnableForSms(MobilePhone phone) throws FrameworkException
FrameworkException