Added mozart and a project
This commit is contained in:
1488
Data/.lift/checkstyle-cos126.xml
Normal file
1488
Data/.lift/checkstyle-cos126.xml
Normal file
File diff suppressed because it is too large
Load Diff
1326
Data/.lift/checkstyle-coursera.xml
Normal file
1326
Data/.lift/checkstyle-coursera.xml
Normal file
File diff suppressed because it is too large
Load Diff
BIN
Data/.lift/checkstyle-lift.jar
Normal file
BIN
Data/.lift/checkstyle-lift.jar
Normal file
Binary file not shown.
359
Data/.lift/checkstyle-suppressions.xml
Normal file
359
Data/.lift/checkstyle-suppressions.xml
Normal file
@@ -0,0 +1,359 @@
|
||||
<?xml version="1.0"?>
|
||||
<!DOCTYPE suppressions PUBLIC
|
||||
"-//Checkstyle//DTD SuppressionFilter Configuration 1.2//EN"
|
||||
"https://checkstyle.org/dtds/suppressions_1_2.dtd">
|
||||
|
||||
<suppressions>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- STDLIB.JAR EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<suppress checks="ParameterAssignmentCheck"
|
||||
files="(Draw|StdDraw).java"/>
|
||||
|
||||
<suppress checks="IllegalCatch"
|
||||
files="(In|StdDraw|Draw|StdAudio).java"/>
|
||||
|
||||
<suppress id="IllegalType"
|
||||
files="(StdDraw|Draw|StdIn|In|Out|StdOut).java"/>
|
||||
|
||||
<suppress id="FloatType"
|
||||
files="(StdDraw|Draw|StdIn|In|Out|StdOut|StdAudio).java"/>
|
||||
|
||||
<suppress id="BitwiseAnd"
|
||||
files="(StdRandom|BinaryStdIn|BinaryStdOut|BinaryIn|BinaryOut|StdAudio|Picture|GrayscalePicture).java"/>
|
||||
|
||||
<suppress id="BitwiseOr"
|
||||
files="(BinaryStdOut|BinaryStdIn|BinaryIn|BinaryOut).java"/>
|
||||
|
||||
<suppress id="InterfaceType"
|
||||
files="(DrawListener).java"/>
|
||||
|
||||
<suppress id="Synchronized"
|
||||
files="(StdDraw|Draw|StdAudio).java"/>
|
||||
|
||||
<suppress files="StdDraw3D.java" checks="[a-zA-Z0-9]*"/>
|
||||
|
||||
<suppress files="StdInTest.java" checks="[a-zA-Z0-9]*"/>
|
||||
|
||||
<suppress files="APIChecker.java" checks="[a-zA-Z0-9]*"/>
|
||||
|
||||
<suppress files="AutocompleteGUI.java" checks="[a-zA-Z0-9]*"/>
|
||||
|
||||
<suppress files="Keyboard.java" checks="IllegalImport|IllegalToken|StringLiteralCount|ModifiedControlVariable|MyIllegalType"/>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- ALGS4.JAR EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- phi() and Phi(), which are now deprecated -->
|
||||
<suppress checks="MethodNameCheck"
|
||||
files="(Gaussian|ErrorFunction).java"/>
|
||||
|
||||
<suppress checks="EmptyStatement"
|
||||
files="(Evaluate|Quick3stringX).java"/>
|
||||
|
||||
<!-- median of 3 -->
|
||||
<suppress checks="AvoidInlineConditionals"
|
||||
files="Quick.*.java"/>
|
||||
|
||||
<suppress checks="ParameterAssignmentCheck"
|
||||
files="(.*BST|UF|MinPQ|MaxPQ|Heap|Heapify|.*TST|Trie.*|StringSET).java"/>
|
||||
|
||||
<suppress checks="ParameterAssignmentCheck"
|
||||
files="(SuffixArrayMerge|SuffixArrayX|Manber).java"/>
|
||||
|
||||
<suppress checks="ParameterNumberCheck"
|
||||
files="TraceBentleyMcIlroyPartition.java"/>
|
||||
|
||||
<suppress checks="EmptyStatement"
|
||||
files="(QuickX).java"/>
|
||||
|
||||
<suppress id="Wrapper"
|
||||
files="(IndexMinPQ|IndexMaxPQ|AdjMatrixGraph|AdjMatrixDigraph).java"/>
|
||||
|
||||
<suppress id="Wrapper"
|
||||
files="(Autoboxing|MutableInteger|SortCompare|.*Reflection|.*OfInts|.*OfIntegers|Memory.*).java"/>
|
||||
|
||||
<suppress id="Wrapper"
|
||||
files="(KendallTau|Inversions|Distinct|SecureShuffle|PermutationInplace).java"/>
|
||||
|
||||
<!-- shifting and masking -->
|
||||
<suppress id="BitwiseAnd"
|
||||
files="(PatriciaSET|PatriciaST|LSD|MSD|HexDump|OneWay|AmericanFlag|AmericanFlagX|.*HashST).java"/>
|
||||
|
||||
<!-- intentionally buggy program -->
|
||||
<suppress checks="CovariantEquals"
|
||||
files="CovariantPhoneNumber.java"/>
|
||||
|
||||
<!-- has a deeply nested loop -->
|
||||
<suppress checks="NestedForDepth"
|
||||
files="EuclideanGraph.java"/>
|
||||
|
||||
<!-- more than one statement per line -->
|
||||
<suppress checks="OneStatementPerLine"
|
||||
files="Inversions.java"/>
|
||||
|
||||
<!-- long line -->
|
||||
<suppress checks="LineLength"
|
||||
files="Inversions.java"/>
|
||||
|
||||
<!-- methods named V() and E() -->
|
||||
<suppress checks="MethodName"
|
||||
files="(Digraph|Graph|Network|GraphX).java"/>
|
||||
|
||||
<!-- RM for RabinKarp -->
|
||||
<suppress checks="MemberName"
|
||||
files="RabinKarp.java"/>
|
||||
|
||||
<!-- Calls Math.random() -->
|
||||
<suppress id="AvoidMathRandom"
|
||||
files="Knuth.java"/>
|
||||
|
||||
<!-- Calls Math.pow(x, 0.5) -->
|
||||
<suppress id="Sqrt"
|
||||
files="Stopwatch(CPU)?.java"/>
|
||||
|
||||
<!-- Local variable named H -->
|
||||
<suppress checks="LocalVariableName"
|
||||
files="(GlobalMincut|UniqueMincut|DirectedEulerianPath|DirectedEulerianCycle|BipartiteMatchingToMaxflow).java"/>
|
||||
|
||||
<!-- Local variable named F -->
|
||||
<suppress checks="LocalVariableName"
|
||||
files="(Bipartite|BipartiteX|DirectedCycleX|EdgeWeightedDirectedCycle|TopologicalX).java"/>
|
||||
|
||||
<!-- parameters named V1 and V2 -->
|
||||
<suppress checks="ParameterName"
|
||||
files="(Digraph|Graph)Generator.java"/>
|
||||
|
||||
<!-- method named R(), now deprecated -->
|
||||
<suppress checks="MethodName"
|
||||
files="Alphabet.java"/>
|
||||
|
||||
<!-- method named R2() -->
|
||||
<suppress checks="MethodName"
|
||||
files=".*Regression.java"/>
|
||||
|
||||
<!-- copy constructor -->
|
||||
<suppress checks="HiddenField"
|
||||
files="(Digraph|Graph|Network|RabinKarp).java"/>
|
||||
|
||||
|
||||
<suppress files="MultiwayMinPQ.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files="FibonacciMinPQ.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files="BinomialMinPQ.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files="FenwickTree.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files="SegmentTree.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files="TestLayoutBug.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files=".*DualPivotQuicksort.*.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files="BentleyMcIlroyJava6.java" checks="[a-zA-Z0-9]*"/>
|
||||
<suppress files="Sort[3-6].java" checks="[a-zA-Z0-9]*"/>
|
||||
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- INTROCS.JAR EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- intentionally misindented program -->
|
||||
<suppress checks="Indentation" files="Factors2.java"/>
|
||||
|
||||
<suppress checks="ParameterNumberCheck"
|
||||
files="PlasmaCloud.*.java"/>
|
||||
|
||||
<suppress checks="SuppressWarningsCheck"
|
||||
files="(HashST|SET|Insertion|Merge).java"/>
|
||||
|
||||
<suppress checks="StringLiteralCount"
|
||||
files="(PotentialGene|Merge|Insertion|Complex|HashST|StockQuote).java"/>
|
||||
|
||||
<suppress checks="MemberNameCheck"
|
||||
files="(Graph).java"/>
|
||||
|
||||
<!-- StdRandom does some unusual things -->
|
||||
<suppress checks="IllegalImportCheck"
|
||||
files="StdRandom.java"/>
|
||||
<suppress checks="IllegalTypeCheck"
|
||||
files="StdRandom.java"/>
|
||||
<suppress checks="InnerAssignmentCheck"
|
||||
files="StdRandom.java"/>
|
||||
<suppress checks="IllegalMethodCallCheck"
|
||||
files="StdRandom.java"/>
|
||||
<suppress id="StaticInitializer"
|
||||
files="StdRandom.java"/>
|
||||
|
||||
<!-- need Double[] to pass as Comparable[] -->
|
||||
<suppress id="Wrapper"
|
||||
files="InsertionTest.java"/>
|
||||
|
||||
<!-- Calls Math.random() -->
|
||||
<suppress id="AvoidMathRandom"
|
||||
files="(CouponCollector|Coupon|Flip|Gambler|RandomInt|RandomSeq|RandomSurfer|Sample|SelfAvoidingWalk|TwentyQuestions|MusicalDiceGame|PerfectShuffle).java"/>
|
||||
|
||||
<!-- use type parameter upper and lower bounds -->
|
||||
<suppress id="TypeParameter"
|
||||
files="(BST|SET|ST).java"/>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- COS 126 PROGRAMMING ASSIGNMENT/PRECEPT EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- Calls Math.random() -->
|
||||
<suppress id="AvoidMathRandom"
|
||||
files="(RandomWalker|RandomWalkers|RollDice|RollDie|RollLoadedDie|Ball|Birthday|RandomPokerHands).java"/>
|
||||
|
||||
<!-- throw RuntimeException is ok in RingBuffer because we've just introduced exceptions -->
|
||||
<suppress checks="IllegalThrows"
|
||||
files="(RingBuffer).java"/>
|
||||
|
||||
<!-- students need ^ as xor operator in LFSR and PhotoMagic -->
|
||||
<!-- students may use bit-whacking in LFSR, but limits register size -->
|
||||
<!-- HammingEncoder, HammingDecoder, and TOY do some bit-whacking -->
|
||||
<suppress id="BitwiseAnd"
|
||||
files="(LFSR|HammingEncoder|HammingDecoder|TOY).java"/>
|
||||
<suppress id="BitwiseOr"
|
||||
files="(LFSR|HammingEncoder|HammingDecoder|TOY).java"/>
|
||||
<suppress id="BitwiseXor"
|
||||
files="(LFSR|PhotoMagic|HammingEncoder|HammingDecoder|TOY).java"/>
|
||||
|
||||
<!-- convenient to put multiple statements on one line -->
|
||||
<suppress checks="OneStatementPerLine"
|
||||
files="(TOY).java"/>
|
||||
|
||||
<!-- programming exams that uses generics (seems needed for generic types only in Checkstyle 8.14, bug?) -->
|
||||
<suppress id="Wrapper"
|
||||
files="(RollingStats|NgonArt|MiniPro|MiniPro2|Election).java"/>
|
||||
|
||||
<!-- has a quadruple nested loop -->
|
||||
<suppress checks="NestedForDepth"
|
||||
files="(KernelFilter).java"/>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- COS 226 PROGRAMMING ASSIGNMENT EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- codePost has a limit on the length of a filename -->
|
||||
<suppress id="LongFileName"
|
||||
files="(InteractivePercolationVisualizer).java"/>
|
||||
|
||||
<!-- PercolationVisualizer uses java.awt.Font -->
|
||||
<suppress checks="IllegalImport"
|
||||
files="(PercolationVisualizer).java"/>
|
||||
|
||||
<!-- has a quadruple nested loop -->
|
||||
<suppress checks="NestedForDepth"
|
||||
files="(BruteCollinearPoints|Board|SolverVisualizer).java"/>
|
||||
|
||||
<!-- UnicodeTest has non-ASCII characters in header -->
|
||||
<suppress id="NotASCII"
|
||||
files="(UnicodeTest).java"/>
|
||||
|
||||
<!-- id does not support regular expressions, so need two separate suppression statements -->
|
||||
<suppress id="FloatType"
|
||||
files="SCUtility.java"/>
|
||||
<suppress id="FloatLiteral"
|
||||
files="SCUtility.java"/>
|
||||
|
||||
<!-- x0 = x1 = StdDraw.mouseX() in RangeSearchVisualizer -->
|
||||
<suppress checks="InnerAssignmentCheck"
|
||||
files="(RangeSearchVisualizer).java"/>
|
||||
|
||||
<!-- clean implementations can use many parameters -->
|
||||
<suppress checks="ParameterNumberCheck"
|
||||
files="(EnhancedKdTreeST|KdTree|KdTreeST).java"/>
|
||||
|
||||
<!-- clean implementations can update champion variable, which is passed as an argument -->
|
||||
<suppress checks="ParameterAssignmentCheck"
|
||||
files="(EnhancedKdTreeST|KdTree|KdTreeST).java"/>
|
||||
|
||||
<!-- students might legitimately use & as bitwise and in SeamCarving, BurrowsWheeler, or MoveToFront -->
|
||||
<!-- students might legitimately use | as bitwise or operator in SeamCarving -->
|
||||
<suppress id="BitwiseAnd"
|
||||
files="(SeamCarver|BurrowsWheeler|MoveToFront).java"/>
|
||||
<suppress id="BitwiseOr"
|
||||
files="(SeamCarver|BurrowsWheeler|MoveToFront).java"/>
|
||||
|
||||
<!-- students often use Integer or Double when unit testing Deque and RandomizedQueue -->
|
||||
<suppress id="Wrapper"
|
||||
files="(Deque|RandomizedQueue|BinarySearchDeluxe).java"/>
|
||||
|
||||
<!-- students need to use Integer to check for null entry in Iterable -->
|
||||
<suppress id="Wrapper"
|
||||
files="(ShortestCommonAncestor|SAP|DeluxeBFS).java"/>
|
||||
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- IGNORE HEADER CHECKS EXCEPT ON CERTAIN FILES -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- suppress header check except on COS 126 and COS 226 required files -->
|
||||
<!-- this formatting hack seems to enable us to split regexp over several lines -->
|
||||
<suppress id="Header"
|
||||
files="^(?!.*\b(readme.txt|
|
||||
|HelloWorld.java|HiFour.java|SumThree.java|Ordered.java|GreatCircle.java|RGBtoCMYK.java|
|
||||
|Bits.java|Checkerboard.java|NoonSnooze.java|RandomWalker.java|RandomWalkers.java|RollDice.java|
|
||||
|NBody.java|
|
||||
|Transform2D.java|Sierpinski.java|Art.java|
|
||||
|LFSR.java|PhotoMagic.java|
|
||||
|RingBuffer.java|GuitarString|GuitarHero.java|
|
||||
|MarkovModel.java|TextGenerator.java|
|
||||
|Tour.java|
|
||||
|Blob.java|BeadFinder.java|BeadTracker.java|Avogadro.java|
|
||||
|Percolation.java|PercolationStats.java|
|
||||
|Deque.java|RandomizedQueue.java|Permutation.java|
|
||||
|Autocomplete.java|BinarySearchDeluxe.java|Term.java|
|
||||
|Board.java|Solver.java|
|
||||
|PointST.java|KdTreeST.java|
|
||||
|WordNet.java|ShortestCommonAncestor.java|Outcast.java|
|
||||
|SeamCarver.java|
|
||||
|MoveToFront.java|BurrowsWheeler.java)$).*$"/>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- IGNORE LINELENGTH, MAINCALLS, and COMMENT EXCEPT ON CERTAIN FILES -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
|
||||
<!-- don't require main to call directly the one public method in API -->
|
||||
<suppress checks="MainCallsAllPublicMethods"
|
||||
files="(ImageClassifier).java"/>
|
||||
|
||||
<suppress checks="LineLengthCheck|MainCallsAllPublicMethods|CommentCheck"
|
||||
files="^(?!.*(HiFour|SumThree|Ordered|GreatCircle|RGBtoCMYK|
|
||||
|Bits|Checkerboard|NoonSnooze|RandomWalker|RandomWalkers|RollDice|
|
||||
|NBody|
|
||||
|Greeting|SayHelloWorld|
|
||||
|Triangle|CMYKtoRGB|Brighter|MilitaryTime|
|
||||
|MusicLoop|MajorScale|DeluxeMajorScale|MusicalDiceGame|
|
||||
|ReverseSoundWave|Superpose|EchoFilter|PerfectShuffle|
|
||||
|ViewSoundWave|Quilt|WorldMap|SepiaFilter|
|
||||
|Synth|
|
||||
|Transform2D|Sierpinski|Art|
|
||||
|LFSR|PhotoMagic|
|
||||
|ImageClassifier|Perceptron|MultiPerceptron|
|
||||
|RingBuffer|GuitarString|GuitarHero|
|
||||
|MarkovModel|TextGenerator|
|
||||
|Tour|
|
||||
|Blob|BeadFinder|BeadTracker|Avogadro|
|
||||
|Percolation|PercolationStats|
|
||||
|Deque|RandomizedQueue|
|
||||
|Autocomplete|BinarySearchDeluxe|Term|
|
||||
|Board|Solver|
|
||||
|PointST|KdTreeST|
|
||||
|WordNet|ShortestCommonAncestor|
|
||||
|SeamCarver|
|
||||
|MoveToFront|BurrowsWheeler|
|
||||
|HelloGoodbye|RightTriangle|GreatCircle|CMYKtoRGB|
|
||||
|GeneralizedHarmonic|BandMatrix|RandomWalker|RandomWalkers|
|
||||
|DiscreteDistribution|ThueMorse|Birthday|
|
||||
|ShannonEntropy|Checkerboard|WorldMap|
|
||||
|ActivationFunction|Divisors|AudioCollage|
|
||||
|TrinomialBrute|TrinomialDP|RevesPuzzle|
|
||||
|Inversions|Ramanujan|MaximumSquareSubmatrix|
|
||||
|Huntingtons|KernelFilter|
|
||||
|ColorHSB|Clock|
|
||||
|BruteCollinearPoints|FastCollinearPoints|Point|
|
||||
|BaseballElimination|
|
||||
|BoggleSolver|
|
||||
).java$).*$"/>
|
||||
</suppressions>
|
||||
|
||||
BIN
Data/.lift/introcs.jar
Normal file
BIN
Data/.lift/introcs.jar
Normal file
Binary file not shown.
543
Data/.lift/spotbugs.xml
Normal file
543
Data/.lift/spotbugs.xml
Normal file
@@ -0,0 +1,543 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<FindBugsFilter
|
||||
xmlns="https://github.com/spotbugs/filter/3.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="https://github.com/spotbugs/filter/3.0.0 https://raw.githubusercontent.com/spotbugs/spotbugs/3.1.0/spotbugs/etc/findbugsfilter.xsd">
|
||||
|
||||
<!-- Bug descriptions: http://spotbugs.readthedocs.io/en/latest/bugDescriptions.html -->
|
||||
<!-- Filter file format: http://spotbugs.readthedocs.io/en/latest/filter.html -->
|
||||
|
||||
<!-- Match all violations. -->
|
||||
<!-- But ignore these:
|
||||
* comparator should be serializable
|
||||
* something else dealing with serialization
|
||||
* format string should use %n instead of /n
|
||||
* inner class should be static (awkard, but possible with generics)
|
||||
* using entrySet() is more efficient than keySet(), but it is awkward
|
||||
* uses non-localized toLowerCase() or toUpperCase()
|
||||
* switch statement with no default; seems OK when used for cases with (int) (4 * Math.random())
|
||||
* class naming convention (defer to Checkstyle)
|
||||
* method naming convention (defer to Checkstyle)
|
||||
* unused field (defer to PMD/IntelliJ since it highlight entire class)
|
||||
* class defines compareTo() and inherits equals()
|
||||
-->
|
||||
<Match>
|
||||
<BugPattern name="SE_COMPARATOR_SHOULD_BE_SERIALIZABLE,
|
||||
SE_BAD_FIELD,
|
||||
VA_FORMAT_STRING_USES_NEWLINE,
|
||||
SIC_INNER_SHOULD_BE_STATIC,
|
||||
WMI_WRONG_MAP_ITERATOR,
|
||||
DM_CONVERT_CASE,
|
||||
SF_SWITCH_NO_DEFAULT,
|
||||
NM_METHOD_NAMING_CONVENTION,
|
||||
NM_CLASS_NAMING_CONVENTION,
|
||||
NM_FIELD_NAMING_CONVENTION,
|
||||
EQ_COMPARETO_USE_OBJECT_EQUALS" />
|
||||
</Match>
|
||||
|
||||
<!-- from fb-contrib-7.4.3.jar plugin -->
|
||||
<!-- FCBL_FIELD_COULD_BE_LOCAL redundant with PMD -->
|
||||
<!-- PME_POOR_MANS_ENUM we disallow enum and seems to have false positives -->
|
||||
<!-- OCP_OVERLY_CONCRETE_PARAMETER wants Picture to be defines as java.awt.event.ActionListener -->
|
||||
<!-- NAB_NEEDLESS_BOXING_VALUEOF wants stack.push(Integer.valueOf(s)) instead of stack.push(Integer.parseInt(s)) -->
|
||||
<!-- CBX_CUSTOM_BUILT_XML flags StdOut.println("> " + (r1.size() == 0)); -->
|
||||
|
||||
<!-- TODO: Java 7 - replace CHARSET_NAME with java.nio.charset.StandardCharsets.UTF_8 and eliminate
|
||||
CSI_CHAR_SET_ISSUES_USE_STANDARD_CHARSET,
|
||||
CSI_CHAR_SET_ISSUES_USE_STANDARD_CHARSET_NAME,
|
||||
-->
|
||||
|
||||
<!-- TODO: use java.nio.file.Files.newInputStream and java.nio.file.Files.newOutputStream
|
||||
to eliminate IOI_USE_OF_FILE_STREAM_CONSTRUCTORS
|
||||
-->
|
||||
|
||||
<Match>
|
||||
<BugPattern name="AI_ANNOTATION_ISSUES_NEEDS_NULLABLE,
|
||||
BL_BURYING_LOGIC,
|
||||
CBX_CUSTOM_BUILT_XML,
|
||||
CC_CYCLOMATIC_COMPLEXITY,
|
||||
CE_CLASS_ENVY,
|
||||
CLI_CONSTANT_LIST_INDEX,
|
||||
CSI_CHAR_SET_ISSUES_USE_STANDARD_CHARSET,
|
||||
CSI_CHAR_SET_ISSUES_USE_STANDARD_CHARSET_NAME,
|
||||
EXS_EXCEPTION_SOFTENING_NO_CONSTRAINTS,
|
||||
FCBL_FIELD_COULD_BE_LOCAL,
|
||||
CNC_COLLECTION_NAMING_CONFUSION,
|
||||
IMC_IMMATURE_CLASS_NO_EQUALS,
|
||||
IMC_IMMATURE_CLASS_NO_PACKAGE,
|
||||
IMC_IMMATURE_CLASS_NO_TOSTRING,
|
||||
IMC_IMMATURE_CLASS_NO_HASHCODE,
|
||||
IMC_IMMATURE_CLASS_WRONG_FIELD_ORDER,
|
||||
IOI_USE_OF_FILE_STREAM_CONSTRUCTORS,
|
||||
ISB_EMPTY_STRING_APPENDING,
|
||||
ISB_INEFFICIENT_STRING_BUFFERING,
|
||||
ISB_TOSTRING_APPENDING,
|
||||
LSC_LITERAL_STRING_COMPARISON,
|
||||
MAC_MANUAL_ARRAY_COPY,
|
||||
MDM_RANDOM_SEED,
|
||||
MUI_CONTAINSKEY_BEFORE_GET,
|
||||
NAB_NEEDLESS_BOXING_VALUEOF,
|
||||
OPM_OVERLY_PERMISSIVE_METHOD,
|
||||
OCP_OVERLY_CONCRETE_PARAMETER,
|
||||
PCOA_PARTIALLY_CONSTRUCTED_OBJECT_ACCESS,
|
||||
PCAIL_POSSIBLE_CONSTANT_ALLOCATION_IN_LOOP,
|
||||
PL_PARALLEL_LISTS,
|
||||
PME_POOR_MANS_ENUM,
|
||||
PRMC_POSSIBLY_REDUNDANT_METHOD_CALLS,
|
||||
PSC_PRESIZE_COLLECTIONS,
|
||||
S508C_NON_TRANSLATABLE_STRING,
|
||||
SACM_STATIC_ARRAY_CREATED_IN_METHOD,
|
||||
SCR_SLOPPY_CLASS_REFLECTION,
|
||||
SEO_SUBOPTIMAL_EXPRESSION_ORDER,
|
||||
SPP_TEMPORARY_TRIM,
|
||||
STT_STRING_PARSING_A_FIELD,
|
||||
UCPM_USE_CHARACTER_PARAMETERIZED_METHOD,
|
||||
USBR_UNNECESSARY_STORE_BEFORE_RETURN,
|
||||
UVA_USE_VAR_ARGS,
|
||||
URF_UNREAD_FIELD,
|
||||
UUF_UNUSED_FIELD,
|
||||
WEM_WEAK_EXCEPTION_MESSAGING" />
|
||||
</Match>
|
||||
|
||||
|
||||
|
||||
<!-- Ignore DLS_DEAD_LOCAL_STORE for low-confidence warnings (3)
|
||||
Otherwise it will flag code like the following:
|
||||
for (String x : set)
|
||||
count++;
|
||||
-->
|
||||
<Match>
|
||||
<BugPattern name="DLS_DEAD_LOCAL_STORE, UWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTOR" />
|
||||
<Confidence value="3" />
|
||||
</Match>
|
||||
|
||||
<!-- Ignore SCRV_SUSPICIOUS_COMPARATOR_RETURN_VALUES for low-confidence warnings (3)
|
||||
to avoid false positives in compare() -->
|
||||
<Match>
|
||||
<BugPattern name="SCRV_SUSPICIOUS_COMPARATOR_RETURN_VALUES" />
|
||||
<Confidence value="3" />
|
||||
</Match>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- STDLIB.JAR EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*(Std)?Draw" />
|
||||
<BugPattern name="ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD, DE_MIGHT_IGNORE" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*StdAudio" />
|
||||
<BugPattern name="DM_EXIT" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*In" />
|
||||
<BugPattern name="DMI_HARDCODED_ABSOLUTE_FILENAME" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*(In|StdIn)" />
|
||||
<BugPattern name="LEST_LOST_EXCEPTION_STACK_TRACE" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*(BinaryIn|BinaryOut|BinaryStdIn|BinaryStdOut)" />
|
||||
<BugPattern name="FCCD_FIND_CLASS_CIRCULAR_DEPENDENCY" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*(BinaryOut|BinaryStdOut|Draw|Out|Picture|StdAudio|StdDraw)" />
|
||||
<BugPattern name="IMC_IMMATURE_CLASS_PRINTSTACKTRACE" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*(Draw|StdDraw)" />
|
||||
<BugPattern name="MDM_THREAD_YIELD" />
|
||||
</Match>
|
||||
|
||||
<!-- false positive -->
|
||||
<Match>
|
||||
<Class name = "~.*(StdRandom)" />
|
||||
<Method name="poisson" params="double" returns="int" />
|
||||
<BugPattern name="MRC_METHOD_RETURNS_CONSTANT" />
|
||||
</Match>
|
||||
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- INTRO TO PROGRAMMING IN JAVA EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*Bug.*" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "Confusion" />
|
||||
<BugPattern name="SA_LOCAL_SELF_ASSIGNMENT, DLS_OVERWRITTEN_INCREMENT" />
|
||||
</Match>
|
||||
|
||||
<!-- Double.valueOf() not introduced, so better to use Double.parseDouble() -->
|
||||
<Match>
|
||||
<Class name = "Evaluate" />
|
||||
<BugPattern name="NAB_NEEDLESS_BOXING_VALUEOF" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "PassByValue" />
|
||||
<BugPattern name="IP_PARAMETER_IS_DEAD_BUT_OVERWRITTEN" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "ArrayExamples" />
|
||||
<BugPattern name="DMI_INVOKING_TOSTRING_ON_ARRAY" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "PhoneNumber" />
|
||||
<BugPattern name="SA_LOCAL_SELF_COMPARISON" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "HashCode" />
|
||||
<BugPattern name="ES_COMPARING_STRINGS_WITH_EQ,DM_STRING_CTOR" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~NoBaseCase|NoConvergence" />
|
||||
<BugPattern name="IL_INFINITE_RECURSIVE_LOOP" />
|
||||
</Match>
|
||||
|
||||
<!-- Exclude Gaussian.Phi() test for floating-point equality. -->
|
||||
<Match>
|
||||
<Class name = "Gaussian" />
|
||||
<BugPattern name="FE_FLOATING_POINT_EQUALITY" />
|
||||
</Match>
|
||||
|
||||
<!-- generating random integers before StdRandom.uniform() is introduced -->
|
||||
<Match>
|
||||
<Class name = "~Coupon|CouponCollector|TwentyQuestions|Craps|Functions|
|
||||
|Mozart|Birthday|Birthdays|RollDie|SumOfTwoDice|
|
||||
|RandomStudent|Sicherman|Chaos|DiscreteDistribution|
|
||||
|MonteHall|MostLikelyRoll" />
|
||||
<BugPattern name="DM_NEXTINT_VIA_NEXTDOUBLE" />
|
||||
</Match>
|
||||
|
||||
|
||||
<!-- string concatenation before StringBuffer is introduced -->
|
||||
<Match>
|
||||
<Class name = "~RulerN|DigitReverser|Loops|LongestCommonSubsequence|
|
||||
|ThueMorse|Ordinal|DeBruijn|Soundex|Repeat|
|
||||
|Quote|CircularQuote" />
|
||||
<BugPattern name="SBSC_USE_STRINGBUFFER_CONCATENATION" />
|
||||
</Match>
|
||||
|
||||
<!-- we are measuring side effect of elapsed time -->
|
||||
<Match>
|
||||
<Class name = "DoublingTest" />
|
||||
<BugPattern name="DLS_DEAD_LOCAL_STORE" />
|
||||
</Match>
|
||||
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- ALGS4.JAR EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- techincally, need (edu\.princeton\.cs\.algs4\.)? instead of .* for package version -->
|
||||
<Match>
|
||||
<Class name = "~.*(BellmanFordSP|DijkstraSP|DynamicProgrammingSP|UniqueMincut|
|
||||
|Hungarian|DijkstraUndirectedSP)" />
|
||||
<BugPattern name="FE_FLOATING_POINT_EQUALITY" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*Doubling.*" />
|
||||
<BugPattern name="RV_RETURN_VALUE_IGNORED_NO_SIDE_EFFECT,UC_USELESS_OBJECT" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~(Autoboxing|DualPivotQuicksort)" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~Mutable(String|Integer)" />
|
||||
<BugPattern name="DP_DO_INSIDE_DO_PRIVILEGED" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~AntiQuicksorter.*" />
|
||||
<BugPattern name="HE_EQUALS_USE_HASHCODE, HE_EQUALS_NO_HASHCODE" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "BrokenShuffle" />
|
||||
<BugPattern name="DM_NEXTINT_VIA_NEXTDOUBLE" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*RabinKarp" />
|
||||
<BugPattern name="UPM_UNCALLED_PRIVATE_METHOD" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "CovariantPhoneNumber" />
|
||||
<BugPattern name="EQ_SELF_USE_OBJECT" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*MemoryOf.*" />
|
||||
<BugPattern name="DM_NUMBER_CTOR" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "Concatenate" />
|
||||
<BugPattern name="SBSC_USE_STRINGBUFFER_CONCATENATION" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~(edu.princeton.cs.algs4.)?Student" />
|
||||
<BugPattern name="SA_LOCAL_SELF_COMPARISON, EC_UNRELATED_TYPES" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~(edu.princeton.cs.algs4.)?Person" />
|
||||
<BugPattern name="SA_LOCAL_SELF_COMPARISON" />
|
||||
</Match>
|
||||
|
||||
<!-- These properly handle NaN and -0.0 -->
|
||||
<Match>
|
||||
<Class name = "~(edu.princeton.cs.algs4.)?(Transaction|Interval1D|Point2D).*" />
|
||||
<BugPattern name="FE_FLOATING_POINT_EQUALITY,CO_COMPARETO_INCORRECT_FLOATING" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~(edu.princeton.cs.algs4.)?(GaussJordanElimination|GaussianElimination)" />
|
||||
<BugPattern name="PZLA_PREFER_ZERO_LENGTH_ARRAYS" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*(SET)" />
|
||||
<BugPattern name="ITU_INAPPROPRIATE_TOSTRING_USE,OCP_OVERLY_CONCRETE_PARAMETER" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*((Index)?(Binomial|Fibonacci)(Min|Max)PQ)" />
|
||||
<BugPattern name="CFS_CONFUSING_FUNCTION_SEMANTICS" />
|
||||
</Match>
|
||||
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- COS 126 PROGRAMMING ASSIGNMENT EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- n will always be non-negative -->
|
||||
<Match>
|
||||
<Class name = "~(Checkerboard)(126)?" />
|
||||
<BugPattern name="IM_BAD_CHECK_FOR_ODD" />
|
||||
</Match>
|
||||
|
||||
<!-- generating random integers before StdRandom.uniform() is introduced -->
|
||||
<Match>
|
||||
<Class name = "~(RollDice|TenDice|RandomWalker|RandomWalkers|Art|MusicalDiceGame|PerfectShuffle)(126)?" />
|
||||
<BugPattern name="DM_NEXTINT_VIA_NEXTDOUBLE" />
|
||||
</Match>
|
||||
|
||||
<!-- ok to return null in copy() if argument is null -->
|
||||
<Match>
|
||||
<Class name = "~(Transform2D)(126)?" />
|
||||
<Method name="copy" params="double[]" returns="double[]" />
|
||||
<BugPattern name="PZLA_PREFER_ZERO_LENGTH_ARRAYS" />
|
||||
</Match>
|
||||
|
||||
<!-- GUI is side effect -->
|
||||
<Match>
|
||||
<Class name = "Keyboard" />
|
||||
<BugPattern name="DLS_DEAD_LOCAL_STORE" />
|
||||
</Match>
|
||||
|
||||
<!-- need to read m, width, and height for training images, but don't need to store -->
|
||||
<Match>
|
||||
<Class name = "ImageClassifier" />
|
||||
<BugPattern name="DLS_DEAD_LOCAL_STORE" />
|
||||
</Match>
|
||||
|
||||
<!-- false positive in LFSR with String instance variable -->
|
||||
<Match>
|
||||
<Class name = "~(LFSR)" />
|
||||
<BugPattern name="STT_TOSTRING_STORED_IN_FIELD" />
|
||||
</Match>
|
||||
|
||||
<!-- string concatenation before StringBuffer is introduced -->
|
||||
<Match>
|
||||
<Class name = "~(LFSR|MarkovModel|Perceptron|MultiPerceptron)(126)?" />
|
||||
<BugPattern name="SBSC_USE_STRINGBUFFER_CONCATENATION" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~(RingBuffer)(126)?" />
|
||||
<Method name="toString" params="" returns="java.lang.String" />
|
||||
<BugPattern name="SBSC_USE_STRINGBUFFER_CONCATENATION" />
|
||||
</Match>
|
||||
|
||||
<!--
|
||||
<Match>
|
||||
<Class name = "~(MarkovModel)(126)?" />
|
||||
<Method name="main" />
|
||||
<BugPattern name="SBSC_USE_STRINGBUFFER_CONCATENATION" />
|
||||
</Match>
|
||||
-->
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- COS 126 PROGRAMMING EXAM EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- string concatenation before StringBuffer is introduced -->
|
||||
<Match>
|
||||
<Class name = "~PokerHand|PokerHandWild|Language" />
|
||||
<BugPattern name="SBSC_USE_STRINGBUFFER_CONCATENATION" />
|
||||
</Match>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- COURSERA PROGRAMMING WITH A PURPOSE EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- generating random integers before StdRandom.uniform() is introduced -->
|
||||
<Match>
|
||||
<Class name = "~(RandomWalk|RandomWalkers|DiscreteDistribution|Minesweeper|Birthday)(126)?" />
|
||||
<BugPattern name="DM_NEXTINT_VIA_NEXTDOUBLE" />
|
||||
</Match>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- COS 226 / COURSERA PROGRAMMING ASSIGNMENT EXCEPTIONS -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- Exclude compare() by slope order in Point.java on collinear assignment -->
|
||||
<!-- It produces a warning even though it properly handles NaN -->
|
||||
<Match>
|
||||
<Class name = "~Point.*(226)?" />
|
||||
<BugPattern name="CO_COMPARETO_INCORRECT_FLOATING" />
|
||||
</Match>
|
||||
|
||||
<!-- Exclude compare() by slope order in Point.java on collinear assignment -->
|
||||
<!-- It produces a warning even though it properly handles NaN -->
|
||||
<Match>
|
||||
<Class name = "~(LineSegment)(226)?" />
|
||||
<BugPattern name="HE_HASHCODE_USE_OBJECT_EQUALS" />
|
||||
</Match>
|
||||
|
||||
<!-- ok to call x.compareTo(x) when unit testing Term -->
|
||||
<Match>
|
||||
<Class name = "~(Term)(226)?" />
|
||||
<Method name="main" />
|
||||
<BugPattern name="SA_LOCAL_SELF_COMPARISON" />
|
||||
</Match>
|
||||
|
||||
<!-- n will always be non-negative -->
|
||||
<Match>
|
||||
<Class name = "~(Board|KdTreeST|KdTree)(226)?" />
|
||||
<BugPattern name="IM_BAD_CHECK_FOR_ODD" />
|
||||
</Match>
|
||||
|
||||
<!-- ok to call board.equals(null), board.equals(string), or board.equals(board) when unit testing Board -->
|
||||
<Match>
|
||||
<Class name = "~(Board)(226)?" />
|
||||
<Method name="main" />
|
||||
<BugPattern name="EC_NULL_ARG,EC_UNRELATED_TYPES,SA_LOCAL_SELF_COMPARISON" />
|
||||
</Match>
|
||||
|
||||
<!-- slider puzzle, before we've introduced hashCode() -->
|
||||
<Match>
|
||||
<Class name = "~(Board)(226)?" />
|
||||
<BugPattern name="HE_EQUALS_USE_HASHCODE, HE_EQUALS_NO_HASHCODE" />
|
||||
</Match>
|
||||
|
||||
<!-- BST style code for insert() -->
|
||||
<Match>
|
||||
<Class name = "~(KdTree|KdTreeST)(226)?" />
|
||||
<BugPattern name="CFS_CONFUSING_FUNCTION_SEMANTICS" />
|
||||
</Match>
|
||||
|
||||
<!-- SCUtility not very well designed, but it's our class -->
|
||||
<Match>
|
||||
<Class name = "~(SCUtility)" />
|
||||
<BugPattern name="FCCD_FIND_CLASS_CIRCULAR_DEPENDENCY" />
|
||||
</Match>
|
||||
|
||||
<!-- some false positives -->
|
||||
<Match>
|
||||
<Class name = "~(SeamCarver)" />
|
||||
<BugPattern name="SLS_SUSPICIOUS_LOOP_SEARCH" />
|
||||
</Match>
|
||||
|
||||
<!-- BoggleBoard doesn't implement hashCode() or equals() and does safe test for floating-point equality -->
|
||||
<Match>
|
||||
<Class name = "~(BoggleBoard)(226)?" />
|
||||
<BugPattern name="FE_FLOATING_POINT_EQUALITY,HE_HASHCODE_USE_OBJECT_EQUALS" />
|
||||
</Match>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- AUTOGRADER -->
|
||||
<!-- *********************************************************************** -->
|
||||
|
||||
<!-- allow methods in *API to return null or false without complaints -->
|
||||
<Match>
|
||||
<Class name = "~.*API" />
|
||||
<BugPattern name="PZLA_PREFER_ZERO_LENGTH_ARRAYS,
|
||||
NP_TOSTRING_COULD_RETURN_NULL,
|
||||
UP_UNUSED_PARAMETER,
|
||||
MRC_METHOD_RETURNS_CONSTANT,
|
||||
EQ_ALWAYS_FALSE" />
|
||||
</Match>
|
||||
|
||||
<!-- allow methods to write to static instance variables ending in "count" -->
|
||||
<!-- allow methods to store operation counts that are not currently used -->
|
||||
<Match>
|
||||
<Field name = "~.*[Cc]ount" />
|
||||
<BugPattern name="ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD,
|
||||
URF_UNREAD_FIELD" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~.*TimingData" />
|
||||
<BugPattern name="FCBL_FIELD_COULD_BE_LOCAL" />
|
||||
</Match>
|
||||
|
||||
<!-- allow methods to store values in variables named "ignore.*" -->
|
||||
<Match>
|
||||
<Local name = "~.*[Ii]gnore.*" />
|
||||
<BugPattern name="DLS_DEAD_LOCAL_STORE" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~ScreenPrimitiveContainer.*" />
|
||||
<BugPattern name="HE_EQUALS_USE_HASHCODE, HE_EQUALS_NO_HASHCODE" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "LineSegment" />
|
||||
<BugPattern name="HE_EQUALS_USE_HASHCODE, HE_EQUALS_NO_HASHCODE" />
|
||||
</Match>
|
||||
|
||||
|
||||
<Match>
|
||||
<Class name = "~Test.*" />
|
||||
<Method name = "~extract.*" />
|
||||
<BugPattern name="PZLA_PREFER_ZERO_LENGTH_ARRAYS" />
|
||||
</Match>
|
||||
|
||||
<Match>
|
||||
<Class name = "~(Test|Time).*" />
|
||||
<BugPattern name="EXS_EXCEPTION_SOFTENING_RETURN_FALSE,
|
||||
RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
|
||||
</Match>
|
||||
|
||||
<!-- *********************************************************************** -->
|
||||
<!-- JAVA MATRIX PACKAGE -->
|
||||
<!-- *********************************************************************** -->
|
||||
<Match>
|
||||
<Class name = "~Jama\..*" />
|
||||
</Match>
|
||||
|
||||
|
||||
</FindBugsFilter>
|
||||
BIN
Data/.lift/stdlib.jar
Normal file
BIN
Data/.lift/stdlib.jar
Normal file
Binary file not shown.
Reference in New Issue
Block a user