<commit_before>/*
 * Copyright 2019 the original author or authors.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.gradle.kotlin.dsl.support.delegates

import groovy.lang.Closure

import org.gradle.api.Action
import org.gradle.api.artifacts.ClientModule
import org.gradle.api.artifacts.Dependency
import org.gradle.api.artifacts.DependencyArtifact
import org.gradle.api.artifacts.ExcludeRule
import org.gradle.api.artifacts.ExternalDependency
import org.gradle.api.artifacts.ExternalModuleDependency
import org.gradle.api.artifacts.ModuleDependency
import org.gradle.api.artifacts.ModuleDependencyCapabilitiesHandler
import org.gradle.api.artifacts.ModuleIdentifier
import org.gradle.api.artifacts.ModuleVersionIdentifier
import org.gradle.api.artifacts.MutableVersionConstraint
import org.gradle.api.artifacts.VersionConstraint
import org.gradle.api.attributes.AttributeContainer
import org.gradle.api.capabilities.Capability


/**
 * Facilitates the implementation of the [ClientModule] interface by delegation via subclassing.
 *
 * See [GradleDelegate] for details why this is currently necessary.
 */
abstract class ClientModuleDelegate : ClientModule {

    internal
    abstract val delegate: ClientModule

    override fun getGroup(): String? =
        delegate.group

    override fun addDependency(dependency: ModuleDependency) =
        delegate.addDependency(dependency)

    override fun getName(): String =
        delegate.name

    override fun getExcludeRules(): MutableSet<ExcludeRule> =<commit_msg>Fix `ClientModuleDelegate.getGroup()` not to return `null`<commit_after>/*
 * Copyright 2019 the original author or authors.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.gradle.kotlin.dsl.support.delegates

import groovy.lang.Closure

import org.gradle.api.Action
import org.gradle.api.artifacts.ClientModule
import org.gradle.api.artifacts.Dependency
import org.gradle.api.artifacts.DependencyArtifact
import org.gradle.api.artifacts.ExcludeRule
import org.gradle.api.artifacts.ExternalDependency
import org.gradle.api.artifacts.ExternalModuleDependency
import org.gradle.api.artifacts.ModuleDependency
import org.gradle.api.artifacts.ModuleVersionSelector
import org.gradle.api.artifacts.ModuleDependencyCapabilitiesHandler
import org.gradle.api.artifacts.ModuleIdentifier
import org.gradle.api.artifacts.ModuleVersionIdentifier
import org.gradle.api.artifacts.MutableVersionConstraint
import org.gradle.api.artifacts.VersionConstraint
import org.gradle.api.attributes.AttributeContainer
import org.gradle.api.capabilities.Capability


/**
 * Facilitates the implementation of the [ClientModule] interface by delegation via subclassing.
 *
 * See [GradleDelegate] for details why this is currently necessary.
 */
abstract class ClientModuleDelegate : ClientModule {

    internal
    abstract val delegate: ClientModule

    override fun getGroup(): String =
        /** Because this also implements [ModuleVersionSelector.getGroup] it must not return `null` */
        delegate.group ?: ""

    override fun addDependency(dependency: ModuleDependency) =
        delegate.addDependency(dependency)

    override fun getName(): String =
        delegate.name

    override fun getExcludeRules(): MutableSet<ExcludeRule> =
{'fraction_non_alphanumeric': 0.07629681321237497, 'fraction_numerical': 0.0037217957664573155, 'mean_word_length': 4.657894736842105, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2503365', 'n_tokens_mistral': 1148, 'n_tokens_neox': 1075, 'n_words': 353}