Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- switch(attributeName)
- {
- case {attributeName} :
- log.info("Currently switching on value... ${attributeName}")
- case user.getFirstNameMapping():
- model.user.userInfo.firstName = attributeValue
- break
- case user.getLastNameMapping():
- model.user.userInfo.lastName = attributeValue
- break
- case user.getAuthenticationKeyMapping():
- model.authenticationValue = attributeValue
- break
- case user.getEmailMapping():
- model.email = attributeValue.toLowerCase()
- break
- }
- if(attributeName.equals(user.getFirstNameMapping())
- {
- ...
- }
- switch(true)
- {
- case {attributeName} :
- log.info("Currently switching on value... ${attributeName}")
- case {user.getFirstNameMapping().equals(attributeName)}:
- model.user.userInfo.firstName = attributeValue
- break
- case {user.getLastNameMapping().equals(attributeName)}:
- model.user.userInfo.lastName = attributeValue
- break
- case {user.getAuthenticationKeyMapping().equals(attributeName)}:
- model.authenticationValue = attributeValue
- break
- case {user.getEmailMapping().equals(attributeName)}:
- model.email = attributeValue.toLowerCase()
- break
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement