We can retrieve the currently logged user in two ways.
1. By el : retrieving the user details in front end pages using expression language.
#{securityContext.userName}
2. By managed bean java code.
import statements :
import oracle.adf.share.ADFContext;
import oracle.adf.share.security.SecurityContext;
SecurityContext securityContext=ADFContext.getCurrent().getSecurityContext();
String username=securityContext.getUserName();
1. By el : retrieving the user details in front end pages using expression language.
#{securityContext.userName}
2. By managed bean java code.
import statements :
import oracle.adf.share.ADFContext;
import oracle.adf.share.security.SecurityContext;
SecurityContext securityContext=ADFContext.getCurrent().getSecurityContext();
String username=securityContext.getUserName();
No comments:
Post a Comment