/*
 * Copyright 2000-2016 JetBrains s.r.o.
 *
 * 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 com.intellij.ide.projectView;

import org.jetbrains.annotations.NotNull;

/**
 * This interface is intended for a provider of nesting rules for the project view.
 * Implementations of the {@link #addFileNestingRules} method should pass
 * the longest possible file name suffix to the consumer.
 * Usually this suffix starts with a dot. For example ".js"->".min.js".
 * You can specify a custom provider in the {@code plugin.xml} file:<pre>
 * &lt;extensions defaultExtensionNs="com.intellij"&gt;
 * &nbsp;&nbsp;&nbsp;&nbsp;&lt;projectViewNestingRulesProvider implementation="my.package.MyRulesProvider"/&gt;
 * &lt;/extensions&gt;</pre>
 */
public interface NestingRulesProvider {
  void addFileNestingRules(@NotNull Consumer consumer);

  interface Consumer {
    void addNestingRule(@NotNull String parentFileSuffix, @NotNull String childFileSuffix);
  }
}

@@ -714,21 +714,18 @@
 ded 
-for a
+to
  provide
 r of
@@ -724,12 +724,13 @@
 vide
-r of
+ file
  nes
@@ -739,20 +739,75 @@
 ng rules
- for
+,%0A * which allow to improve folder contents presentation in
  the pro
@@ -819,213 +819,320 @@
 view
-.
 %0A * 
-Implementations of the %7B@link #addFileNestingRules%7D method should pass%0A * the longest possible file name suffix to the consumer.%0A * Usually this suffix starts with a dot. For example %22.js%22-%3E%22.min.js%22.
+by showing some files as children of another peer file.%0A * It is useful when a folder contains both source file and its compiled output.%0A * For example, a generated %7B@code foo.min.js%7D file will be shown%0A * as a child of a %7B@code foo.js%7D file.%0A * %3Cbr/%3ENote that nesting logic is based on file names only.%3Cbr/%3E
 %0A * 
@@ -1443,16 +1443,295 @@
 vider %7B%0A
+  /**%0A   * Implementations of this method should pass the longest possible file name suffix to the consumer.%0A   * Usually this suffix starts with a dot. For example %22.js%22-%3E%22.min.js%22.%0A   *%0A   * @param consumer a consumer which maps extensions of a parent file and its child%0A   */%0A
   void a

Update javadoc for the NestingRulesProvider interface