Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | |
7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 | 31 |
Tags
- xssfworkbook
- Swift
- poi 대용량
- poi monitorjbl
- swift 계산기
- xssreader
- js 전자서명
- xlsx-streamer
- monitorjbl
- xcode12.5.1
- swift 메모장 만들기
- 전자서명개발
- js달력
- PostgreSQL
- monitorjbl 엑셀
- spring annotation
- 달력기능개발
- MSsql
- fullcalendar js
- opcpackage
- outofmemoryerror 방지
- ios app 개발
- jxls 엑셀
- mysql
- xcode swift memo
- Xcode
- 전자서명기능구현
- 대용량엑셀업로드
- Oracle
- jxls
Archives
- Today
- Total
web developer👩🏻💻
컨트롤러 아닌곳에서 session 값 얻기 본문
728x90
public static LoginVO getUser(){
ServletRequestAttributes servletrequestattributes = (ServletRequestAttributes) RequestContextHolder.currentRequestAttributes();
HttpSession session = servletrequestattributes.getRequest().getSession(true);
return (LoginVO) session.getAttribute("컨트롤러에서 만들었던 setAttribute 값 ex)loginVO");
}
'Spring' 카테고리의 다른 글
[Spring] WebSocket sockJS 실시간 알림 구현하기 (3) (1) | 2022.01.10 |
---|---|
[Spring] 파일 다운로드 구현 (0) | 2021.12.15 |
[JAVA] sever ip 얻는 방법 InetAddress.getLocalHost() (0) | 2021.11.28 |
[Spring] WebSocket sockJS Q&A 실시간 알림 구현하기 (2) (3) | 2021.11.12 |
[Spring] WebSocket sockJS Q&A 실시간 알림 구현하기 (1) (0) | 2021.11.11 |