< prev index next >

test/langtools/tools/javac/diags/CheckResourceKeys.java

Print this page
rev 51258 : imported patch switch.diff


 285             // system properties
 286             "application.home", // in Paths.java
 287             "env.class.path",
 288             "line.separator",
 289             "os.name",
 290             "user.dir",
 291             // file names
 292             "ct.sym",
 293             "rt.jar",
 294             "jfxrt.jar",
 295             "module-info.class",
 296             "module-info.sig",
 297             "jrt-fs.jar",
 298             // -XD option names
 299             "process.packages",
 300             "ignore.symbol.file",
 301             "fileManager.deferClose",
 302             // prefix/embedded strings
 303             "compiler.",
 304             "compiler.misc.",

 305             "opt.Xlint.desc.",
 306             "count.",
 307             "illegal.",
 308             "java.",
 309             "javac.",
 310             "verbose.",
 311             "locn."
 312     ));
 313 
 314     /**
 315      * Look for a resource that ends in this string fragment.
 316      */
 317     boolean hasMatch(Set<String> resourceKeys, String s) {
 318         for (String rk: resourceKeys) {
 319             if (rk.endsWith(s))
 320                 return true;
 321         }
 322         return false;
 323     }
 324 




 285             // system properties
 286             "application.home", // in Paths.java
 287             "env.class.path",
 288             "line.separator",
 289             "os.name",
 290             "user.dir",
 291             // file names
 292             "ct.sym",
 293             "rt.jar",
 294             "jfxrt.jar",
 295             "module-info.class",
 296             "module-info.sig",
 297             "jrt-fs.jar",
 298             // -XD option names
 299             "process.packages",
 300             "ignore.symbol.file",
 301             "fileManager.deferClose",
 302             // prefix/embedded strings
 303             "compiler.",
 304             "compiler.misc.",
 305             "compiler.misc.tree.tag.",
 306             "opt.Xlint.desc.",
 307             "count.",
 308             "illegal.",
 309             "java.",
 310             "javac.",
 311             "verbose.",
 312             "locn."
 313     ));
 314 
 315     /**
 316      * Look for a resource that ends in this string fragment.
 317      */
 318     boolean hasMatch(Set<String> resourceKeys, String s) {
 319         for (String rk: resourceKeys) {
 320             if (rk.endsWith(s))
 321                 return true;
 322         }
 323         return false;
 324     }
 325 


< prev index next >