[JAVA] About setAttribute / getAttribute

I am a java beginner. This time, I will output about setAttribute / getAttribute. setAttribute() Store the value with a specific name as a marker with setAttribute getAttribute() Extract the value based on the name given by setAttribute

Q1: Where are you storing it?

For example

session.setAttribute("str","Qiita"); In the above case, the character string "Qiita" named str is stored in ** session **.

request.setAttribute("language","Java"); In the above case, the string "Java" named language is stored in ** request **.

How to write when taking out

In case of ① session.getAttribute("str"); Now you can get the string "Qiita".

Basically in java ** set ** is stored ** get ** is taken out I would like to think of it like this.

Recommended Posts

About setAttribute / getAttribute
About =
About method.invoke
About Kotlin
About attr_accessor
About Hinemos
About inheritance
About params
About Docker
About form_for
About Spring ③
About polymorphism
About Optional
About hashes
About JitPack
About Dockerfile
About this ()
About devise
About encapsulation
About Docker
About JAVA_HOME
About static
About exceptions
About scope
[Maven] About Maven