Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
raphw
asm
Commits
a1820830
Commit
a1820830
authored
Apr 02, 2018
by
raphw
Browse files
Make non-checking constructor accessible and deprecate consructor with unused argument
parent
ab106301
Pipeline
#1238
passed with stage
in 6 minutes and 38 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
asm/src/main/java/org/objectweb/asm/ClassReader.java
View file @
a1820830
...
...
@@ -136,13 +136,25 @@ public class ClassReader {
this
(
classFile
,
0
,
classFile
.
length
);
}
/**
* Constructs a new {@link ClassReader} object.
*
* @param classFileBuffer a byte array containing the JVMS ClassFile structure to be read.
* @param classFileOffset the offset in byteBuffer of the first byte of the ClassFile to be read.
*/
public
ClassReader
(
final
byte
[]
classFileBuffer
,
final
int
classFileOffset
)
{
this
(
classFileBuffer
,
classFileOffset
,
/* checkClassVersion = */
true
);
}
/**
* Constructs a new {@link ClassReader} object.
*
* @param classFileBuffer a byte array containing the JVMS ClassFile structure to be read.
* @param classFileOffset the offset in byteBuffer of the first byte of the ClassFile to be read.
* @param classFileLength the length in bytes of the ClassFile to be read.
* @deprecated use {@link ClassReader#ClassReader(byte[], int)}.
*/
@Deprecated
public
ClassReader
(
final
byte
[]
classFileBuffer
,
final
int
classFileOffset
,
final
int
classFileLength
)
{
this
(
classFileBuffer
,
classFileOffset
,
/* checkClassVersion = */
true
);
...
...
@@ -156,7 +168,7 @@ public class ClassReader {
* @param classFileOffset the offset in byteBuffer of the first byte of the ClassFile to be read.
* @param checkClassVersion whether to check the class version or not.
*/
ClassReader
(
protected
ClassReader
(
final
byte
[]
classFileBuffer
,
final
int
classFileOffset
,
final
boolean
checkClassVersion
)
{
this
.
b
=
classFileBuffer
;
// Check the class' major_version. This field is after the magic and minor_version fields, which
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment