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 |
Tags
- Application Runner
- 알고리즘
- 정적 리소스
- 스프링부트
- 백준
- JPA
- Spring Security
- 다익스트라
- OAuth2
- 백트래킹
- webjar
- rest api
- Application Argument
- 리소스 서버
- 브루트포스
- AuthenticationPrincipal
- 스프링 부트
- application.properties
- HATEOAS
- @ConfigurationProperties
- @Profile
- 리소스핸들러
- JsonSerializer
- Application Event
- 외부설정
- cors
- WebApplication Type
- HttpMessageConverters
- 백기선
- EnableAutoConfiguration
Archives
- Today
- Total
아카이브
final 키워드 본문
1. class final
- class가 상속되지 않도록 함
- final class Sample {
}
2. method final
- method 오버라이딩을 차단
- class Sample {
void methodA() {...}
}
class Child extends Sample {
// 상위 class의 method를 오버라이딩 할 수 없음
}
3. variable final
- final 변수가 초기화된 후 값을 변경할 수 없음
- final int INF = Integer.MAX_VALUE
- 문서화의 한 형태로 가독성을 높이고 수정이 간편함
'Java' 카테고리의 다른 글
HashMap과 HashTable (0) | 2021.01.06 |
---|---|
equals()메소드와 hashCode()메소드 (0) | 2018.06.27 |
Interface와 abstract class (0) | 2018.06.18 |
String 과 StringBuffer/StringBuilder (0) | 2018.06.18 |