Home
Jiny
Cancel

Java Generic

Generic ๐Ÿ’ฟ Generic Data Type์„ ์ผ๋ฐ˜ํ™” ํ•˜๋Š”๊ฒƒ์„ ์˜๋ฏธ Classs ๋‚˜ Method์—์„œ ์‚ฌ์šฉํ•  ๋‚ด๋ถ€ ๋ฐ์ดํ„ฐ ํƒ€์ž…์„ ์ปดํŒŒ์ผ ์‹œ์— ๋ฏธ๋ฆฌ ์ง€์ •ํ•˜๋Š” ๋ฐฉ๋ฒ• Class๋‚˜ ๋ฉ”์„œ๋“œ ๋‚ด๋ถ€์—์„œ ์‚ฌ์šฉ๋˜๋Š” ๊ฐ์ฒด์˜ ํƒ€์ž…์˜ ์•ˆ์ •์„ฑ์„ ๋†’์ผ ์ˆ˜ ์žˆ๋‹ค. ๋ฐ˜ํ™˜๊ฐ’์— ๋Œ€ํ•œ ํƒ€์ž… ๋ณ€ํ™˜ ๋ฐ ํƒ€์ž… ๊ฒ€์‚ฌ์— ๋“ค์–ด๊ฐ€๋Š” ๋…ธ๋ ฅ์„ ์ค„์ผ...

Spring

Java Annotation ๐Ÿ”˜ Annotation ์–ด๋…ธํ…Œ์ด์…˜์˜ ์—ญํ• ๋„ ์ฃผ์„๊ณผ ํฌ๊ฒŒ ๋‹ค๋ฅด์ง€ ์•Š๋Š”๋‹ค. ์ผ๋ฐ˜์ฃผ์„๊ณผ ํฐ ์ฐจ์ด์ ์€ ์ฝ”๋“œ๋ฅผ ์ž‘์„ฑํ•  ์ˆ˜ ์žˆ๋‹ค๋Š” ๊ฒƒ์ด ๋‹ค๋ฅด๋‹ค. ์ฝ”๋“œ๋ฅผ ์ž‘์„ฑํ•  ์ˆ˜ ์žˆ๋‹ค๋Š” ๋œป์€ ์–ด๋…ธํ…Œ์ด์…˜์œผ๋กœ ๋ญ”๊ฐ€๋ฅผ ํ•  ์ˆ˜ ์žˆ๋‹ค๋Š” ๋œป์ด ๋œ๋‹ค. ์–ด๋…ธํ…Œ์ด์…˜๋„ enum๊ณผ ๋งˆ์ฐฌ๊ฐ€์ง€๋กœ 1.5์— ๋“ฑ์žฅํ–ˆ๋‹ค๊ณ  ํ•œ๋‹ค. ๐Ÿ”˜ Annotation...

Spring JPA 2

Spring JPA 2 ๐Ÿ’ฟ Entity Mapping @Entity Entity๋Š” ๊ฐ์ฒด ๊ด€์ ์—์„œ ๋ถ€๋ฅด๋Š” ์ด๋ฆ„ ๋ณดํ†ต Class์™€ ๊ฐ™์€ ์ด๋ฆ„์„ ์‚ฌ์šฉํ•˜๊ธฐ ๋•Œ๋ฌธ์— ๊ฐ’์„ ๋ณ€๊ฒฝํ•˜์ง€ ์•Š์Œ Entity์˜ ์ด๋ฆ„์€ JQL์—์„œ ์‚ฌ์šฉ @Table Relation(database) ๊ด€์ ์—์„œ ๋ถ€๋ฅด๋Š” ์ด๋ฆ„ @Entity์˜ ์ด๋ฆ„์ด ๊ธฐ๋ณธ๊ฐ’ Ta...

Spring JPA

Spring JPA ๐Ÿ’ฟ JPA ์ž๋ฐ” ์–ดํ”Œ๋ฆฌ์ผ€์ด์…˜์—์„œ ๊ด€๊ณ„ํ˜• ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค๋ฅผ ์‚ฌ์šฉํ•˜๋Š” ๋ฐฉ์‹์„ ์ •์˜ํ•œ ์ธํ„ฐํŽ˜์ด์Šค ์—ฌ๊ธฐ์„œ ์ฃผ๋ชฉํ•  ์ ์€ ๋ฐ”๋กœ ์ธํ„ฐํŽ˜์ด์Šค๋ผ๋Š” ๊ฒƒ์ด๋‹ค. JPA๋Š” ํŠน์ • ๊ธฐ๋Šฅ์„ ํ•˜๋Š” ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ๊ฐ€ ์•„๋‹ˆ๋‹ค. JPA๋Š” ์ž๋ฐ” ์–ดํ”Œ๋ฆฌ์ผ€์ด์…˜์—์„œ ๊ด€๊ณ„ํ˜• ๋ฐ์ดํ„ฐ๋ฒ ์ด์Šค๋ฅผ ์–ด๋–ป๊ฒŒ ์‚ฌ์šฉํ•ด์•ผ ํ•˜๋Š”์ง€๋ฅผ ์ •์˜ํ•œ ๋ฐฉ๋ฒ•์ด๋‹ค. JPA๋Š” ๋‹จ์ˆœํžˆ interface์ด...

Thread Process

