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.rat.analysis.license;
20  
21  import org.apache.rat.DeprecationReporter;
22  import org.apache.rat.license.ILicenseFamily;
23  
24  @Deprecated // remove in v1.0
25  @DeprecationReporter.Info(since = "0.16", forRemoval = true, use = "new configuration options")
26  public abstract class BaseLicense implements DeprecatedConfig {
27      private String licenseFamilyCategory;
28      private String licenseFamilyName;
29      private String notes;
30  
31      public BaseLicense() {
32          DeprecationReporter.logDeprecated(BaseLicense.class);
33      }
34  
35      public String getLicenseFamilyCategory() {
36          return licenseFamilyCategory;
37      }
38  
39      public void setLicenseFamilyCategory(String pDocumentCategory) {
40          licenseFamilyCategory = pDocumentCategory;
41      }
42  
43      public String getLicenseFamilyName() {
44          return licenseFamilyName;
45      }
46  
47      public void setLicenseFamilyName(String pLicenseFamilyCategory) {
48          licenseFamilyName = pLicenseFamilyCategory;
49      }
50  
51      public String getNotes() {
52          return notes;
53      }
54  
55      public void setNotes(String pNotes) {
56          notes = pNotes;
57      }
58      
59      @Override
60      final public ILicenseFamily getLicenseFamily() {
61          return ILicenseFamily.builder()
62          .setLicenseFamilyCategory(licenseFamilyCategory)
63          .setLicenseFamilyName(licenseFamilyName)
64          .build();
65      }
66  }