public Optional<GraphQLError> addAll(Collection<SDLDefinition> definitions) {
        for (SDLDefinition definition : definitions) {
            Optional<GraphQLError> error = add(definition);
            if (error.isPresent()) {
                return error;
            }
        }
        return Optional.empty();
    }
public Optional < GraphQLError > addAll ( Collection < SDLDefinition > definitions ) { for ( SDLDefinition definition : definitions ) { Optional < GraphQLError > error = add ( definition ) ; if ( error . isPresent ( ) ) { return error ; } } return Optional . empty ( ) ; }
Adds a a collections of definitions to the registry

@param definitions the definitions to add

@return an optional error for the first problem, typically type redefinition