Package: groovy.org.codenarc.rule.unnecessary

## [Groovy] Class UnnecessaryInstantiationAstVisitor

- groovy.org.codenarc.rule.unnecessary.UnnecessaryInstantiationAstVisitor

- Base visitor for unnecessary constructor calls.

  Authors:
    Hamlet D'Arcy

- - ### Properties Summary

    Properties
    Type | Name and description
    --- | ---
    `List<Class>` | `parameterTypes`
    `String` | `suffix`
    `Class` | `targetType`

  - ### Constructor Summary

    Constructors
    Constructor and description
    `UnnecessaryInstantiationAstVisitor (Class targetType, List<Class> parameterTypes, String suffix)`

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `protected boolean` | `isTypeSuffixNecessary(def argument)`
    `` | `protected boolean` | `shouldSkipViolation(Object value)`
    `` | `void` | `visitConstructorCallExpression(org.codehaus.groovy.ast.expr.ConstructorCallExpression call)`

- - ### Property Detail

    - #### List<Class> parameterTypes

    - #### String suffix

    - #### Class targetType

  - ### Constructor Detail

    - #### UnnecessaryInstantiationAstVisitor(Class targetType, List<Class> parameterTypes, String suffix)

  - ### Method Detail

    - #### @SuppressWarnings('UnusedMethodParameter') protected boolean isTypeSuffixNecessary(def argument)

    - #### @SuppressWarnings('UnusedMethodParameter') protected boolean shouldSkipViolation(Object value)

    - #### @Override final void visitConstructorCallExpression(org.codehaus.groovy.ast.expr.ConstructorCallExpression call)