From f807803916a24bd7c3bea20f10d599d8cf5495af Mon Sep 17 00:00:00 2001 From: Yoann Vernageau <6807151+yvrng@users.noreply.github.com> Date: Tue, 9 Apr 2024 19:05:47 +0200 Subject: [PATCH] Allow custom writer configurations in IonSystemBuilder (#781) * Allow custom writer configurations in IonSystemBuilder * Update baseline.xml with JDK 17 * fix: fix typo in javadoc Co-authored-by: Zack Slayton * fix: typo in javadoc Co-authored-by: Zack Slayton * fix: typo in javadoc Co-authored-by: Zack Slayton * Add default values on builders * Add javadoc * Add more tests on catalog * Fix tests on catalog --------- Co-authored-by: Zack Slayton Co-authored-by: Matthew Pope <81593196+popematt@users.noreply.github.com> --- build.gradle.kts | 2 +- config/spotbugs/baseline.xml | 1840 ++++++++--------- .../amazon/ion/system/IonSystemBuilder.java | 135 +- .../ion/system/IonSystemBuilderTest.java | 43 + 4 files changed, 1068 insertions(+), 952 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 773a793dd3..1d7ae0975f 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -322,7 +322,7 @@ tasks { "xsltproc", "--output", spotbugsBaselineFile, "$rootDir/config/spotbugs/baseline.xslt", - "${outputLocation.get()}/spotBugs" + "${outputLocation.get()}" ) } } diff --git a/config/spotbugs/baseline.xml b/config/spotbugs/baseline.xml index 79b19a3ce6..656a32390c 100644 --- a/config/spotbugs/baseline.xml +++ b/config/spotbugs/baseline.xml @@ -1,307 +1,307 @@ - + Possible null pointer dereference on branch that might be infeasible Possible null pointer dereference of Timestamp._fraction on branch that might be infeasible in com.amazon.ion.Timestamp.equals(Timestamp) - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.equals(Timestamp) - + In Timestamp.java Value contained in com.amazon.ion.Timestamp._fraction - - Dereferenced at Timestamp.java:[line 2794] + + Dereferenced at Timestamp.java:[line 2808] - - Known null at Timestamp.java:[line 2790] + + Known null at Timestamp.java:[line 2804] - Suspicious reference comparison - Suspicious comparison of Integer references in com.amazon.ion.Timestamp.make_localtime() + Comparaison de références suspecte + Comparaison suspecte des références com.amazon.ion.Timestamp._offset dans com.amazon.ion.Timestamp.make_localtime() - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.make_localtime() - - At Integer.java:[lines 59-1825] + + At Integer.java:[lines 71-1872] Actual type Integer - + In Timestamp.java Value loaded from field com.amazon.ion.Timestamp._offset - - At Timestamp.java:[line 1236] + + At Timestamp.java:[line 1249] Suspicious reference comparison to constant Suspicious comparison of a Integer reference to constant in com.amazon.ion.Timestamp.print(Appendable, Timestamp) - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.print(Appendable, Timestamp) - - At Integer.java:[lines 59-1825] + + At Integer.java:[lines 71-1872] Actual type Integer - + In Timestamp.java Value loaded from field com.amazon.ion.Timestamp.UNKNOWN_OFFSET - - At Timestamp.java:[line 2157] + + At Timestamp.java:[line 2171] - - Another occurrence at Timestamp.java:[line 2165] + + Another occurrence at Timestamp.java:[line 2179] - - Another occurrence at Timestamp.java:[line 2173] + + Another occurrence at Timestamp.java:[line 2187] - - Another occurrence at Timestamp.java:[line 2191] + + Another occurrence at Timestamp.java:[line 2205] Suspicious reference comparison to constant Suspicious comparison of a Integer reference to constant in com.amazon.ion.Timestamp.printZ(Appendable) - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.printZ(Appendable) - - At Integer.java:[lines 59-1825] + + At Integer.java:[lines 71-1872] Actual type Integer - + In Timestamp.java Value loaded from field com.amazon.ion.Timestamp.UNKNOWN_OFFSET - - At Timestamp.java:[line 2117] + + At Timestamp.java:[line 2131] Suspicious reference comparison to constant Suspicious comparison of a Integer reference to constant in com.amazon.ion.Timestamp.set_fields_from_calendar(Calendar, Timestamp$Precision, boolean) - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.set_fields_from_calendar(Calendar, Timestamp$Precision, boolean) - - At Integer.java:[lines 59-1825] + + At Integer.java:[lines 71-1872] Actual type Integer - + In Timestamp.java Value loaded from field com.amazon.ion.Timestamp.UNKNOWN_OFFSET - - At Timestamp.java:[line 434] + + At Timestamp.java:[line 436] - Switch statement found where one case falls through to the next case - Switch statement found in new com.amazon.ion.Timestamp(BigDecimal, Timestamp$Precision, Integer) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de new com.amazon.ion.Timestamp(BigDecimal, Timestamp$Precision, Integer) comporte un cas qui déborde sur le suivant - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method new com.amazon.ion.Timestamp(BigDecimal, Timestamp$Precision, Integer) - - At Timestamp.java:[lines 746-748] + + At Timestamp.java:[lines 757-759] - - Another occurrence at Timestamp.java:[lines 748-750] + + Another occurrence at Timestamp.java:[lines 759-761] - - Another occurrence at Timestamp.java:[lines 751-753] + + Another occurrence at Timestamp.java:[lines 762-764] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.Timestamp.clearUnusedPrecision() where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.Timestamp.clearUnusedPrecision() comporte un cas qui déborde sur le suivant - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.clearUnusedPrecision() - - At Timestamp.java:[lines 2353-2355] + + At Timestamp.java:[lines 2367-2369] - - Another occurrence at Timestamp.java:[lines 2355-2357] + + Another occurrence at Timestamp.java:[lines 2369-2371] - - Another occurrence at Timestamp.java:[lines 2358-2360] + + Another occurrence at Timestamp.java:[lines 2372-2374] Switch statement found where default case is missing Switch statement found in new com.amazon.ion.Timestamp(BigDecimal, Timestamp$Precision, Integer) where default case is missing - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method new com.amazon.ion.Timestamp(BigDecimal, Timestamp$Precision, Integer) - - At Timestamp.java:[lines 743-753] + + At Timestamp.java:[lines 754-764] Switch statement found where default case is missing Switch statement found in com.amazon.ion.Timestamp.calendarValue() where default case is missing - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.calendarValue() - - At Timestamp.java:[lines 1580-1593] + + At Timestamp.java:[lines 1594-1607] Switch statement found where default case is missing Switch statement found in com.amazon.ion.Timestamp.clearUnusedPrecision() where default case is missing - - At Timestamp.java:[lines 74-2870] + + At Timestamp.java:[lines 74-2884] In class com.amazon.ion.Timestamp - + In method com.amazon.ion.Timestamp.clearUnusedPrecision() - - At Timestamp.java:[lines 2351-2361] + + At Timestamp.java:[lines 2365-2375] Class defines clone() but doesn't implement Cloneable com.amazon.ion.impl.BlockedBuffer defines clone() but doesn't implement Cloneable - + At BlockedBuffer.java:[lines 38-1041] In class com.amazon.ion.impl.BlockedBuffer - + In method com.amazon.ion.impl.BlockedBuffer.clone() - + At BlockedBuffer.java:[lines 173-196] - Method may fail to close stream - new com.amazon.ion.impl.BlockedBuffer(InputStream) may fail to close stream + La méthode peut ne pas fermer un flux + La méthode new com.amazon.ion.impl.BlockedBuffer(InputStream) peut ne pas fermer un flux - + At BlockedBuffer.java:[lines 38-1041] In class com.amazon.ion.impl.BlockedBuffer - + In method new com.amazon.ion.impl.BlockedBuffer(InputStream) - - At OutputStream.java:[lines 48-193] + + At OutputStream.java:[lines 52-198] Need to close java.io.OutputStream - + At BlockedBuffer.java:[line 156] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream(BlockedBuffer) may expose internal representation by storing an externally mutable object into BlockedBuffer$BlockedByteOutputStream._buf + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream(BlockedBuffer) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream._buf - + At BlockedBuffer.java:[lines 1310-1656] In class com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream - + In method new com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream(BlockedBuffer) - + In BlockedBuffer.java Field com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream._buf @@ -309,25 +309,25 @@ Local variable named bb - + At BlockedBuffer.java:[line 1334] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream(BlockedBuffer, int) may expose internal representation by storing an externally mutable object into BlockedBuffer$BlockedByteOutputStream._buf + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream(BlockedBuffer, int) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream._buf - + At BlockedBuffer.java:[lines 1310-1656] In class com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream - + In method new com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream(BlockedBuffer, int) - + In BlockedBuffer.java Field com.amazon.ion.impl.BlockedBuffer$BlockedByteOutputStream._buf @@ -335,25 +335,25 @@ Local variable named bb - + At BlockedBuffer.java:[line 1349] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.BlockedBuffer$BufferedOutputStream(BlockedBuffer) may expose internal representation by storing an externally mutable object into BlockedBuffer$BufferedOutputStream._buffer + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.BlockedBuffer$BufferedOutputStream(BlockedBuffer) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.BlockedBuffer$BufferedOutputStream._buffer - + At BlockedBuffer.java:[lines 1674-1776] In class com.amazon.ion.impl.BlockedBuffer$BufferedOutputStream - + In method new com.amazon.ion.impl.BlockedBuffer$BufferedOutputStream(BlockedBuffer) - + In BlockedBuffer.java Field com.amazon.ion.impl.BlockedBuffer$BufferedOutputStream._buffer @@ -361,7 +361,7 @@ Local variable named buffer - + At BlockedBuffer.java:[line 1677] @@ -369,16 +369,16 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonBinary.lenInt(BigInteger, boolean) where default case is missing - + At IonBinary.java:[lines 42-940] In class com.amazon.ion.impl.IonBinary - + In method com.amazon.ion.impl.IonBinary.lenInt(BigInteger, boolean) - + At IonBinary.java:[lines 538-544] @@ -386,22 +386,22 @@ Condition has no effect Useless condition: it's known that longVal != Long.MIN_VALUE at this point - + At IonBinary.java:[lines 42-940] In class com.amazon.ion.impl.IonBinary - + In method com.amazon.ion.impl.IonBinary.lenInt(long) Value longVal != Long.MIN_VALUE - + Unreachable code at IonBinary.java:[line 529] - + At IonBinary.java:[line 529] @@ -409,22 +409,22 @@ Condition has no effect Useless condition: it's known that longVal >= 0 at this point - + At IonBinary.java:[lines 42-940] In class com.amazon.ion.impl.IonBinary - + In method com.amazon.ion.impl.IonBinary.lenInt(long) Value longVal >= 0 - + Unreachable code at IonBinary.java:[line 521] - + At IonBinary.java:[line 521] @@ -432,13 +432,13 @@ Condition has no effect due to the variable type Useless condition: it's always longVal >= Long.MIN_VALUE because variable type is long - + At IonBinary.java:[lines 42-940] In class com.amazon.ion.impl.IonBinary - + In method com.amazon.ion.impl.IonBinary.lenVarUInt(long) @@ -447,10 +447,10 @@ Type long - + Unreachable code at IonBinary.java:[line 454] - + At IonBinary.java:[line 454] @@ -458,195 +458,195 @@ Class defines clone() but doesn't implement Cloneable com.amazon.ion.impl.IonBinary$BufferManager defines clone() but doesn't implement Cloneable - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.clone() - + At IonBinary.java:[lines 396-398] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.IonBinary$BufferManager.buffer() may expose internal representation by returning IonBinary$BufferManager._buf + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.IonBinary$BufferManager.buffer() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.IonBinary$BufferManager._buf - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.buffer() - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._buf - + At IonBinary.java:[line 414] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.IonBinary$BufferManager.openReader() may expose internal representation by returning IonBinary$BufferManager._reader + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.IonBinary$BufferManager.openReader() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.IonBinary$BufferManager._reader - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.openReader() - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._reader - + At IonBinary.java:[line 405] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.IonBinary$BufferManager.openWriter() may expose internal representation by returning IonBinary$BufferManager._writer + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.IonBinary$BufferManager.openWriter() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.IonBinary$BufferManager._writer - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.openWriter() - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._writer - + At IonBinary.java:[line 411] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.IonBinary$BufferManager.reader() may expose internal representation by returning IonBinary$BufferManager._reader + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.IonBinary$BufferManager.reader() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.IonBinary$BufferManager._reader - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.reader() - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._reader - + At IonBinary.java:[line 415] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.IonBinary$BufferManager.reader(int) may expose internal representation by returning IonBinary$BufferManager._reader + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.IonBinary$BufferManager.reader(int) risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.IonBinary$BufferManager._reader - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.reader(int) - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._reader - + At IonBinary.java:[line 421] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.IonBinary$BufferManager.writer() may expose internal representation by returning IonBinary$BufferManager._writer + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.IonBinary$BufferManager.writer() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.IonBinary$BufferManager._writer - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.writer() - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._writer - + At IonBinary.java:[line 416] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.IonBinary$BufferManager.writer(int) may expose internal representation by returning IonBinary$BufferManager._writer + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.IonBinary$BufferManager.writer(int) risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.IonBinary$BufferManager._writer - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method com.amazon.ion.impl.IonBinary$BufferManager.writer(int) - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._writer - + At IonBinary.java:[line 426] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.IonBinary$BufferManager(BlockedBuffer) may expose internal representation by storing an externally mutable object into IonBinary$BufferManager._buf + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.IonBinary$BufferManager(BlockedBuffer) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.IonBinary$BufferManager._buf - + At IonBinary.java:[lines 322-437] In class com.amazon.ion.impl.IonBinary$BufferManager - + In method new com.amazon.ion.impl.IonBinary$BufferManager(BlockedBuffer) - + In IonBinary.java Field com.amazon.ion.impl.IonBinary$BufferManager._buf @@ -654,52 +654,24 @@ Local variable named buf - + At IonBinary.java:[line 334] - - Method invokes inefficient Number constructor; use static valueOf instead - com.amazon.ion.impl.IonBinary$Reader.readVarIntWithNegativeZero() invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead - - - At IonBinary.java:[lines 942-1815] - - In class com.amazon.ion.impl.IonBinary$Reader - - - - In method com.amazon.ion.impl.IonBinary$Reader.readVarIntWithNegativeZero() - - - - Called method new Integer(int) - - - - Should call Integer.valueOf(int) instead - - - At IonBinary.java:[line 1519] - - - Another occurrence at IonBinary.java:[line 1523] - - - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonBinary$Reader.readIntAsInt(int) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonBinary$Reader.readIntAsInt(int) comporte un cas qui déborde sur le suivant - + At IonBinary.java:[lines 942-1815] In class com.amazon.ion.impl.IonBinary$Reader - + In method com.amazon.ion.impl.IonBinary$Reader.readIntAsInt(int) - + At IonBinary.java:[lines 1237-1239] @@ -707,16 +679,16 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonBinary$Reader.readIntAsInt(int) where default case is missing - + At IonBinary.java:[lines 942-1815] In class com.amazon.ion.impl.IonBinary$Reader - + In method com.amazon.ion.impl.IonBinary$Reader.readIntAsInt(int) - + At IonBinary.java:[lines 1229-1243] @@ -724,30 +696,30 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonBinary$Reader.readIntAsLong(int) where default case is missing - + At IonBinary.java:[lines 942-1815] In class com.amazon.ion.impl.IonBinary$Reader - + In method com.amazon.ion.impl.IonBinary$Reader.readIntAsLong(int) - + At IonBinary.java:[lines 1177-1204] - Incompatible bit masks - Incompatible bit masks in (e & 0x80 == 0x40) yields a constant result in com.amazon.ion.impl.IonBinary$Writer.writeIntValue(long) + Masques binaires incompatibles + Des masques binaires incompatibles renvoient un résultat constant dans com.amazon.ion.impl.IonBinary$Writer.writeIntValue(long) - + At IonBinary.java:[lines 1819-2917] In class com.amazon.ion.impl.IonBinary$Writer - + In method com.amazon.ion.impl.IonBinary$Writer.writeIntValue(long) @@ -756,396 +728,343 @@ Value 0x40 - + At IonBinary.java:[line 2433] - - Iterator next() method cannot throw NoSuchElementException - com.amazon.ion.impl.IonReaderBinaryIncremental$2.next() cannot throw NoSuchElementException - - - At IonReaderBinaryIncremental.java:[lines 1846-1860] - - In class com.amazon.ion.impl.IonReaderBinaryIncremental$2 - - - - In method com.amazon.ion.impl.IonReaderBinaryIncremental$2.next() - - - At IonReaderBinaryIncremental.java:[line 1855] - - - - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderBinaryRawX.has_next_helper_raw() where one case falls through to the next case - - - At IonReaderBinaryRawX.java:[lines 55-1354] - - In class com.amazon.ion.impl.IonReaderBinaryRawX - - - - In method com.amazon.ion.impl.IonReaderBinaryRawX.has_next_helper_raw() - - - At IonReaderBinaryRawX.java:[lines 327-330] - - - - Unread field - Unread field: com.amazon.ion.impl.IonReaderLookaheadBuffer.currentNumberOfAnnotations - - - At IonReaderLookaheadBuffer.java:[lines 22-956] - - In class com.amazon.ion.impl.IonReaderLookaheadBuffer - - - - In IonReaderLookaheadBuffer.java - - Field com.amazon.ion.impl.IonReaderLookaheadBuffer.currentNumberOfAnnotations - - - At IonReaderLookaheadBuffer.java:[line 285] - - - Method concatenates strings using + in a loop - com.amazon.ion.impl.IonReaderTextRawTokensX.peekNullTypeSymbolUndo(int[], int) concatenates strings using + in a loop + La méthode concatène des chaînes au moyen de + en boucle + La méthode com.amazon.ion.impl.IonReaderTextRawTokensX.peekNullTypeSymbolUndo(int[], int) concatène des chaînes au moyen de + en boucle - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.peekNullTypeSymbolUndo(int[], int) - - At IonReaderTextRawTokensX.java:[line 424] + + At IonReaderTextRawTokensX.java:[line 429] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.load_double_quoted_string(StringBuilder, boolean) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.load_double_quoted_string(StringBuilder, boolean) comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.load_double_quoted_string(StringBuilder, boolean) - - At IonReaderTextRawTokensX.java:[lines 2039-2041] + + At IonReaderTextRawTokensX.java:[lines 2057-2059] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.load_fixed_digits(StringBuilder, int) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.load_fixed_digits(StringBuilder, int) comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.load_fixed_digits(StringBuilder, int) - - At IonReaderTextRawTokensX.java:[lines 1707-1710] + + At IonReaderTextRawTokensX.java:[lines 1725-1728] - - Another occurrence at IonReaderTextRawTokensX.java:[lines 1712-1715] + + Another occurrence at IonReaderTextRawTokensX.java:[lines 1730-1733] - - Another occurrence at IonReaderTextRawTokensX.java:[lines 1717-1720] + + Another occurrence at IonReaderTextRawTokensX.java:[lines 1735-1738] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.load_single_quoted_string(StringBuilder, boolean) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.load_single_quoted_string(StringBuilder, boolean) comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.load_single_quoted_string(StringBuilder, boolean) - - At IonReaderTextRawTokensX.java:[lines 1955-1959] + + At IonReaderTextRawTokensX.java:[lines 1973-1977] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.read_base64_byte_helper() where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.read_base64_byte_helper() comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.read_base64_byte_helper() - - At IonReaderTextRawTokensX.java:[lines 2561-2564] + + At IonReaderTextRawTokensX.java:[lines 2579-2582] - - Another occurrence at IonReaderTextRawTokensX.java:[lines 2565-2568] + + Another occurrence at IonReaderTextRawTokensX.java:[lines 2583-2586] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_double_quoted_string_helper() where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.skip_double_quoted_string_helper() comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_double_quoted_string_helper() - - At IonReaderTextRawTokensX.java:[lines 2001-2006] + + At IonReaderTextRawTokensX.java:[lines 2019-2024] - - Another occurrence at IonReaderTextRawTokensX.java:[lines 2006-2008] + + Another occurrence at IonReaderTextRawTokensX.java:[lines 2024-2026] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_over_container(int) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.skip_over_container(int) comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_over_container(int) - - At IonReaderTextRawTokensX.java:[lines 1215-1219] + + At IonReaderTextRawTokensX.java:[lines 1225-1229] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_single_quoted_string(UnifiedSavePointManagerX$SavePoint) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.skip_single_quoted_string(UnifiedSavePointManagerX$SavePoint) comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_single_quoted_string(UnifiedSavePointManagerX$SavePoint) - - At IonReaderTextRawTokensX.java:[lines 1919-1921] + + At IonReaderTextRawTokensX.java:[lines 1937-1939] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_triple_quoted_string(UnifiedSavePointManagerX$SavePoint, IonReaderTextRawTokensX$CommentStrategy) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawTokensX.skip_triple_quoted_string(UnifiedSavePointManagerX$SavePoint, IonReaderTextRawTokensX$CommentStrategy) comporte un cas qui déborde sur le suivant - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_triple_quoted_string(UnifiedSavePointManagerX$SavePoint, IonReaderTextRawTokensX$CommentStrategy) - - At IonReaderTextRawTokensX.java:[lines 2137-2139] + + At IonReaderTextRawTokensX.java:[lines 2155-2157] Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.read_escaped_char_content_helper(int, boolean) where default case is missing - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.read_escaped_char_content_helper(int, boolean) - - At IonReaderTextRawTokensX.java:[lines 2472-2491] + + At IonReaderTextRawTokensX.java:[lines 2490-2509] Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_block_comment() where default case is missing - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_block_comment() - - At IonReaderTextRawTokensX.java:[lines 935-948] + + At IonReaderTextRawTokensX.java:[lines 940-953] Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_double_quoted_string_helper() where default case is missing - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_double_quoted_string_helper() - - At IonReaderTextRawTokensX.java:[lines 1999-2010] + + At IonReaderTextRawTokensX.java:[lines 2017-2028] Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_single_quoted_string(UnifiedSavePointManagerX$SavePoint) where default case is missing - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_single_quoted_string(UnifiedSavePointManagerX$SavePoint) - - At IonReaderTextRawTokensX.java:[lines 1918-1926] + + At IonReaderTextRawTokensX.java:[lines 1936-1944] Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonReaderTextRawTokensX.skip_triple_quoted_string(UnifiedSavePointManagerX$SavePoint, IonReaderTextRawTokensX$CommentStrategy) where default case is missing - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.skip_triple_quoted_string(UnifiedSavePointManagerX$SavePoint, IonReaderTextRawTokensX$CommentStrategy) - - At IonReaderTextRawTokensX.java:[lines 2135-2158] + + At IonReaderTextRawTokensX.java:[lines 2153-2176] Condition has no effect Useless condition: it's known that c != -1 at this point - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.read_base64_getchar_helper(int) Value c != -1 - - Unreachable code at IonReaderTextRawTokensX.java:[line 2577] + + Unreachable code at IonReaderTextRawTokensX.java:[line 2595] - - At IonReaderTextRawTokensX.java:[line 2576] + + At IonReaderTextRawTokensX.java:[line 2594] Condition has no effect Useless condition: it's known that c != 125 ('}') at this point - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.read_base64_getchar_helper(int) Value c != 125 ('}') - - Unreachable code at IonReaderTextRawTokensX.java:[line 2577] + + Unreachable code at IonReaderTextRawTokensX.java:[line 2595] - - At IonReaderTextRawTokensX.java:[line 2576] + + At IonReaderTextRawTokensX.java:[line 2594] Condition has no effect Useless condition: it's known that len <= 0 at this point - - At IonReaderTextRawTokensX.java:[lines 65-2897] + + At IonReaderTextRawTokensX.java:[lines 66-2915] In class com.amazon.ion.impl.IonReaderTextRawTokensX - + In method com.amazon.ion.impl.IonReaderTextRawTokensX.read_hex_escape_sequence_value(int) Value len <= 0 - - Unreachable code at IonReaderTextRawTokensX.java:[line 2510] + + Unreachable code at IonReaderTextRawTokensX.java:[line 2528] - - At IonReaderTextRawTokensX.java:[line 2509] + + At IonReaderTextRawTokensX.java:[line 2527] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonReaderTextRawX.parseSymbolToken(String, StringBuilder, int) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonReaderTextRawX.parseSymbolToken(String, StringBuilder, int) comporte un cas qui déborde sur le suivant - - At IonReaderTextRawX.java:[lines 72-1440] + + At IonReaderTextRawX.java:[lines 72-1446] In class com.amazon.ion.impl.IonReaderTextRawX - + In method com.amazon.ion.impl.IonReaderTextRawX.parseSymbolToken(String, StringBuilder, int) - + At IonReaderTextRawX.java:[lines 756-758] @@ -1153,22 +1072,22 @@ Condition has no effect Useless condition: it's known that c >= 65535 (0xffff) at this point - + At IonTokenConstsX.java:[lines 27-951] In class com.amazon.ion.impl.IonTokenConstsX - + In method com.amazon.ion.impl.IonTokenConstsX.escapeSequence(int) Value c >= 65535 (0xffff) - + Unreachable code at IonTokenConstsX.java:[line 401] - + At IonTokenConstsX.java:[line 400] @@ -1176,39 +1095,39 @@ Condition has no effect Useless condition: it's known that c <= 1114111 (0x10ffff) at this point - + At IonTokenConstsX.java:[lines 27-951] In class com.amazon.ion.impl.IonTokenConstsX - + In method com.amazon.ion.impl.IonTokenConstsX.escapeSequence(int) Value c <= 1114111 (0x10ffff) - + At IonTokenConstsX.java:[line 388] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.IonTokenReader.readEscapedCharacter(PushbackReader, boolean) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.IonTokenReader.readEscapedCharacter(PushbackReader, boolean) comporte un cas qui déborde sur le suivant - + At IonTokenReader.java:[lines 41-1620] In class com.amazon.ion.impl.IonTokenReader - + In method com.amazon.ion.impl.IonTokenReader.readEscapedCharacter(PushbackReader, boolean) - + At IonTokenReader.java:[lines 1167-1171] - + Another occurrence at IonTokenReader.java:[lines 1179-1183] @@ -1216,35 +1135,35 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonTokenReader.matchKeyword(StringBuilder, int, int) where default case is missing - + At IonTokenReader.java:[lines 41-1620] In class com.amazon.ion.impl.IonTokenReader - + In method com.amazon.ion.impl.IonTokenReader.matchKeyword(StringBuilder, int, int) - + At IonTokenReader.java:[lines 724-756] - Comparison of String objects using == or != - Comparison of String objects using == or != in com.amazon.ion.impl.IonTokenReader$Type.setNumericValue(IonTokenReader, String) + Comparaison d'objets String utilisant == ou != + Comparaison d'objets String utilisant == ou != dans com.amazon.ion.impl.IonTokenReader$Type.setNumericValue(IonTokenReader, String) - + At IonTokenReader.java:[lines 54-209] In class com.amazon.ion.impl.IonTokenReader$Type - + In method com.amazon.ion.impl.IonTokenReader$Type.setNumericValue(IonTokenReader, String) - - At String.java:[lines 125-3345] + + At String.java:[lines 140-4657] Actual type String @@ -1254,64 +1173,64 @@ Value loaded from eFormat - + At IonTokenReader.java:[line 184] - Class names should start with an upper case letter - The class name com.amazon.ion.impl.IonTokenReader$Type$timeinfo doesn't start with an upper case letter + Nom de classe devant commencer par une majuscule + Le nom de la classe com.amazon.ion.impl.IonTokenReader$Type$timeinfo ne commence pas par une majusucle - + At IonTokenReader.java:[lines 132-143] In class com.amazon.ion.impl.IonTokenReader$Type$timeinfo - + At IonTokenReader.java:[lines 132-143] - Bitwise OR of signed byte value - Bitwise OR of signed byte value computed in com.amazon.ion.impl.IonUTF8.getAs4BytesReversed(int) + Ou binaire d'un octet signé + Ou binaire d'un octet signé calculé dans com.amazon.ion.impl.IonUTF8.getAs4BytesReversed(int) - + At IonUTF8.java:[lines 35-406] In class com.amazon.ion.impl.IonUTF8 - + In method com.amazon.ion.impl.IonUTF8.getAs4BytesReversed(int) - + At IonUTF8.java:[line 179] - + Another occurrence at IonUTF8.java:[line 183] - + Another occurrence at IonUTF8.java:[line 188] - Bitwise OR of signed byte value - Bitwise OR of signed byte value computed in com.amazon.ion.impl.IonUTF8.packBytesAfter1(int, int) + Ou binaire d'un octet signé + Ou binaire d'un octet signé calculé dans com.amazon.ion.impl.IonUTF8.packBytesAfter1(int, int) - + At IonUTF8.java:[lines 35-406] In class com.amazon.ion.impl.IonUTF8 - + In method com.amazon.ion.impl.IonUTF8.packBytesAfter1(int, int) - + At IonUTF8.java:[line 262] - + Another occurrence at IonUTF8.java:[line 266] @@ -1319,111 +1238,111 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.IonUTF8.convertToUTF8Bytes(int, byte[], int, int) where default case is missing - + At IonUTF8.java:[lines 35-406] In class com.amazon.ion.impl.IonUTF8 - + In method com.amazon.ion.impl.IonUTF8.convertToUTF8Bytes(int, byte[], int, int) - + At IonUTF8.java:[lines 214-235] - Nullcheck of value previously dereferenced - Nullcheck of IonWriterSystemBinary._patch at line 518 of value previously dereferenced in com.amazon.ion.impl.IonWriterSystemBinary.closeValue() + Test de nullité d'une valeur préalablement déréférencée + Test de nullité dans com.amazon.ion.impl.IonWriterSystemBinary._patch d'une valeur préalablement déréférencée dans com.amazon.ion.impl.IonWriterSystemBinary.closeValue() - - At IonWriterSystemBinary.java:[lines 40-1048] + + At IonWriterSystemBinary.java:[lines 40-1049] In class com.amazon.ion.impl.IonWriterSystemBinary - + In method com.amazon.ion.impl.IonWriterSystemBinary.closeValue() - + In IonWriterSystemBinary.java Value loaded from field com.amazon.ion.impl.IonWriterSystemBinary._patch - - At IonWriterSystemBinary.java:[line 517] + + At IonWriterSystemBinary.java:[line 518] - - Redundant null check at IonWriterSystemBinary.java:[line 518] + + Redundant null check at IonWriterSystemBinary.java:[line 519] - Inconsistent synchronization - Inconsistent synchronization of com.amazon.ion.impl.LocalSymbolTable.mySymbolNames; locked 75% of time + Synchronisation incohérente + Synchronisation incohérente de com.amazon.ion.impl.LocalSymbolTable.mySymbolNames; verrouillée à 58% - - At LocalSymbolTable.java:[lines 53-874] + + At LocalSymbolTable.java:[lines 52-863] In class com.amazon.ion.impl.LocalSymbolTable - + In LocalSymbolTable.java Field com.amazon.ion.impl.LocalSymbolTable.mySymbolNames - - Synchronized 75% of the time + + Synchronized 58% of the time - - Unsynchronized access at LocalSymbolTable.java:[line 856] + + Unsynchronized access at LocalSymbolTable.java:[line 845] + + + Unsynchronized access at LocalSymbolTable.java:[line 849] + + + Unsynchronized access at LocalSymbolTable.java:[line 859] - - Unsynchronized access at LocalSymbolTable.java:[line 860] + + Unsynchronized access at LocalSymbolTable.java:[line 143] - - Unsynchronized access at LocalSymbolTable.java:[line 870] + + Unsynchronized access at LocalSymbolTable.java:[line 145] - + Synchronized access at LocalSymbolTable.java:[line 424] - + Synchronized access at LocalSymbolTable.java:[line 555] - + Synchronized access at LocalSymbolTable.java:[line 575] - + Synchronized access at LocalSymbolTable.java:[line 563] - + Synchronized access at LocalSymbolTable.java:[line 564] - - Synchronized access at LocalSymbolTable.java:[line 144] - - - Synchronized access at LocalSymbolTable.java:[line 146] - - + Synchronized access at LocalSymbolTable.java:[line 494] - + Synchronized access at LocalSymbolTable.java:[line 401] - Inconsistent synchronization - Inconsistent synchronization of com.amazon.ion.impl.LocalSymbolTable.mySymbolsCount; locked 81% of time + Synchronisation incohérente + Synchronisation incohérente de com.amazon.ion.impl.LocalSymbolTable.mySymbolsCount; verrouillée à 81% - - At LocalSymbolTable.java:[lines 53-874] + + At LocalSymbolTable.java:[lines 52-863] In class com.amazon.ion.impl.LocalSymbolTable - + In LocalSymbolTable.java Field com.amazon.ion.impl.LocalSymbolTable.mySymbolsCount @@ -1431,83 +1350,55 @@ Synchronized 81% of the time - - Unsynchronized access at LocalSymbolTable.java:[line 848] + + Unsynchronized access at LocalSymbolTable.java:[line 837] - - Unsynchronized access at LocalSymbolTable.java:[line 854] + + Unsynchronized access at LocalSymbolTable.java:[line 843] - + Synchronized access at LocalSymbolTable.java:[line 379] - + Synchronized access at LocalSymbolTable.java:[line 555] - + Synchronized access at LocalSymbolTable.java:[line 557] - + Synchronized access at LocalSymbolTable.java:[line 575] - + Synchronized access at LocalSymbolTable.java:[line 570] - + Synchronized access at LocalSymbolTable.java:[line 576] - + Synchronized access at LocalSymbolTable.java:[line 576] - + Synchronized access at LocalSymbolTable.java:[line 563] - + Synchronized access at LocalSymbolTable.java:[line 401] - - Method invokes inefficient Number constructor; use static valueOf instead - com.amazon.ion.impl.SimpleByteBuffer$SimpleByteReader.readVarInteger() invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead - - - At SimpleByteBuffer.java:[lines 135-660] - - In class com.amazon.ion.impl.SimpleByteBuffer$SimpleByteReader - - - - In method com.amazon.ion.impl.SimpleByteBuffer$SimpleByteReader.readVarInteger() - - - - Called method new Integer(int) - - - - Should call Integer.valueOf(int) instead - - - At SimpleByteBuffer.java:[line 372] - - - Another occurrence at SimpleByteBuffer.java:[line 376] - - - Method call passes null for non-null parameter - Null passed for non-null parameter of com.amazon.ion.Timestamp.createFromUtcFields(Timestamp$Precision, int, int, int, int, int, int, BigDecimal, Integer) in com.amazon.ion.impl.SimpleByteBuffer$SimpleByteReader.readTimestamp(int) + Méthode passant null à un paramètre déréférencé inconditionnellement + L'appel de méthode dans com.amazon.ion.impl.SimpleByteBuffer$SimpleByteReader.readTimestamp(int) passe null à un paramètre de com.amazon.ion.Timestamp.createFromUtcFields(Timestamp$Precision, int, int, int, int, int, int, BigDecimal, Integer) déréférencé de façon inconditionnelle - + At SimpleByteBuffer.java:[lines 135-660] In class com.amazon.ion.impl.SimpleByteBuffer$SimpleByteReader - + In method com.amazon.ion.impl.SimpleByteBuffer$SimpleByteReader.readTimestamp(int) - + Called method com.amazon.ion.Timestamp.createFromUtcFields(Timestamp$Precision, int, int, int, int, int, int, BigDecimal, Integer) @@ -1516,37 +1407,37 @@ Value loaded from p - + Method invoked at SimpleByteBuffer.java:[line 559] - + Null value at SimpleByteBuffer.java:[line 509] - + Known null at SimpleByteBuffer.java:[line 521] - Switch statement found where one case falls through to the next case - Switch statement found in com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarInt(int, int, boolean) where one case falls through to the next case + Un switch comporte un cas qui déborde sur le suivant + Un switch de com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarInt(int, int, boolean) comporte un cas qui déborde sur le suivant - + At SimpleByteBuffer.java:[lines 841-1383] In class com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter - + In method com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarInt(int, int, boolean) - + At SimpleByteBuffer.java:[lines 987-988] - + Another occurrence at SimpleByteBuffer.java:[lines 988-989] - + Another occurrence at SimpleByteBuffer.java:[lines 989-990] @@ -1554,16 +1445,16 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeULong(long, int) where default case is missing - + At SimpleByteBuffer.java:[lines 841-1383] In class com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter - + In method com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeULong(long, int) - + At SimpleByteBuffer.java:[lines 1179-1187] @@ -1571,16 +1462,16 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarInt(int, int, boolean) where default case is missing - + At SimpleByteBuffer.java:[lines 841-1383] In class com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter - + In method com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarInt(int, int, boolean) - + At SimpleByteBuffer.java:[lines 986-990] @@ -1588,16 +1479,16 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarInt(long, int, boolean) where default case is missing - + At SimpleByteBuffer.java:[lines 841-1383] In class com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter - + In method com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarInt(long, int, boolean) - + At SimpleByteBuffer.java:[lines 1123-1133] @@ -1605,34 +1496,34 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarUInt(int, int, boolean) where default case is missing - + At SimpleByteBuffer.java:[lines 841-1383] In class com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter - + In method com.amazon.ion.impl.SimpleByteBuffer$SimpleByteWriter.writeVarUInt(int, int, boolean) - + At SimpleByteBuffer.java:[lines 1020-1030] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.UnifiedDataPageX$Bytes(byte[], int, int) may expose internal representation by storing an externally mutable object into UnifiedDataPageX$Bytes._bytes + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.UnifiedDataPageX$Bytes(byte[], int, int) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.UnifiedDataPageX$Bytes._bytes - + At UnifiedDataPageX.java:[lines 168-204] In class com.amazon.ion.impl.UnifiedDataPageX$Bytes - + In method new com.amazon.ion.impl.UnifiedDataPageX$Bytes(byte[], int, int) - + In UnifiedDataPageX.java Field com.amazon.ion.impl.UnifiedDataPageX$Bytes._bytes @@ -1640,25 +1531,25 @@ Local variable named bytes - + At UnifiedDataPageX.java:[line 175] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.UnifiedDataPageX$Chars(char[], int, int) may expose internal representation by storing an externally mutable object into UnifiedDataPageX$Chars._characters + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.UnifiedDataPageX$Chars(char[], int, int) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.UnifiedDataPageX$Chars._characters - + At UnifiedDataPageX.java:[lines 210-251] In class com.amazon.ion.impl.UnifiedDataPageX$Chars - + In method new com.amazon.ion.impl.UnifiedDataPageX$Chars(char[], int, int) - + In UnifiedDataPageX.java Field com.amazon.ion.impl.UnifiedDataPageX$Chars._characters @@ -1666,25 +1557,25 @@ Local variable named chars - + At UnifiedDataPageX.java:[line 217] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl._Private_FastAppendableDecorator(_Private_FastAppendable) may expose internal representation by storing an externally mutable object into _Private_FastAppendableDecorator.myOutput + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl._Private_FastAppendableDecorator(_Private_FastAppendable) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_FastAppendableDecorator.myOutput - + At _Private_FastAppendableDecorator.java:[lines 31-100] In class com.amazon.ion.impl._Private_FastAppendableDecorator - + In method new com.amazon.ion.impl._Private_FastAppendableDecorator(_Private_FastAppendable) - + In _Private_FastAppendableDecorator.java Field com.amazon.ion.impl._Private_FastAppendableDecorator.myOutput @@ -1692,113 +1583,113 @@ Local variable named output - + At _Private_FastAppendableDecorator.java:[line 32] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl._Private_IonBinaryWriterBuilder.getInitialSymbolTable() may expose internal representation by returning _Private_IonBinaryWriterBuilder.myInitialSymbolTable + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_IonBinaryWriterBuilder.getInitialSymbolTable() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl._Private_IonBinaryWriterBuilder.myInitialSymbolTable - - At _Private_IonBinaryWriterBuilder.java:[lines 39-384] + + At _Private_IonBinaryWriterBuilder.java:[lines 39-414] In class com.amazon.ion.impl._Private_IonBinaryWriterBuilder - + In method com.amazon.ion.impl._Private_IonBinaryWriterBuilder.getInitialSymbolTable() - + In _Private_IonBinaryWriterBuilder.java Field com.amazon.ion.impl._Private_IonBinaryWriterBuilder.myInitialSymbolTable - + At _Private_IonBinaryWriterBuilder.java:[line 135] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_IonBinaryWriterBuilder.setInitialSymbolTable(SymbolTable) may expose internal representation by storing an externally mutable object into _Private_IonBinaryWriterBuilder.myInitialSymbolTable + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_IonBinaryWriterBuilder.setInitialSymbolTable(SymbolTable) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_IonBinaryWriterBuilder.myInitialSymbolTable - - At _Private_IonBinaryWriterBuilder.java:[lines 39-384] + + At _Private_IonBinaryWriterBuilder.java:[lines 39-414] In class com.amazon.ion.impl._Private_IonBinaryWriterBuilder - + In method com.amazon.ion.impl._Private_IonBinaryWriterBuilder.setInitialSymbolTable(SymbolTable) - + In _Private_IonBinaryWriterBuilder.java Field com.amazon.ion.impl._Private_IonBinaryWriterBuilder.myInitialSymbolTable - + Local variable named symtab - + At _Private_IonBinaryWriterBuilder.java:[line 179] - Field is a mutable array - com.amazon.ion.impl._Private_IonConstants.BINARY_VERSION_MARKER_1_0 is a mutable array + Un champ est un tableau modifiable + com.amazon.ion.impl._Private_IonConstants.BINARY_VERSION_MARKER_1_0 est un tableau modifiable - - At _Private_IonConstants.java:[lines 23-275] + + At _Private_IonConstants.java:[lines 23-282] In class com.amazon.ion.impl._Private_IonConstants - + In _Private_IonConstants.java Field com.amazon.ion.impl._Private_IonConstants.BINARY_VERSION_MARKER_1_0 - - At _Private_IonConstants.java:[line 103] + + At _Private_IonConstants.java:[line 111] - Field is a mutable array - com.amazon.ion.impl._Private_IonTextAppender.ZERO_PADDING is a mutable array + Un champ est un tableau modifiable + com.amazon.ion.impl._Private_IonTextAppender.ZERO_PADDING est un tableau modifiable - - At _Private_IonTextAppender.java:[lines 43-1008] + + At _Private_IonTextAppender.java:[lines 43-1032] In class com.amazon.ion.impl._Private_IonTextAppender - + In _Private_IonTextAppender.java Field com.amazon.ion.impl._Private_IonTextAppender.ZERO_PADDING - + At _Private_IonTextAppender.java:[line 111] - Field should be package protected - com.amazon.ion.impl._Private_IonTextAppender.OPERATOR_CHAR_FLAGS should be package protected + Un champ devrait être package protected + com.amazon.ion.impl._Private_IonTextAppender.OPERATOR_CHAR_FLAGS devrait être package protected - - At _Private_IonTextAppender.java:[lines 43-1008] + + At _Private_IonTextAppender.java:[lines 43-1032] In class com.amazon.ion.impl._Private_IonTextAppender - + In _Private_IonTextAppender.java Field com.amazon.ion.impl._Private_IonTextAppender.OPERATOR_CHAR_FLAGS - + At _Private_IonTextAppender.java:[line 98] @@ -1806,76 +1697,76 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl._Private_IonTextAppender.isIdentifierKeyword(CharSequence) where default case is missing - - At _Private_IonTextAppender.java:[lines 43-1008] + + At _Private_IonTextAppender.java:[lines 43-1032] In class com.amazon.ion.impl._Private_IonTextAppender - + In method com.amazon.ion.impl._Private_IonTextAppender.isIdentifierKeyword(CharSequence) - + At _Private_IonTextAppender.java:[lines 421-460] - Field isn't final but should be - com.amazon.ion.impl._Private_IonTextWriterBuilder.STANDARD isn't final but should be + Un champ n'est pas final alors qu'il devrait l'être + com.amazon.ion.impl._Private_IonTextWriterBuilder.STANDARD n'est pas final mais devrait l'être - - At _Private_IonTextWriterBuilder.java:[lines 33-314] + + At _Private_IonTextWriterBuilder.java:[lines 33-329] In class com.amazon.ion.impl._Private_IonTextWriterBuilder - + In _Private_IonTextWriterBuilder.java Field com.amazon.ion.impl._Private_IonTextWriterBuilder.STANDARD - + At _Private_IonTextWriterBuilder.java:[line 44] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl._Private_MarkupCallback.getAppendable() may expose internal representation by returning _Private_MarkupCallback.myAppendable + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_MarkupCallback.getAppendable() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl._Private_MarkupCallback.myAppendable - + At _Private_MarkupCallback.java:[lines 190-351] In class com.amazon.ion.impl._Private_MarkupCallback - + In method com.amazon.ion.impl._Private_MarkupCallback.getAppendable() - + In _Private_MarkupCallback.java Field com.amazon.ion.impl._Private_MarkupCallback.myAppendable - + At _Private_MarkupCallback.java:[line 200] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl._Private_MarkupCallback(_Private_FastAppendable) may expose internal representation by storing an externally mutable object into _Private_MarkupCallback.myAppendable + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl._Private_MarkupCallback(_Private_FastAppendable) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_MarkupCallback.myAppendable - + At _Private_MarkupCallback.java:[lines 190-351] In class com.amazon.ion.impl._Private_MarkupCallback - + In method new com.amazon.ion.impl._Private_MarkupCallback(_Private_FastAppendable) - + In _Private_MarkupCallback.java Field com.amazon.ion.impl._Private_MarkupCallback.myAppendable @@ -1883,69 +1774,69 @@ Local variable named appendable - + At _Private_MarkupCallback.java:[line 191] - Field isn't final but should be - com.amazon.ion.impl._Private_ScalarConversions.FNID_identity isn't final but should be + Un champ n'est pas final alors qu'il devrait l'être + com.amazon.ion.impl._Private_ScalarConversions.FNID_identity n'est pas final mais devrait l'être - + At _Private_ScalarConversions.java:[lines 30-333] In class com.amazon.ion.impl._Private_ScalarConversions - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions.FNID_identity - + At _Private_ScalarConversions.java:[line 114] - Field isn't final but should be - com.amazon.ion.impl._Private_ScalarConversions.FNID_no_conversion isn't final but should be + Un champ n'est pas final alors qu'il devrait l'être + com.amazon.ion.impl._Private_ScalarConversions.FNID_no_conversion n'est pas final mais devrait l'être - + At _Private_ScalarConversions.java:[lines 30-333] In class com.amazon.ion.impl._Private_ScalarConversions - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions.FNID_no_conversion - + At _Private_ScalarConversions.java:[line 113] - Unchecked/unconfirmed cast - Unchecked/unconfirmed cast from java.math.BigDecimal to com.amazon.ion.Decimal in com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(BigDecimal) + Transtypage non vérifié/non confirmé + Transtypage non vérifié/non confirmé de com.amazon.ion.Decimal vers value dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(BigDecimal) - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(BigDecimal) - - At BigDecimal.java:[lines 228-5723] + + At BigDecimal.java:[lines 305-5815] Actual type java.math.BigDecimal - + At Decimal.java:[lines 48-426] Expected com.amazon.ion.Decimal @@ -1953,94 +1844,94 @@ Value loaded from value - + At _Private_ScalarConversions.java:[line 505] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getDate() may expose internal representation by returning _Private_ScalarConversions$ValueVariant._date_value + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getDate() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._date_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getDate() - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._date_value - + At _Private_ScalarConversions.java:[line 566] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getDecimal() may expose internal representation by returning _Private_ScalarConversions$ValueVariant._decimal_value + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getDecimal() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getDecimal() - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value - + At _Private_ScalarConversions.java:[line 562] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getTimestamp() may expose internal representation by returning _Private_ScalarConversions$ValueVariant._timestamp_value + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getTimestamp() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._timestamp_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.getTimestamp() - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._timestamp_value - + At _Private_ScalarConversions.java:[line 570] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Decimal) may expose internal representation by storing an externally mutable object into _Private_ScalarConversions$ValueVariant._decimal_value + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Decimal) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Decimal) - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value @@ -2048,25 +1939,25 @@ Local variable named value - + At _Private_ScalarConversions.java:[line 509] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Timestamp) may expose internal representation by storing an externally mutable object into _Private_ScalarConversions$ValueVariant._timestamp_value + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Timestamp) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._timestamp_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Timestamp) - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._timestamp_value @@ -2074,25 +1965,25 @@ Local variable named value - + At _Private_ScalarConversions.java:[line 517] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(BigDecimal) may expose internal representation by storing an externally mutable object into _Private_ScalarConversions$ValueVariant._decimal_value + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(BigDecimal) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(BigDecimal) - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value @@ -2100,25 +1991,25 @@ Local variable named value - + At _Private_ScalarConversions.java:[line 505] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Date) may expose internal representation by storing an externally mutable object into _Private_ScalarConversions$ValueVariant._date_value + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Date) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._date_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.addValue(Date) - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._date_value @@ -2126,25 +2017,25 @@ Local variable named value - + At _Private_ScalarConversions.java:[line 513] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Decimal) may expose internal representation by storing an externally mutable object into _Private_ScalarConversions$ValueVariant._decimal_value + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Decimal) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Decimal) - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._decimal_value @@ -2152,25 +2043,25 @@ Local variable named value - + At _Private_ScalarConversions.java:[line 463] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Timestamp) may expose internal representation by storing an externally mutable object into _Private_ScalarConversions$ValueVariant._timestamp_value + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Timestamp) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._timestamp_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Timestamp) - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._timestamp_value @@ -2178,25 +2069,25 @@ Local variable named value - + At _Private_ScalarConversions.java:[line 471] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Date) may expose internal representation by storing an externally mutable object into _Private_ScalarConversions$ValueVariant._date_value + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Date) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._date_value - + At _Private_ScalarConversions.java:[lines 373-873] In class com.amazon.ion.impl._Private_ScalarConversions$ValueVariant - + In method com.amazon.ion.impl._Private_ScalarConversions$ValueVariant.setValue(Date) - + In _Private_ScalarConversions.java Field com.amazon.ion.impl._Private_ScalarConversions$ValueVariant._date_value @@ -2204,25 +2095,25 @@ Local variable named value - + At _Private_ScalarConversions.java:[line 467] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_SymtabExtendsCache.symtabsCompat(SymbolTable, SymbolTable) may expose internal representation by storing an externally mutable object into _Private_SymtabExtendsCache.myReaderSymtab + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_SymtabExtendsCache.symtabsCompat(SymbolTable, SymbolTable) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_SymtabExtendsCache.myReaderSymtab - + At _Private_SymtabExtendsCache.java:[lines 27-64] In class com.amazon.ion.impl._Private_SymtabExtendsCache - + In method com.amazon.ion.impl._Private_SymtabExtendsCache.symtabsCompat(SymbolTable, SymbolTable) - + In _Private_SymtabExtendsCache.java Field com.amazon.ion.impl._Private_SymtabExtendsCache.myReaderSymtab @@ -2230,25 +2121,25 @@ Local variable named readerSymtab - + At _Private_SymtabExtendsCache.java:[line 58] - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.impl._Private_SymtabExtendsCache.symtabsCompat(SymbolTable, SymbolTable) may expose internal representation by storing an externally mutable object into _Private_SymtabExtendsCache.myWriterSymtab + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.impl._Private_SymtabExtendsCache.symtabsCompat(SymbolTable, SymbolTable) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl._Private_SymtabExtendsCache.myWriterSymtab - + At _Private_SymtabExtendsCache.java:[lines 27-64] In class com.amazon.ion.impl._Private_SymtabExtendsCache - + In method com.amazon.ion.impl._Private_SymtabExtendsCache.symtabsCompat(SymbolTable, SymbolTable) - + In _Private_SymtabExtendsCache.java Field com.amazon.ion.impl._Private_SymtabExtendsCache.myWriterSymtab @@ -2256,7 +2147,7 @@ Local variable named writerSymtab - + At _Private_SymtabExtendsCache.java:[line 57] @@ -2264,114 +2155,114 @@ Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$2.beforeStepIn(IonManagedBinaryWriter, IonType) where default case is missing - - At IonManagedBinaryWriter.java:[lines 328-420] + + At IonManagedBinaryWriter.java:[lines 327-419] In class com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$2 - + In method com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$2.beforeStepIn(IonManagedBinaryWriter, IonType) - - At IonManagedBinaryWriter.java:[lines 335-351] + + At IonManagedBinaryWriter.java:[lines 334-350] Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$3.afterStepOut(IonManagedBinaryWriter) where default case is missing - - At IonManagedBinaryWriter.java:[lines 422-510] + + At IonManagedBinaryWriter.java:[lines 421-509] In class com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$3 - + In method com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$3.afterStepOut(IonManagedBinaryWriter) - - At IonManagedBinaryWriter.java:[lines 437-473] + + At IonManagedBinaryWriter.java:[lines 436-472] Switch statement found where default case is missing Switch statement found in com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$3.writeInt(IonManagedBinaryWriter, long) where default case is missing - - At IonManagedBinaryWriter.java:[lines 422-510] + + At IonManagedBinaryWriter.java:[lines 421-509] In class com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$3 - + In method com.amazon.ion.impl.bin.IonManagedBinaryWriter$UserState$3.writeInt(IonManagedBinaryWriter, long) - - At IonManagedBinaryWriter.java:[lines 500-506] + + At IonManagedBinaryWriter.java:[lines 499-505] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.bin.utf8.PoolableByteBuffer.getBuffer() may expose internal representation by returning PoolableByteBuffer.buffer + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.bin.utf8.PoolableByteBuffer.getBuffer() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.bin.utf8.PoolableByteBuffer.buffer - + At PoolableByteBuffer.java:[lines 12-31] In class com.amazon.ion.impl.bin.utf8.PoolableByteBuffer - + In method com.amazon.ion.impl.bin.utf8.PoolableByteBuffer.getBuffer() - + In PoolableByteBuffer.java Field com.amazon.ion.impl.bin.utf8.PoolableByteBuffer.buffer - + At PoolableByteBuffer.java:[line 31] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result.getBuffer() may expose internal representation by returning Utf8StringEncoder$Result.buffer + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result.getBuffer() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result.buffer - + At Utf8StringEncoder.java:[lines 128-148] In class com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result - + In method com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result.getBuffer() - + In Utf8StringEncoder.java Field com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result.buffer - + At Utf8StringEncoder.java:[line 141] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result(int, byte[]) may expose internal representation by storing an externally mutable object into Utf8StringEncoder$Result.buffer + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result(int, byte[]) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result.buffer - + At Utf8StringEncoder.java:[lines 128-148] In class com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result - + In method new com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result(int, byte[]) - + In Utf8StringEncoder.java Field com.amazon.ion.impl.bin.utf8.Utf8StringEncoder$Result.buffer @@ -2379,7 +2270,7 @@ Local variable named buffer - + At Utf8StringEncoder.java:[line 130] @@ -2387,13 +2278,13 @@ Bad comparison of nonnegative value with negative constant or zero Bad comparison of nonnegative value with 0 in com.amazon.ion.impl.lite.IonContainerLite.add(int, IonValueLite) - - At IonContainerLite.java:[lines 35-751] + + At IonContainerLite.java:[lines 39-857] In class com.amazon.ion.impl.lite.IonContainerLite - + In method com.amazon.ion.impl.lite.IonContainerLite.add(int, IonValueLite) @@ -2402,71 +2293,71 @@ Local variable named index - - At IonContainerLite.java:[line 569] + + At IonContainerLite.java:[line 663] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.next() may expose internal representation by returning IonContainerLite$SequenceContentIterator.__current + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.next() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.__current - - At IonContainerLite.java:[lines 191-361] + + At IonContainerLite.java:[lines 275-463] In class com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator - + In method com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.next() - + In IonContainerLite.java Field com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.__current - - At IonContainerLite.java:[line 283] + + At IonContainerLite.java:[line 367] - May expose internal representation by returning reference to mutable object - com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.previous() may expose internal representation by returning IonContainerLite$SequenceContentIterator.__current + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.previous() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.__current - - At IonContainerLite.java:[lines 191-361] + + At IonContainerLite.java:[lines 275-463] In class com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator - + In method com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.previous() - + In IonContainerLite.java Field com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.__current - - At IonContainerLite.java:[line 309] + + At IonContainerLite.java:[line 408] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator(IonContainerLite, int, boolean) may expose internal representation by storing an externally mutable object into IonContainerLite$SequenceContentIterator.this$0 + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator(IonContainerLite, int, boolean) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.this$0 - - At IonContainerLite.java:[lines 191-361] + + At IonContainerLite.java:[lines 275-463] In class com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator - + In method new com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator(IonContainerLite, int, boolean) - + In IonContainerLite.java Field com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.this$0 @@ -2474,48 +2365,48 @@ Local variable named this$0 - - At IonContainerLite.java:[line 200] + + At IonContainerLite.java:[line 284] - Self assignment of field - Self assignment of field IonContainerLite$SequenceContentIterator.__pos in com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.force_position_sync_helper() + Auto-alimentation d'un champs + Auto-alimentation du champs com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.__pos dans com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.force_position_sync_helper() - - At IonContainerLite.java:[lines 191-361] + + At IonContainerLite.java:[lines 275-463] In class com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator - + In method com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.force_position_sync_helper() - + In IonContainerLite.java Field com.amazon.ion.impl.lite.IonContainerLite$SequenceContentIterator.__pos - - At IonContainerLite.java:[line 234] + + At IonContainerLite.java:[line 318] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.impl.lite.IonDatagramLite$SystemContentIterator(IonDatagramLite, boolean) may expose internal representation by storing an externally mutable object into IonDatagramLite$SystemContentIterator.this$0 + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.impl.lite.IonDatagramLite$SystemContentIterator(IonDatagramLite, boolean) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.impl.lite.IonDatagramLite$SystemContentIterator.this$0 - - At IonDatagramLite.java:[lines 604-853] + + At IonDatagramLite.java:[lines 585-834] In class com.amazon.ion.impl.lite.IonDatagramLite$SystemContentIterator - + In method new com.amazon.ion.impl.lite.IonDatagramLite$SystemContentIterator(IonDatagramLite, boolean) - + In IonDatagramLite.java Field com.amazon.ion.impl.lite.IonDatagramLite$SystemContentIterator.this$0 @@ -2523,75 +2414,75 @@ Local variable named this$0 - - At IonDatagramLite.java:[line 614] + + At IonDatagramLite.java:[line 595] - Nullcheck of value previously dereferenced - Nullcheck of IonDatagramLite$SystemIteratorPosition.__local_values at line 1094 of value previously dereferenced in com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.push_system_value(IonValueLite) + Test de nullité d'une valeur préalablement déréférencée + Test de nullité dans com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.__local_values d'une valeur préalablement déréférencée dans com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.push_system_value(IonValueLite) - - At IonDatagramLite.java:[lines 856-1157] + + At IonDatagramLite.java:[lines 837-1138] In class com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition - + In method com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.push_system_value(IonValueLite) - + In IonDatagramLite.java Value loaded from field com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.__local_values - - At IonDatagramLite.java:[line 1093] + + At IonDatagramLite.java:[line 1074] - - Redundant null check at IonDatagramLite.java:[line 1094] + + Redundant null check at IonDatagramLite.java:[line 1075] - Nullcheck of value previously dereferenced - Nullcheck of curr at line 1153 of value previously dereferenced in com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.count_system_values(IonSystem, SymbolTable, SymbolTable) + Test de nullité d'une valeur préalablement déréférencée + Test de nullité dans curr d'une valeur préalablement déréférencée dans com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.count_system_values(IonSystem, SymbolTable, SymbolTable) - - At IonDatagramLite.java:[lines 856-1157] + + At IonDatagramLite.java:[lines 837-1138] In class com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition - + In method com.amazon.ion.impl.lite.IonDatagramLite$SystemIteratorPosition.count_system_values(IonSystem, SymbolTable, SymbolTable) Value loaded from curr - - At IonDatagramLite.java:[line 1148] + + At IonDatagramLite.java:[line 1129] - - Redundant null check at IonDatagramLite.java:[line 1153] + + Redundant null check at IonDatagramLite.java:[line 1134] - Comparison of String objects using == or != - Comparison of String objects using == or != in com.amazon.ion.impl.lite.IonStructLite.validate() + Comparaison d'objets String utilisant == ou != + Comparaison d'objets String utilisant == ou != dans com.amazon.ion.impl.lite.IonStructLite.validate() - - At IonStructLite.java:[lines 41-818] + + At IonStructLite.java:[lines 38-753] In class com.amazon.ion.impl.lite.IonStructLite - + In method com.amazon.ion.impl.lite.IonStructLite.validate() - - At String.java:[lines 125-3345] + + At String.java:[lines 140-4657] Actual type String @@ -2601,269 +2492,342 @@ Value loaded from error - - At IonStructLite.java:[line 233] + + At IonStructLite.java:[line 230] - Load of known null value - Load of known null value in com.amazon.ion.impl.lite.IonStructLite.add(SymbolToken, IonValue) + Chargement d'une valeur connue pour être à null + Chargement d'une valeur connue pour être à null dans com.amazon.ion.impl.lite.IonStructLite.add(SymbolToken, IonValue) - - At IonStructLite.java:[lines 41-818] + + At IonStructLite.java:[lines 38-753] In class com.amazon.ion.impl.lite.IonStructLite - + In method com.amazon.ion.impl.lite.IonStructLite.add(SymbolToken, IonValue) - + Value loaded from text - - At IonStructLite.java:[line 528] + + At IonStructLite.java:[line 500] - Method concatenates strings using + in a loop - com.amazon.ion.impl.lite.IonStructLite.validate() concatenates strings using + in a loop + La méthode concatène des chaînes au moyen de + en boucle + La méthode com.amazon.ion.impl.lite.IonStructLite.validate() concatène des chaînes au moyen de + en boucle - - At IonStructLite.java:[lines 41-818] + + At IonStructLite.java:[lines 38-753] In class com.amazon.ion.impl.lite.IonStructLite - + In method com.amazon.ion.impl.lite.IonStructLite.validate() - - At IonStructLite.java:[line 229] - - - - Method invokes inefficient Number constructor; use static valueOf instead - com.amazon.ion.impl.lite.IonTimestampLite.setLocalOffset(int) invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead - - - At IonTimestampLite.java:[lines 29-246] - - In class com.amazon.ion.impl.lite.IonTimestampLite - - - - In method com.amazon.ion.impl.lite.IonTimestampLite.setLocalOffset(int) - - - - Called method new Integer(int) - - - - Should call Integer.valueOf(int) instead - - - At IonTimestampLite.java:[line 215] + + At IonStructLite.java:[line 226] - Unsigned right shift cast to short/byte - Unsigned right shift cast to short/byte in com.amazon.ion.impl.lite.ReverseBinaryEncoder.writeVarInt(int) + Décalage à droite non signé et transtypage short/byte + Décalage à droite non signé et transtypage vers un short/byte dans com.amazon.ion.impl.lite.ReverseBinaryEncoder.writeVarInt(int) - + At ReverseBinaryEncoder.java:[lines 90-1464] In class com.amazon.ion.impl.lite.ReverseBinaryEncoder - + In method com.amazon.ion.impl.lite.ReverseBinaryEncoder.writeVarInt(int) - + At ReverseBinaryEncoder.java:[line 571] - + Another occurrence at ReverseBinaryEncoder.java:[line 581] - + Another occurrence at ReverseBinaryEncoder.java:[line 592] - Unsigned right shift cast to short/byte - Unsigned right shift cast to short/byte in com.amazon.ion.impl.lite.ReverseBinaryEncoder.writeVarUInt(int) + Décalage à droite non signé et transtypage short/byte + Décalage à droite non signé et transtypage vers un short/byte dans com.amazon.ion.impl.lite.ReverseBinaryEncoder.writeVarUInt(int) - + At ReverseBinaryEncoder.java:[lines 90-1464] In class com.amazon.ion.impl.lite.ReverseBinaryEncoder - + In method com.amazon.ion.impl.lite.ReverseBinaryEncoder.writeVarUInt(int) - + At ReverseBinaryEncoder.java:[line 486] - + Another occurrence at ReverseBinaryEncoder.java:[line 494] - + Another occurrence at ReverseBinaryEncoder.java:[line 503] - + Another occurrence at ReverseBinaryEncoder.java:[line 513] + + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.system.IonSystemBuilder.getIonBinaryWriterBuilder() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.system.IonSystemBuilder.binaryWriterBuilder + + + At IonSystemBuilder.java:[lines 86-465] + + In class com.amazon.ion.system.IonSystemBuilder + + + + In method com.amazon.ion.system.IonSystemBuilder.getIonBinaryWriterBuilder() + + + + In IonSystemBuilder.java + + Field com.amazon.ion.system.IonSystemBuilder.binaryWriterBuilder + + + At IonSystemBuilder.java:[line 345] + + + + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.system.IonSystemBuilder.getIonTextWriterBuilder() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.system.IonSystemBuilder.textWriterBuilder + + + At IonSystemBuilder.java:[lines 86-465] + + In class com.amazon.ion.system.IonSystemBuilder + + + + In method com.amazon.ion.system.IonSystemBuilder.getIonTextWriterBuilder() + + + + In IonSystemBuilder.java + + Field com.amazon.ion.system.IonSystemBuilder.textWriterBuilder + + + At IonSystemBuilder.java:[line 292] + + - May expose internal representation by returning reference to mutable object - com.amazon.ion.system.IonSystemBuilder.getReaderBuilder() may expose internal representation by returning IonSystemBuilder.readerBuilder + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.system.IonSystemBuilder.getReaderBuilder() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.system.IonSystemBuilder.readerBuilder - - At IonSystemBuilder.java:[lines 84-358] + + At IonSystemBuilder.java:[lines 86-465] In class com.amazon.ion.system.IonSystemBuilder - + In method com.amazon.ion.system.IonSystemBuilder.getReaderBuilder() - + In IonSystemBuilder.java Field com.amazon.ion.system.IonSystemBuilder.readerBuilder - - At IonSystemBuilder.java:[line 287] + + At IonSystemBuilder.java:[line 398] + + + + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.system.IonSystemBuilder.setIonBinaryWriterBuilder(IonBinaryWriterBuilder) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.system.IonSystemBuilder.binaryWriterBuilder + + + At IonSystemBuilder.java:[lines 86-465] + + In class com.amazon.ion.system.IonSystemBuilder + + + + In method com.amazon.ion.system.IonSystemBuilder.setIonBinaryWriterBuilder(IonBinaryWriterBuilder) + + + + In IonSystemBuilder.java + + Field com.amazon.ion.system.IonSystemBuilder.binaryWriterBuilder + + + Local variable stored in JVM register ? + + + At IonSystemBuilder.java:[line 364] + + + + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.system.IonSystemBuilder.setIonTextWriterBuilder(IonTextWriterBuilder) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.system.IonSystemBuilder.textWriterBuilder + + + At IonSystemBuilder.java:[lines 86-465] + + In class com.amazon.ion.system.IonSystemBuilder + + + + In method com.amazon.ion.system.IonSystemBuilder.setIonTextWriterBuilder(IonTextWriterBuilder) + + + + In IonSystemBuilder.java + + Field com.amazon.ion.system.IonSystemBuilder.textWriterBuilder + + + Local variable stored in JVM register ? + + + At IonSystemBuilder.java:[line 311] - - May expose internal representation by incorporating reference to mutable object - com.amazon.ion.system.IonSystemBuilder.setReaderBuilder(IonReaderBuilder) may expose internal representation by storing an externally mutable object into IonSystemBuilder.readerBuilder + + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode com.amazon.ion.system.IonSystemBuilder.setReaderBuilder(IonReaderBuilder) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.system.IonSystemBuilder.readerBuilder - - At IonSystemBuilder.java:[lines 84-358] + + At IonSystemBuilder.java:[lines 86-465] In class com.amazon.ion.system.IonSystemBuilder - + In method com.amazon.ion.system.IonSystemBuilder.setReaderBuilder(IonReaderBuilder) - + In IonSystemBuilder.java Field com.amazon.ion.system.IonSystemBuilder.readerBuilder - - Local variable named builder + + Local variable stored in JVM register ? - - At IonSystemBuilder.java:[line 306] + + At IonSystemBuilder.java:[line 417] - Public static method may expose internal representation by returning array - Public static com.amazon.ion.system.IonSystemBuilder.standard() may expose internal representation by returning IonSystemBuilder.STANDARD + Une méthode statique publique risque d'exposer une représentation interne en renvoyant un tableau + La méthode statique publique com.amazon.ion.system.IonSystemBuilder.standard() peut exposer une représentation interne en renvoyant com.amazon.ion.system.IonSystemBuilder.STANDARD - - At IonSystemBuilder.java:[lines 84-358] + + At IonSystemBuilder.java:[lines 86-465] In class com.amazon.ion.system.IonSystemBuilder - + In method com.amazon.ion.system.IonSystemBuilder.standard() - + In IonSystemBuilder.java Field com.amazon.ion.system.IonSystemBuilder.STANDARD - - At IonSystemBuilder.java:[line 96] + + At IonSystemBuilder.java:[line 98] Equals method should not assume anything about the type of its argument Equals method for com.amazon.ion.util.Equivalence$Field assumes the argument is of type Equivalence$Field - - At Equivalence.java:[lines 421-471] + + At Equivalence.java:[lines 444-496] In class com.amazon.ion.util.Equivalence$Field - + In method com.amazon.ion.util.Equivalence$Field.equals(Object) - - At Equivalence.java:[line 468] + + At Equivalence.java:[line 493] - equals() method does not check for null argument - com.amazon.ion.util.Equivalence$Field.equals(Object) does not check for null argument + Méthode equals() ne vérifiant pas la nullité + com.amazon.ion.util.Equivalence$Field.equals(Object) ne vérifie pas la nullité d'un paramètre - - At Equivalence.java:[lines 421-471] + + At Equivalence.java:[lines 444-496] In class com.amazon.ion.util.Equivalence$Field - + In method com.amazon.ion.util.Equivalence$Field.equals(Object) Parameter other - - At Equivalence.java:[lines 468-470] + + At Equivalence.java:[lines 493-495] - May expose internal representation by returning reference to mutable object - com.amazon.ion.util.JarInfo.getBuildTime() may expose internal representation by returning JarInfo.ourBuildTime + Une méthode peut exposer sa représentation interne en renvoyant une référence à un objet modifiable + La méthode com.amazon.ion.util.JarInfo.getBuildTime() risque d'exposer sa représentation interne en renvoyant com.amazon.ion.util.JarInfo.ourBuildTime - - At JarInfo.java:[lines 48-125] + + At JarInfo.java:[lines 43-120] In class com.amazon.ion.util.JarInfo - + In method com.amazon.ion.util.JarInfo.getBuildTime() - + In JarInfo.java Field com.amazon.ion.util.JarInfo.ourBuildTime - - At JarInfo.java:[line 70] + + At JarInfo.java:[line 65] - May expose internal representation by incorporating reference to mutable object - new com.amazon.ion.util.Printer$Options(Printer) may expose internal representation by storing an externally mutable object into Printer$Options.this$0 + Une méthode expose sa représentation interne en incorporant une référence à un objet modifiable + La méthode new com.amazon.ion.util.Printer$Options(Printer) risque d'exposer sa représentation interne en stockant un objet externe modifiable dans com.amazon.ion.util.Printer$Options.this$0 - - At Printer.java:[lines 84-111] + + At Printer.java:[lines 88-115] In class com.amazon.ion.util.Printer$Options - + In method new com.amazon.ion.util.Printer$Options(Printer) - + In Printer.java Field com.amazon.ion.util.Printer$Options.this$0 @@ -2871,21 +2835,21 @@ Local variable named this$0 - - At Printer.java:[line 84] + + At Printer.java:[line 88] - Should be a static inner class - Should com.amazon.ion.util.Printer$Options be a _static_ inner class? + Devrait être une classe interne statique + La classe com.amazon.ion.util.Printer$Options devrait-elle être une classe interne static ? - - At Printer.java:[lines 84-111] + + At Printer.java:[lines 88-115] In class com.amazon.ion.util.Printer$Options - - At Printer.java:[lines 84-111] + + At Printer.java:[lines 88-115] diff --git a/src/main/java/com/amazon/ion/system/IonSystemBuilder.java b/src/main/java/com/amazon/ion/system/IonSystemBuilder.java index c6c69c74f8..35db2ef2a0 100644 --- a/src/main/java/com/amazon/ion/system/IonSystemBuilder.java +++ b/src/main/java/com/amazon/ion/system/IonSystemBuilder.java @@ -24,6 +24,8 @@ import com.amazon.ion.SymbolTable; import com.amazon.ion.impl._Private_IonBinaryWriterBuilder; import com.amazon.ion.impl._Private_Utils; +import java.util.Objects; +import java.util.Optional; /** * The builder for creating {@link IonSystem}s. @@ -101,7 +103,10 @@ public static IonSystemBuilder standard() IonCatalog myCatalog; boolean myStreamCopyOptimized = false; - IonReaderBuilder readerBuilder; + + IonTextWriterBuilder textWriterBuilder = IonTextWriterBuilder.standard().withCharsetAscii(); + IonBinaryWriterBuilder binaryWriterBuilder = IonBinaryWriterBuilder.standard(); + IonReaderBuilder readerBuilder = IonReaderBuilder.standard(); /** You no touchy. */ @@ -114,6 +119,8 @@ private IonSystemBuilder(IonSystemBuilder that) { this.myCatalog = that.myCatalog; this.myStreamCopyOptimized = that.myStreamCopyOptimized; + this.textWriterBuilder = that.textWriterBuilder; + this.binaryWriterBuilder = that.binaryWriterBuilder; this.readerBuilder = that.readerBuilder; } @@ -271,7 +278,113 @@ public final IonSystemBuilder withStreamCopyOptimized(boolean optimized) return b; } + //========================================================================= + /** + * Gets the text writer builder whose options will be used when building an + * {@link IonSystem}. By default, {@link IonTextWriterBuilder#standard()} + * using {@code US-ASCII} encoding will be used. + * + * @see #setIonTextWriterBuilder(IonTextWriterBuilder) + * @see #withIonTextWriterBuilder(IonTextWriterBuilder) + */ + public final IonTextWriterBuilder getIonTextWriterBuilder() { + return textWriterBuilder; + } + + /** + * Sets the text writer builder whose options will be used when building + * an {@link IonSystem}. The writer builder's catalog will never be used; the + * catalog provided to {@link #setCatalog(IonCatalog)} or + * {@link #withCatalog(IonCatalog)} will always be used instead. + * + * @param builder the writer builder to use in built systems. + * If null, each system will be built with {@link IonTextWriterBuilder#standard()} + * using {@code US-ASCII} encoding. + * + * @see #getIonTextWriterBuilder() + * @see #withIonTextWriterBuilder(IonTextWriterBuilder) + * + * @throws UnsupportedOperationException if this is immutable. + */ + public final void setIonTextWriterBuilder(IonTextWriterBuilder builder) { + mutationCheck(); + textWriterBuilder = Objects.requireNonNull(builder); + } + + /** + * Declares the text writer builder whose options will be used when building + * an {@link IonSystem}, returning a new mutable builder if this is immutable. + * The writer builder's catalog will never be used; the catalog provided to + * {@link #setCatalog(IonCatalog)} or {@link #withCatalog(IonCatalog)} will + * always be used instead. + * + * @param builder the writer builder to use in built systems. + * If null, each system will be built with {@link IonTextWriterBuilder#standard()} + * using {@code US-ASCII} encoding. + * + * @see #getIonTextWriterBuilder() + * @see #setIonTextWriterBuilder(IonTextWriterBuilder) + */ + public final IonSystemBuilder withIonTextWriterBuilder(IonTextWriterBuilder builder) + { + IonSystemBuilder b = mutable(); + b.setIonTextWriterBuilder(builder); + return b; + } + + //========================================================================= + + /** + * Gets the binary writer builder whose options will be used when building an + * {@link IonSystem}. By default, {@link IonBinaryWriterBuilder#standard()} will + * be used. + * + * @see #setIonBinaryWriterBuilder(IonBinaryWriterBuilder) + * @see #withIonBinaryWriterBuilder(IonBinaryWriterBuilder) + */ + public final IonBinaryWriterBuilder getIonBinaryWriterBuilder() { + return binaryWriterBuilder; + } + + /** + * Sets the binary writer builder whose options will be used when building + * an {@link IonSystem}. The writer builder's catalog will never be used; the + * catalog provided to {@link #setCatalog(IonCatalog)} or + * {@link #withCatalog(IonCatalog)} will always be used instead. + * + * @param builder the writer builder to use in built systems. + * If null, each system will be built with {@link IonBinaryWriterBuilder#standard()}. + * + * @see #getIonBinaryWriterBuilder() + * @see #withIonBinaryWriterBuilder(IonBinaryWriterBuilder) + * + * @throws UnsupportedOperationException if this is immutable. + */ + public final void setIonBinaryWriterBuilder(IonBinaryWriterBuilder builder) { + mutationCheck(); + binaryWriterBuilder = Objects.requireNonNull(builder); + } + + /** + * Declares the binary writer builder whose options will be used to use when building + * an {@link IonSystem}, returning a new mutable builder if this is immutable. + * The writer builder's catalog will never be used; the catalog provided to + * {@link #setCatalog(IonCatalog)} or {@link #withCatalog(IonCatalog)} will + * always be used instead. + * + * @param builder the writer builder to use in built systems. + * If null, each system will be built with {@link IonBinaryWriterBuilder#standard()}. + * + * @see #getIonBinaryWriterBuilder() + * @see #setIonBinaryWriterBuilder(IonBinaryWriterBuilder) + */ + public final IonSystemBuilder withIonBinaryWriterBuilder(IonBinaryWriterBuilder builder) + { + IonSystemBuilder b = mutable(); + b.setIonBinaryWriterBuilder(builder); + return b; + } //========================================================================= @@ -303,7 +416,7 @@ public final IonReaderBuilder getReaderBuilder() { */ public final void setReaderBuilder(IonReaderBuilder builder) { mutationCheck(); - readerBuilder = builder; + readerBuilder = Objects.requireNonNull(builder); } /** @@ -334,16 +447,13 @@ public final IonSystemBuilder withReaderBuilder(IonReaderBuilder builder) */ public final IonSystem build() { - IonCatalog catalog = - (myCatalog != null ? myCatalog : new SimpleCatalog()); + IonCatalog catalog = Optional.ofNullable(myCatalog).orElseGet(SimpleCatalog::new); - IonTextWriterBuilder twb = - IonTextWriterBuilder.standard().withCharsetAscii(); - twb.setCatalog(catalog); + IonTextWriterBuilder twb = textWriterBuilder.copy().withCatalog(catalog); + IonBinaryWriterBuilder bwb = binaryWriterBuilder.copy().withCatalog(catalog); + IonReaderBuilder rb = readerBuilder.copy().withCatalog(catalog); - _Private_IonBinaryWriterBuilder bwb = - _Private_IonBinaryWriterBuilder.standard(); - bwb.setCatalog(catalog); + // TODO Use #setStreamCopyOptimized directly on the BWB bwb.setStreamCopyOptimized(myStreamCopyOptimized); // TODO Would be nice to remove this since it's implied by the BWB. @@ -353,9 +463,8 @@ public final IonSystem build() bwb.setInitialSymbolTable(systemSymtab); // This is what we need, more or less. // bwb = bwb.fillDefaults(); - IonReaderBuilder rb = readerBuilder == null ? IonReaderBuilder.standard() : readerBuilder; - rb = rb.withCatalog(catalog); - return newLiteSystem(twb, bwb, rb); + + return newLiteSystem(twb, (_Private_IonBinaryWriterBuilder) bwb, rb); } //========================================================================= diff --git a/src/test/java/com/amazon/ion/system/IonSystemBuilderTest.java b/src/test/java/com/amazon/ion/system/IonSystemBuilderTest.java index ad3f40b0fb..6e0379f275 100644 --- a/src/test/java/com/amazon/ion/system/IonSystemBuilderTest.java +++ b/src/test/java/com/amazon/ion/system/IonSystemBuilderTest.java @@ -133,6 +133,49 @@ public void testStreamCopyOptimizedImmutability() b2.setStreamCopyOptimized(false); } + //------------------------------------------------------------------------- + + @Test + public void testIonTextWriterBuilder() + { + IonCatalog textWriterCatalog = new SimpleCatalog(); // should be ignored + IonTextWriterBuilder textWriterBuilder = IonTextWriterBuilder.standard().withCatalog(textWriterCatalog); + + IonSystemBuilder systemBuilder = IonSystemBuilder.standard().withIonTextWriterBuilder(textWriterBuilder); + assertSame(textWriterBuilder, systemBuilder.getIonTextWriterBuilder()); + + IonCatalog systemCatalog = new SimpleCatalog(); + IonSystem system = systemBuilder.withCatalog(systemCatalog).build(); + assertSame(systemCatalog, system.getCatalog()); + } + + @Test + public void testIonBinaryWriterBuilder() + { + IonCatalog binaryWriterCatalog = new SimpleCatalog(); // should be ignored + IonBinaryWriterBuilder binaryWriterBuilder = IonBinaryWriterBuilder.standard().withCatalog(binaryWriterCatalog); + + IonSystemBuilder systemBuilder = IonSystemBuilder.standard().withIonBinaryWriterBuilder(binaryWriterBuilder); + assertSame(binaryWriterBuilder, systemBuilder.getIonBinaryWriterBuilder()); + + IonCatalog systemCatalog = new SimpleCatalog(); + IonSystem system = systemBuilder.withCatalog(systemCatalog).build(); + assertSame(systemCatalog, system.getCatalog()); + } + + @Test + public void testIonReaderBuilder() + { + IonCatalog readerCatalog = new SimpleCatalog(); // should be ignored + IonReaderBuilder readerBuilder = IonReaderBuilder.standard().withCatalog(readerCatalog); + + IonSystemBuilder systemBuilder = IonSystemBuilder.standard().withReaderBuilder(readerBuilder); + assertSame(readerBuilder, systemBuilder.getReaderBuilder()); + + IonCatalog systemCatalog = new SimpleCatalog(); + IonSystem system = systemBuilder.withCatalog(systemCatalog).build(); + assertSame(systemCatalog, system.getCatalog()); + } //-------------------------------------------------------------------------