mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-16 22:51:17 +07:00
25 lines
817 B
HTML
25 lines
817 B
HTML
<html>
|
|
<body>
|
|
Reports objects of classes not implementing <code>java.io.Serializable</code> used as arguments to
|
|
<code>javax.servlet.http.HttpSession.setAttribute()</code> or
|
|
<code>javax.servlet.http.HttpSession.putValue()</code>.
|
|
<p>
|
|
Such objects will not be serialized if the <code>HttpSession</code> is passivated or migrated,
|
|
and may result in difficult-to-diagnose bugs.
|
|
</p>
|
|
<p>
|
|
This inspection assumes objects of the types <code>java.util.Collection</code> and
|
|
<code>java.util.Map</code> to be <code>Serializable</code>,
|
|
unless type parameters are non-<code>Serializable</code>.
|
|
</p>
|
|
<p><b>Example:</b></p>
|
|
<pre><code>
|
|
void foo(HttpSession session) {
|
|
session.setAttribute("foo", new NonSerializable());
|
|
}
|
|
static class NonSerializable {}
|
|
</code></pre>
|
|
<!-- tooltip end -->
|
|
|
|
</body>
|
|
</html> |