hasConstructor method

  1. @protected
bool hasConstructor(
  1. DartType type
)

If this class possesses a factory such as fromRest

Implementation

@protected
bool hasConstructor(DartType type) {
  final classElement = type.element2 as ClassElement;
  return classElement.getNamedConstructor(constructorName) != null;
}