View Javadoc
1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one
3    * or more contributor license agreements.  See the NOTICE file
4    * distributed with this work for additional information
5    * regarding copyright ownership.  The ASF licenses this file
6    * to you under the Apache License, Version 2.0 (the
7    * "License"); you may not use this file except in compliance
8    * with the License.  You may obtain a copy of the License at
9    *
10   *   http://www.apache.org/licenses/LICENSE-2.0
11   *
12   * Unless required by applicable law or agreed to in writing,
13   * software distributed under the License is distributed on an
14   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15   * KIND, either express or implied.  See the License for the
16   * specific language governing permissions and limitations
17   * under the License.
18   */
19  package org.apache.maven.api;
20  
21  /**
22   * Configuration constants.
23   * <p>
24   * Maven 3 carries only the style names of the Maven 4 class, for {@link org.apache.maven.api.services.MessageBuilder}.
25   *
26   * @since 3.10.1
27   */
28  public final class Constants {
29  
30      public static final String MAVEN_STYLE_PREFIX = "maven.style.";
31  
32      // Style Names
33      public static final String MAVEN_STYLE_TRANSFER_NAME = "transfer";
34      public static final String MAVEN_STYLE_TRACE_NAME = "trace";
35      public static final String MAVEN_STYLE_DEBUG_NAME = "debug";
36      public static final String MAVEN_STYLE_INFO_NAME = "info";
37      public static final String MAVEN_STYLE_WARNING_NAME = "warning";
38      public static final String MAVEN_STYLE_ERROR_NAME = "error";
39      public static final String MAVEN_STYLE_SUCCESS_NAME = "success";
40      public static final String MAVEN_STYLE_FAILURE_NAME = "failure";
41      public static final String MAVEN_STYLE_STRONG_NAME = "strong";
42      public static final String MAVEN_STYLE_MOJO_NAME = "mojo";
43      public static final String MAVEN_STYLE_PROJECT_NAME = "project";
44  
45      // Default Values
46      public static final String MAVEN_STYLE_TRANSFER_DEFAULT = "f:bright-black";
47      public static final String MAVEN_STYLE_TRACE_DEFAULT = "bold,f:magenta";
48      public static final String MAVEN_STYLE_DEBUG_DEFAULT = "bold,f:cyan";
49      public static final String MAVEN_STYLE_INFO_DEFAULT = "bold,f:blue";
50      public static final String MAVEN_STYLE_WARNING_DEFAULT = "bold,f:yellow";
51      public static final String MAVEN_STYLE_ERROR_DEFAULT = "bold,f:red";
52      public static final String MAVEN_STYLE_SUCCESS_DEFAULT = "bold,f:green";
53      public static final String MAVEN_STYLE_FAILURE_DEFAULT = "bold,f:red";
54      public static final String MAVEN_STYLE_STRONG_DEFAULT = "bold";
55      public static final String MAVEN_STYLE_MOJO_DEFAULT = "f:green";
56      public static final String MAVEN_STYLE_PROJECT_DEFAULT = "f:cyan";
57  
58      /**
59       * Maven output color mode.
60       * Allowed values are <code>auto</code>, <code>always</code>, <code>never</code>.
61       *
62       * @since 3.10.1
63       */
64      public static final String MAVEN_STYLE_COLOR_PROPERTY = MAVEN_STYLE_PREFIX + "color";
65  
66      /**
67       * Color style for transfer messages.
68       * @since 3.10.1
69       */
70      public static final String MAVEN_STYLE_TRANSFER = MAVEN_STYLE_PREFIX + MAVEN_STYLE_TRANSFER_NAME;
71  
72      /**
73       * Color style for trace messages.
74       * @since 3.10.1
75       */
76      public static final String MAVEN_STYLE_TRACE = MAVEN_STYLE_PREFIX + MAVEN_STYLE_TRACE_NAME;
77  
78      /**
79       * Color style for debug messages.
80       * @since 3.10.1
81       */
82      public static final String MAVEN_STYLE_DEBUG = MAVEN_STYLE_PREFIX + MAVEN_STYLE_DEBUG_NAME;
83  
84      /**
85       * Color style for info messages.
86       * @since 3.10.1
87       */
88      public static final String MAVEN_STYLE_INFO = MAVEN_STYLE_PREFIX + MAVEN_STYLE_INFO_NAME;
89  
90      /**
91       * Color style for warning messages.
92       * @since 3.10.1
93       */
94      public static final String MAVEN_STYLE_WARNING = MAVEN_STYLE_PREFIX + MAVEN_STYLE_WARNING_NAME;
95  
96      /**
97       * Color style for error messages.
98       * @since 3.10.1
99       */
100     public static final String MAVEN_STYLE_ERROR = MAVEN_STYLE_PREFIX + MAVEN_STYLE_ERROR_NAME;
101 
102     /**
103      * Color style for success messages.
104      * @since 3.10.1
105      */
106     public static final String MAVEN_STYLE_SUCCESS = MAVEN_STYLE_PREFIX + MAVEN_STYLE_SUCCESS_NAME;
107 
108     /**
109      * Color style for failure messages.
110      * @since 3.10.1
111      */
112     public static final String MAVEN_STYLE_FAILURE = MAVEN_STYLE_PREFIX + MAVEN_STYLE_FAILURE_NAME;
113 
114     /**
115      * Color style for strong messages.
116      * @since 3.10.1
117      */
118     public static final String MAVEN_STYLE_STRONG = MAVEN_STYLE_PREFIX + MAVEN_STYLE_STRONG_NAME;
119 
120     /**
121      * Color style for mojo messages.
122      * @since 3.10.1
123      */
124     public static final String MAVEN_STYLE_MOJO = MAVEN_STYLE_PREFIX + MAVEN_STYLE_MOJO_NAME;
125 
126     /**
127      * Color style for project messages.
128      * @since 3.10.1
129      */
130     public static final String MAVEN_STYLE_PROJECT = MAVEN_STYLE_PREFIX + MAVEN_STYLE_PROJECT_NAME;
131 
132     private Constants() {}
133 }