State.java [src/csip/annotations] Revision: default  Date:
/*
 * $Id$
 *
 * This file is part of the Cloud Services Integration Platform (CSIP),
 * a Model-as-a-Service framework, API and application suite.
 *
 * 2012-2022, Olaf David and others, OMSLab, Colorado State University.
 *
 * OMSLab licenses this file to you under the MIT license.
 * See the LICENSE file in the project root for more information.
 */

package csip.annotations;

import java.lang.annotation.ElementType;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * Service development state definitions. Annotate a service to communicate the
 * current implementation phase of a service.
 *
 * @author od
 */
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
@Inherited
public @interface State {

  /**
   * This service is new. It is maybe just a skeleton implementation or a
   * placeholder for future work. No assurance at all.
   */
  public final String NEW = "New";

  /**
   * This is a prototype service implementation. POC, not more.
   *
   */
  public final String PROTOTYPE = "Prototype";

  /**
   * This is service is in development. POC, not more.
   *
   */
  public final String DEVELOPMENT = "Development";

  /**
   * The services is in development and being tested. The service signature and
   * the implementation can still change.
   */
  public final String UNSTABLE = "Unstable";

  /**
   * The service is implemented and tested. The API will not change anymore.
   */
  public final String STABLE = "Stable";

  /**
   * The service is released. It will be maintained with bug fixes. No API
   * changes.
   */
  public final String RELEASED = "Released";

  /**
   * The service is deprecated. Client are discouraged to use it since it may go
   * away soon.
   */
  public final String DEPRECATED = "Deprecated";

  /**
   * The service is expired and should not be used anymore. It is passed its
   * lifetime.
   */
  public static String EXPIRED = "Expired";

  /**
   * The service is temporarily broken. Results should not be trusted.
   */
  public static String BROKEN = "Broken";


  /** Get the State value. Defaults to NEW
   *
   * @return the current service implementation phase.
   */
  public String value() default NEW;
}