// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.intellij.tasks.context;

import com.intellij.openapi.extensions.ExtensionPointName;
import com.intellij.openapi.project.Project;
import org.jdom.Element;
import org.jetbrains.annotations.NotNull;

/**
 * @author Dmitry Avdeev
 */
public abstract class WorkingContextProvider {
  public static final ExtensionPointName<WorkingContextProvider> EP_NAME = new ExtensionPointName<>("com.intellij.tasks.contextProvider");

  /**
   * Short unique name.
   * Should be valid as a tag name (for serialization purposes).
   * No spaces, dots etc allowed.
   *
   * @return provider's name
   */
  @NotNull
  public abstract String getId();

  /**
   * Short description (for UI)
   * @return
   */
  @NotNull
  public abstract String getDescription();

  /**
   * Saves a component's state.
   * May delegate to {@link com.intellij.openapi.util.JDOMExternalizable#writeExternal(org.jdom.Element)}
   * @param project
   * @param toElement
   */
  public abstract void saveContext(@NotNull Project project, @NotNull Element toElement);

  public abstract void loadContext(@NotNull Project project, @NotNull Element fromElement);

  public void clearContext(@NotNull Project project) {
  }
}

@@ -300,16 +300,54 @@
 lement;%0A
+import org.jetbrains.annotations.Nls;%0A
 import o
@@ -857,38 +857,79 @@
  UI)
+.
 %0A   *
- @return%0A   */%0A  @NotNull
+/%0A  @NotNull%0A  @Nls(capitalization = Nls.Capitalization.Sentence)
 %0A  p
@@ -1113,16 +1113,21 @@
 ement)%7D%0A
+   *%0A
    * @pa

add @Nls capitalization