@@ -70,7 +70,7 @@ public static void main(String[] args) {
7070 System .exit (ERROR_STATUS );
7171 }
7272 if (args .length > MAX_ARGS ) {
73- System .out .printf ("Warning: Extra arguments will be ignored" );
73+ System .out .println ("Warning: Extra arguments will be ignored" );
7474 }
7575 SpdxToolsHelper .initialize ();
7676 List <String > verify = null ;
@@ -104,20 +104,20 @@ public static void main(String[] args) {
104104 errors .add (verifyMsg );
105105 }
106106 }
107- if (errors .size () > 0 ) {
107+ if (! errors .isEmpty () ) {
108108 System .out .println ("This SPDX Document is not valid due to:" );
109109 for (String errorMsg :errors ) {
110110 System .out .print ("\t " + errorMsg +"\n " );
111111 }
112112 }
113- if (warnings .size () > 0 ) {
113+ if (! warnings .isEmpty () ) {
114114 System .out .println ("Warning: Deprecated license identifiers were found that should no longer be used.\n "
115115 + "References to the following deprecated license ID's should be updated:" );
116116 for (String warningMsg :warnings ) {
117117 System .out .print ("\t " + warningMsg +"\n " );
118118 }
119119 }
120- if (errors .size () == 0 ) {
120+ if (errors .isEmpty () ) {
121121 System .out .println ("This SPDX Document is valid." );
122122 } else {
123123 System .exit (ERROR_STATUS );
@@ -127,10 +127,7 @@ public static void main(String[] args) {
127127 /**
128128 * Verify a an SPDX file
129129 * @param filePath File path to the SPDX file to be verified
130- * @param fileType
131130 * @return A list of verification errors - if empty, the SPDX file is valid
132- * @throws InvalidFileNameException on invalid file name or file not found
133- * @throws IOException on IO error
134131 * @throws SpdxVerificationException where the SPDX file can not be parsed or the filename is invalid
135132 */
136133 public static List <String > verify (String filePath , SerFileType fileType ) throws SpdxVerificationException {
0 commit comments