Thread Process ๐Ÿ’ฟ Definition ํ”„๋กœ๊ทธ๋žจ: ํŒŒ์ผ์ด ์ €์žฅ ์žฅ์น˜์— ์ €์žฅ๋˜์–ด ์žˆ์ง€๋งŒ ๋ฉ”๋ชจ๋ฆฌ์—๋Š” ์˜ฌ๋ผ๊ฐ€ ์žˆ์ง€ ์•Š์€ ์ •์ ์ธ ์ƒํƒœ๋ฅผ ๋งํ•œ๋‹ค. ํ”„๋กœ์„ธ์Šค: ์šด์˜์ฒด์ œ๋กœ๋ถ€ํ„ฐ ์ž์›์„ ํ• ๋‹น๋ฐ›์€ ์ž‘์—…์˜ ๋‹จ์œ„. ์Šค๋ ˆ๋“œ: ํ”„๋กœ์„ธ์Šค๊ฐ€ ํ• ๋‹น๋ฐ›์€ ์ž์›์„ ์ด์šฉํ•˜๋Š” ์‹คํ–‰ ํ๋ฆ„์˜ ๋‹จ์œ„. ๐Ÿ’ฟ Thread & Process Thread๋Š”...

Java Thread

Java Thread ๐Ÿ’ฟ Thread LifeCycle New: Thread.start() ํ•˜๋ฉด ์‹คํ–‰๋จ Runnable: startํ•˜๋ฉด runnable๋กœ ๋ฐ”๋€œ Control์ด Thread Scheduler๋กœ ๊ฐ€์„œ ์‹คํ–‰์„ ๊ธฐ๋‹ค๋ฆผ Running: Scheduler๊ฐ€ ์‹คํ–‰์„ ์‹œํ‚จ ์ƒํƒœ Blocked...

Spring-Web

Spring Web URL get, post๋Š” ๊ธฐ๋ณธ head: get๊ณผ ๊ฐ™์œผ๋‚˜ header ์ •๋ณด๋งŒ ๊ฐ€์ ธ์˜ด options ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ๋Š” http Method ์ œ๊ณต ์„œ๋ฒ„ ๋˜๋Š” ํŠน์ • ๋ฆฌ์†Œ์Šค๊ฐ€ ์ œ๊ณตํ•˜๋Š” ๊ธฐ๋Šฅ์„ ํ™•์ธ ์„œ๋ฒ„ ๋˜๋Š” allow ์‘๋‹ต ํ—ค๋”์— ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ๋Š” http method ๋ชฉ๋ก ์ œ๊ณต ...

Java Exception

Java Exception ๐Ÿ’ฟ ๋ชฉ์ฐจ ์ž๋ฐ”์—์„œ ์˜ˆ์™ธ ์ฒ˜๋ฆฌ ๋ฐฉ๋ฒ• (try, catch, throw, throws, finally) ์ž๋ฐ”๊ฐ€ ์ œ๊ณตํ•˜๋Š” ์˜ˆ์™ธ ๊ณ„์ธต ๊ตฌ์กฐ Exception๊ณผ Error์˜ ์ฐจ์ด๋Š”? RuntimeException๊ณผ RE๊ฐ€ ์•„๋‹Œ ๊ฒƒ์˜ ์ฐจ์ด๋Š”? ์ปค์Šคํ…€ํ•œ ์˜ˆ์™ธ ๋งŒ๋“œ๋Š” ๋ฐฉ๋ฒ• ์˜ˆ์™ธ(Exception)์™€ ์—๋Ÿฌ(Erro...

Spring Security

Spring Security Spring Security? ์Šคํ”„๋ง ์‹œํ๋ฆฌํ‹ฐ๋Š” ์Šคํ”„๋ง ๊ธฐ๋ฐ˜์˜ ์• ํ”Œ๋ฆฌ์ผ€์ด์…˜์˜ ๋ณด์•ˆ(์ธ์ฆ๊ณผ ๊ถŒํ•œ, ์ธ๊ฐ€ ๋“ฑ)์„ ๋‹ด๋‹นํ•˜๋Š” ํ•˜์œ„ ํ”„๋ ˆ์ž„ ์›Œํฌ ๊ธฐ๋ณธ์šฉ์–ด ์ ‘๊ทผ ์ฃผ์ฒด: ๋ณดํ˜ธ๋œ ๋ฆฌ์†Œ์Šค์— ์ ‘๊ทผํ•˜๋Š” ๋Œ€์ƒ ์ธ์ฆ(Authentication): ๋ณดํ˜ธ๋œ ๋ฆฌ์†Œ์Šค์— ์ ‘๊ทผํ•œ ๋Œ€์ƒ์— ๋Œ€ํ•ด ๋ˆ„๊ตฌ์ธ์ง€, App์˜ ์ž‘์—…์„ ์ˆ˜ํ–‰ํ•ด๋„ ๋˜๋Š”...

Spring Security2

Spring Security-2 DelegatingFilterProxy Spring Security๊ฐ€ ๋ชจ๋“  App ์š”์ฒญ์„ ๊ฐ์‹ธ๊ฒŒ ํ•ด์„œ ๋ณด์•ˆ์ด ์ ์šฉ๋˜๊ฒŒ ํ•˜๋Š” ์„œ๋ธ”๋ฆฟ ํ•„ํ„ฐ ์„œ๋ธ”๋ฆฟ ํ•„ํ„ฐ๋Š” ์Šคํ”„๋ง์—์„œ ์ •์˜๋œ ๋นˆ์„ ์ฃผ์ž…ํ•ด์„œ ์‚ฌ์šฉํ•  ์ˆ˜ ์—†์Œ ํŠน์ •ํ•œ ์ด๋ฆ„์„ ๊ฐ€์ง„ ์Šคํ”„๋ง ๋นˆ์„ ์ฐพ์•„ ๊ทธ ๋นˆ์—๊ฒŒ ์š”์ฒญ์„ ์œ„์ž„ springSe...