We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why checking with instanceof and then casting if we just can pass instance of type Node?
instanceof
Node
@SuppressWarnings("PMD.ConstructorOnlyInitializesOrCallOtherConstructors") DomDecor(final Object doc) throws DecorException { if (doc != null && !(doc instanceof Node)) { throw new DecorException( String.format( "Instance of org.w3c.dom.Node required, while %s provided", doc.getClass().getName() ) ); } this.node = (Node) doc; }
The text was updated successfully, but these errors were encountered:
@yegor256 please, pay attention to this issue
Sorry, something went wrong.
No branches or pull requests
Why checking with
instanceof
and then casting if we just can pass instance of typeNode
?The text was updated successfully, but these errors were encountered: