| 239 | |
| 240 | |
| 241 | boolean isStatic(SimpleNode node) { |
| 242 | if (node instanceof BSHTypedVariableDeclaration) |
| 243 | return ((BSHTypedVariableDeclaration) node).modifiers != null && ((BSHTypedVariableDeclaration) node).modifiers.hasModifier("static"); |
| 244 | |
| 245 | if (node instanceof BSHMethodDeclaration) |
| 246 | return ((BSHMethodDeclaration) node).modifiers != null && ((BSHMethodDeclaration) node).modifiers.hasModifier("static"); |
| 247 | |
| 248 | // need to add static block here |
| 249 | if (node instanceof BSHBlock) return false; |
| 250 | |
| 251 | return false; |
| 252 | } |
| 253 | } |
| 254 | |
| 255 | |