Obtains a boolean value by comparing the obtained value with a local value.
/**
* Sets the port of the local Socks5 proxy. Default is 7777. If you set the port to a negative
* Value Smack tries the absolute value and all following until it finds an open port.
*
* @ Param localSocks5ProxyPort the port of the local Socks5 proxy to set
*/
Public static void setLocalSocks5ProxyPort (int localSocks5ProxyPort ){
SmackConfiguration. localSocks5ProxyPort = localSocks5ProxyPort;
}
In the jsp project, how does one obtain the boolean value of the front-end interface in servlet,
The frontend is actually a string type.
Therefore, the boolean type cannot be obtained directly.
But it can be converted
For example, if you use a boolean value on the front end, but the value of true is changed to true when it is passed, and false is changed to false when it is passed.
When the background is retrieved, it is still the same as the string. When the background is retrieved, let's judge.
String a = request. getXXX // obtain the value passed by the front end
Boolean B;
If (a. equals ("true") // use equals instead of =
B = true;
Else
B = false;
How does the Servlet obtain the boolean value from a boolean data jsp page on the DAO layer?
Servlet: request. setatrri.pdf ("boolean", StringObj );
JSP page: request. getAtrribute ("boolean"); or EL :$ {boolean}