Coverage Report - org.owasp.dependencycheck.xml.pom.Model
 
Classes in this File Line Coverage Branch Coverage Complexity
Model
87%
28/32
N/A
1
 
 1  
 /*
 2  
  * This file is part of dependency-check-core.
 3  
  *
 4  
  * Licensed under the Apache License, Version 2.0 (the "License");
 5  
  * you may not use this file except in compliance with the License.
 6  
  * You may obtain a copy of the License at
 7  
  *
 8  
  *     http://www.apache.org/licenses/LICENSE-2.0
 9  
  *
 10  
  * Unless required by applicable law or agreed to in writing, software
 11  
  * distributed under the License is distributed on an "AS IS" BASIS,
 12  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 13  
  * See the License for the specific language governing permissions and
 14  
  * limitations under the License.
 15  
  *
 16  
  * Copyright (c) 2015 Jeremy Long. All Rights Reserved.
 17  
  */
 18  
 package org.owasp.dependencycheck.xml.pom;
 19  
 
 20  
 import java.util.ArrayList;
 21  
 import java.util.List;
 22  
 
 23  
 /**
 24  
  * A simple pojo to hold data related to a Maven POM file.
 25  
  *
 26  
  * @author jeremy
 27  
  */
 28  2
 public class Model {
 29  
 
 30  
     /**
 31  
      * The name of the project.
 32  
      */
 33  
     private String name;
 34  
 
 35  
     /**
 36  
      * Get the value of name.
 37  
      *
 38  
      * @return the value of name
 39  
      */
 40  
     public String getName() {
 41  2
         return name;
 42  
     }
 43  
 
 44  
     /**
 45  
      * Set the value of name.
 46  
      *
 47  
      * @param name new value of name
 48  
      */
 49  
     public void setName(String name) {
 50  2
         this.name = name;
 51  2
     }
 52  
 
 53  
     /**
 54  
      * The organization name.
 55  
      */
 56  
     private String organization;
 57  
 
 58  
     /**
 59  
      * Get the value of organization.
 60  
      *
 61  
      * @return the value of organization
 62  
      */
 63  
     public String getOrganization() {
 64  1
         return organization;
 65  
     }
 66  
 
 67  
     /**
 68  
      * Set the value of organization.
 69  
      *
 70  
      * @param organization new value of organization
 71  
      */
 72  
     public void setOrganization(String organization) {
 73  0
         this.organization = organization;
 74  0
     }
 75  
 
 76  
     /**
 77  
      * The description.
 78  
      */
 79  
     private String description;
 80  
 
 81  
     /**
 82  
      * Get the value of description.
 83  
      *
 84  
      * @return the value of description
 85  
      */
 86  
     public String getDescription() {
 87  1
         return description;
 88  
     }
 89  
 
 90  
     /**
 91  
      * Set the value of description.
 92  
      *
 93  
      * @param description new value of description
 94  
      */
 95  
     public void setDescription(String description) {
 96  1
         this.description = description;
 97  1
     }
 98  
 
 99  
     /**
 100  
      * The group id.
 101  
      */
 102  
     private String groupId;
 103  
 
 104  
     /**
 105  
      * Get the value of groupId.
 106  
      *
 107  
      * @return the value of groupId
 108  
      */
 109  
     public String getGroupId() {
 110  1
         return groupId;
 111  
     }
 112  
 
 113  
     /**
 114  
      * Set the value of groupId.
 115  
      *
 116  
      * @param groupId new value of groupId
 117  
      */
 118  
     public void setGroupId(String groupId) {
 119  2
         this.groupId = groupId;
 120  2
     }
 121  
 
 122  
     /**
 123  
      * The artifact id.
 124  
      */
 125  
     private String artifactId;
 126  
 
 127  
     /**
 128  
      * Get the value of artifactId.
 129  
      *
 130  
      * @return the value of artifactId
 131  
      */
 132  
     public String getArtifactId() {
 133  1
         return artifactId;
 134  
     }
 135  
 
 136  
     /**
 137  
      * Set the value of artifactId.
 138  
      *
 139  
      * @param artifactId new value of artifactId
 140  
      */
 141  
     public void setArtifactId(String artifactId) {
 142  2
         this.artifactId = artifactId;
 143  2
     }
 144  
 
 145  
     /**
 146  
      * The version number.
 147  
      */
 148  
     private String version;
 149  
 
 150  
     /**
 151  
      * Get the value of version.
 152  
      *
 153  
      * @return the value of version
 154  
      */
 155  
     public String getVersion() {
 156  1
         return version;
 157  
     }
 158  
 
 159  
     /**
 160  
      * Set the value of version.
 161  
      *
 162  
      * @param version new value of version
 163  
      */
 164  
     public void setVersion(String version) {
 165  1
         this.version = version;
 166  1
     }
 167  
 
 168  
     /**
 169  
      * The parent group id.
 170  
      */
 171  
     private String parentGroupId;
 172  
 
 173  
     /**
 174  
      * Get the value of parentGroupId.
 175  
      *
 176  
      * @return the value of parentGroupId
 177  
      */
 178  
     public String getParentGroupId() {
 179  2
         return parentGroupId;
 180  
     }
 181  
 
 182  
     /**
 183  
      * Set the value of parentGroupId.
 184  
      *
 185  
      * @param parentGroupId new value of parentGroupId
 186  
      */
 187  
     public void setParentGroupId(String parentGroupId) {
 188  1
         this.parentGroupId = parentGroupId;
 189  1
     }
 190  
 
 191  
     /**
 192  
      * The parent artifact id.
 193  
      */
 194  
     private String parentArtifactId;
 195  
 
 196  
     /**
 197  
      * Get the value of parentArtifactId.
 198  
      *
 199  
      * @return the value of parentArtifactId
 200  
      */
 201  
     public String getParentArtifactId() {
 202  2
         return parentArtifactId;
 203  
     }
 204  
 
 205  
     /**
 206  
      * Set the value of parentArtifactId.
 207  
      *
 208  
      * @param parentArtifactId new value of parentArtifactId
 209  
      */
 210  
     public void setParentArtifactId(String parentArtifactId) {
 211  1
         this.parentArtifactId = parentArtifactId;
 212  1
     }
 213  
 
 214  
     /**
 215  
      * The parent version number.
 216  
      */
 217  
     private String parentVersion;
 218  
 
 219  
     /**
 220  
      * Get the value of parentVersion.
 221  
      *
 222  
      * @return the value of parentVersion
 223  
      */
 224  
     public String getParentVersion() {
 225  2
         return parentVersion;
 226  
     }
 227  
 
 228  
     /**
 229  
      * Set the value of parentVersion.
 230  
      *
 231  
      * @param parentVersion new value of parentVersion
 232  
      */
 233  
     public void setParentVersion(String parentVersion) {
 234  1
         this.parentVersion = parentVersion;
 235  1
     }
 236  
 
 237  
     /**
 238  
      * The list of licenses.
 239  
      */
 240  2
     private List<License> licenses = new ArrayList<License>();
 241  
 
 242  
     /**
 243  
      * Returns the list of licenses.
 244  
      *
 245  
      * @return the list of licenses
 246  
      */
 247  
     public List<License> getLicenses() {
 248  2
         return licenses;
 249  
     }
 250  
 
 251  
     /**
 252  
      * Adds a new license to the list of licenses.
 253  
      *
 254  
      * @param license the license to add
 255  
      */
 256  
     public void addLicense(License license) {
 257  0
         licenses.add(license);
 258  0
     }
 259  
 
 260  
 }