query
stringlengths
1
74.9k
positive
stringlengths
0
174k
negative
stringlengths
1
174k
label
float64
1
1
task_name
stringclasses
33 values
Is it possible to change plain socket to SSLSocket?
Properly closing SSLSocket
How to tell if Java SSLSocket has data available?
1
stackoverflowdupquestions
How can I make an interface instance method accept arguments of the same class only?
How can I make an interface instance method accept arguments of the same class only, really?
How to create class constructeur that accept array of values?
1
stackoverflowdupquestions
Not able to parse UTC date time to EST local time
UTC to Local date conversion
Convert EST time to local Time in java
1
stackoverflowdupquestions
Using Selenium RemoteWebDriver behind corporate proxy (Java)
Using Selenium RemoteWebDriver behind corporate proxy
Selenium RemoteWebDriver FileDetector Java
1
stackoverflowdupquestions
JavaMail with Gmail: 535-5.7.1 Username and Password not accepted
JavaMail API : Username and Password not accepted (Gmail)
javamail-1.4.5 error at parsing gmail message received via imap
1
stackoverflowdupquestions
Doesn't work setting default value of property in Hibernate
How to set default value in Hibernate
Hibernate - How to order result based on the property of another object
1
stackoverflowdupquestions
How to use YamlPropertiesFactoryBean to load YAML files using Spring Framework 4.1?
Spring Boot: Load @Value from YAML file
Java: Parsing .yaml files [using snake.yaml if possible]
1
stackoverflowdupquestions
Convert binary string to byte array
How to convert efficiently binary string to binary byte array in Java?
Convert byte[] with binary data to String
1
stackoverflowdupquestions
maven project: SWT 3.5 dependency: any official public repo?
How do you build an SWT application with Maven
Java SWT CheckedListBox
1
stackoverflowdupquestions
Exception - checked and unchecked exception type
Java: checked vs unchecked exception explanation
Java checked and unchecked exceptions
1
stackoverflowdupquestions
Jersey Exception when trying to convert a custom object to json
Return an array with jersey
Can't import jersey in Java
1
stackoverflowdupquestions
Eclipse missing imports (javax.media.* and com.sun.media.*)
Why am I getting "the import javax.media cannot be resolved"?
unable to import javax.media.*; (package does not exist) Why does it say so?
1
stackoverflowdupquestions
Java Javascript web browser client
Using java to create a web browser
Web browser in Java
1
stackoverflowdupquestions
Does Java volatile variables impose a happens-before relationship before it is read?
Java - Happens before - volatile
What happens if a volatile variable is written from 2 threads?
1
stackoverflowdupquestions
What is the difference between synchronized on lockObject and using this as the lock?
Java synchronized method lock on object, or method?
Synchronized makes object lock
1
stackoverflowdupquestions
Tomcat randomly shuts down with an AbstractProtocol pause after mild usage
Tomcat8 shutdown randomly with AbstractProtocol.pause
What happens to sleeping threads when container shuts down?
1
stackoverflowdupquestions
EJB's - when to use Remote and/or local interfaces?
Remote EJB call vs Local EJB call performance in same JVM
EJB 3.0 Business Interfaces
1
stackoverflowdupquestions
How to config maven to use servlet 3
Maven dependency for Servlet 3.0 API?
Java servlet access to config file
1
stackoverflowdupquestions
Purpose of ThreadLocal?
When and how should I use a ThreadLocal variable?
Does ThreadLocal need to be used here?
1
stackoverflowdupquestions
Size of JFrame odd after pack()
Why is calling JFrame.pack() adding extra space?
Java Odd pack() Behavior
1
stackoverflowdupquestions
AsyncTask: ClassCastException: java.lang.Object[] cannot be cast to java.lang.String[]
ClassCastException: java.lang.Object[] cannot be cast to java.lang.String[] android
java.lang.ClassCastException: [B > cannot be cast to java.lang.String
1
stackoverflowdupquestions
String index out of range exception and for loop is not working
Java - "String index out of range" exception
Out Of Range Exception
1
stackoverflowdupquestions
Code for searching similar entires in multiple two-dimensional arrays
Find similar rows in 3 two-dimensional arrays
Spring Data JPA duplicate entires
1
stackoverflowdupquestions
Working with constructors and extremely confused
Java Constructors
How to use constructors in Java?
1
stackoverflowdupquestions
Force Java timezone as GMT/UTC
How can I get the current date and time in UTC or GMT in Java?
Print a UTC time in my local timezone
1
stackoverflowdupquestions
Trie Data Structure in Java - Phone Book Application
Trie implementation
Trie data structure returning null even after insertion in java
1
stackoverflowdupquestions
How to obtain MAC address of WiFi network interface?
How to get the MAC address of machine on local network in java
Send data through Wifi from C# to Java
1
stackoverflowdupquestions
Is Java String immutable?
Is "new String()" immutable as well?
Are the objects in the following class immutable?
1
stackoverflowdupquestions
Why does the Java API use int instead of short or byte?
In java, is it more efficient to use byte or short instead of int and float instead of double?
Convert Byte[] to int
1
stackoverflowdupquestions
How do I convert a Java 8 IntStream to a List?
How can I sort an IntStream in ascending order?
IntStream strange error
1
stackoverflowdupquestions
Remove non printable utf8 characters except controlchars from String
Fastest way to strip all non-printable characters from a Java String
How to generate printable (and savable) forms with Java?
1
stackoverflowdupquestions
Circular references in Java and garbage collection
How does Java Garbage Collection work with Circular References?
Garbage collection in Java
1
stackoverflowdupquestions
Replace call to System.currentTimeMillis() at runtime
java.lang.System.currentTimeMillis() replace method
does System.currentTimeMillis() return UTC time?
1
stackoverflowdupquestions
JavaFX transparent window only receives mouse events over drawn pixels
JavaFx Transparent window - yes please. Mouse transparent - no thanks
Window JPanel is transparent?
1
stackoverflowdupquestions
Issues with taking args in command prompt and fileNotFoundExceptions
How to run Java program in command prompt
Give command-line prompt from java
1
stackoverflowdupquestions
What is the use of Java virtual method invocation?
Java - Virtual Methods
How can I find the line numbers of a method invocation in Java
1
stackoverflowdupquestions
Java compiler allows accessing uninitialized blank final field using 'this' keyword? Is this a bug?
Use of uninitialized final field - with/without 'this.' qualifier
Handling uninitialized Strings in Java
1
stackoverflowdupquestions
Java : detect triple-click without firing double-click
Generic class to detect triple click without firing double- or single-click
firing a click event when pressing enter inside a textfield
1
stackoverflowdupquestions
java modal frame with maximize button
Java modal window with maximize button
Cannot Maximize Window with JavaFX
1
stackoverflowdupquestions
How to add Log4J2 appenders at runtime programmatically?
Add file logging dynamically at runtime with Log4j2 2.8.1
Log4j2 - log4j2.xml configuration
1
stackoverflowdupquestions
How do return Java List<String> Json using Jax-RS
How to return List<String> as Response in JAX-RS
Interface as return on GET method using JAX-RS
1
stackoverflowdupquestions
jsoup - strip all formatting and link tags, keep text only
Get text without tags from web page using Jsoup
Replace HTML tags using jsoup
1
stackoverflowdupquestions
hibernate.hbm2ddl.import_files: Path to the files
Java EE jta hibernate.hbm2ddl.import_files does not work
java hibernate the table not created even with <property name="hibernate.hbm2ddl.auto">update</property>
1
stackoverflowdupquestions
Showing GlassPane before entering loop
Layering multiple GlassPane's in a Root Container
How to make Java Glasspane sticks to a location even if GUI was resized?
1
stackoverflowdupquestions
Spring Cloud Config port conflict
Spring Cloud Port Conflict 8888
How can I avoid a name conflict between a class and a package in Java?
1
stackoverflowdupquestions
Gson: parse generic collections
Using a generic type with Gson
When to use GSON to parse object?
1
stackoverflowdupquestions
ImageIO give me a CMMException due to bad JPEG
Is there a 100% Java alternative to ImageIO for reading JPEG files?
ImageIO not able to write a JPEG file
1
stackoverflowdupquestions
Most efficient code to compare lists
Java Compare Two Lists
How to compare two large array lists efficient in java
1
stackoverflowdupquestions
Easiest way to convert a List to a Set in Java
Easiest way to convert a List to a ConcurrentSet? - Java
What's the easiest way to use C source code in a Java application?
1
stackoverflowdupquestions
Why Java Optional performance increase with number of chained calls?
Performance of Java Optional
java: chained method call confusion
1
stackoverflowdupquestions
SerializationException GWT
GWT - RPC SerializationException
GWT + Hibernate many-to-one xml O/R Mapping: SerializationException
1
stackoverflowdupquestions
Changing private final fields via reflection
Change private static final field using Java reflection
How to run method on private field using reflection?
1
stackoverflowdupquestions
How do I convert [[Ljava.lang.String;@7defb4fb] to a String
Error when getting String[] [Ljava.lang.String;@
Error setting expression X with value [Ljava.lang.String;@......]
1
stackoverflowdupquestions
Create threads in java to run in background
Threads in Java
How do I make my java program run in the background?
1
stackoverflowdupquestions
Java convert Windows-1252 to UTF-8, some letters are wrong
Converting windows-1252 Java
How to convert a UTF-8 byteOffset into a charOffset for a Java String?
1
stackoverflowdupquestions
Java Compiling Error in Command prompt: class file has wrong version 52.0, should be 50.0
Class file has wrong version 52.0, should be 50.0
compiling and running java code on cmd prompt with .jar files
1
stackoverflowdupquestions
How to read manifest.mf from POJO class (not a servlet) instantiated by spring?
reading MANIFEST.MF file from jar file using JAVA
File not found: MANIFEST.MF
1
stackoverflowdupquestions
getResourceAsStream returning null despite called file being in same dir as class getResourceAsStream is called in
getResourceAsStream() is always returning null
Why is getResourceAsStream returning null?
1
stackoverflowdupquestions
Setting up JUnit with IntelliJ IDEA
Looking for a tutorial on using JUnit with Intellij IDEA 9.x
AopInvocationException: in @Autowieired in JUnit
1
stackoverflowdupquestions
how to get all attributes of a class?
How to loop over a Class attributes in Java?
How do you print a class's attributes by the objects name using java?
1
stackoverflowdupquestions
Does java support and optimize away tail-recursive calls?
Why does the JVM still not support tail-call optimization?
how i can optimize this java code?
1
stackoverflowdupquestions
Drag and Drop file path to Java Swing JTextField
How can I use Drag-and-Drop in Swing to get file path?
java/swing: drag and drop problems with two child windows
1
stackoverflowdupquestions
Error Occurs while Running Android Project - Unsupported major.minor version
Android Package Builder error : Unsupported Major Minor version 52.0
Java 6 Unsupported major.minor version 51.0
1
stackoverflowdupquestions
How to remove only html tags from text with Jsoup?
Jsoup remove ONLY html tags
Is there a way to access specific attributes of html tags using Java/JSoup?
1
stackoverflowdupquestions
Java 8 Streams: How to call once the Collection.stream() method and retrieve an array of several aggregate values with different fields
Java 8 Streams: How to call once the Collection.stream() method and retrieve an array of several aggregate values
return a value immediately from collection by java 8 streams
1
stackoverflowdupquestions
String and complex data types in Map.xml for IKVM!
IKVM complex custom type error in remapping to properties!
Unity+IKVM / NullReferenceException when calling Java method in dll
1
stackoverflowdupquestions
How can I make Cartesian product with Java 8 streams?
Cartesian product of streams in Java 8 as stream (using streams only)
Using cartesian coordinates in application
1
stackoverflowdupquestions
How do I split strings in J2ME?
Split text in J2ME
What does preverification of J2ME application mean?
1
stackoverflowdupquestions
Is polymorphism possible without inheritance?
What is the main difference between Inheritance and Polymorphism?
Review on Inheritance and polymorphism in Java
1
stackoverflowdupquestions
Is GNU's Java Compiler (GCJ) dead?
Java JRE vs GCJ
Java - dead code in for loop
1
stackoverflowdupquestions
How to make a thread wait for a server response
How to make a Java thread wait for another thread's output?
Thread join() does not wait
1
stackoverflowdupquestions
Immutability of string objects in java
Immutability of Strings in Java
Why is immutability a desired feature in classes?
1
stackoverflowdupquestions
How to convert a LocalDate to an Instant?
Convert java.util.Date to java.time.LocalDate
Joda betweenDays (LocalDate,LocalDate) not applicable
1
stackoverflowdupquestions
Session counter with HttpSessionListener and session count variable access
Using HttpSessionListener to track the total number of session in web application
How can I get HttpServletRequest when in an HttpSessionListener?
1
stackoverflowdupquestions
I get exception when using Thread.sleep(x) or wait()
Difference between wait() and sleep()
How can I get my Thread to sleep
1
stackoverflowdupquestions
CDI interceptor does not work when annotation has parameter
How add FacesMessage to CDI security interceptor?
How to link Custom interceptor using Annotation
1
stackoverflowdupquestions
How to convert a Binary String to UTF-8 String in java?
How to parse String as Binary and convert it to UTF-8 equivalent in Java?
DataEditorSupport and/or ClonableEditor using UTF-8
1
stackoverflowdupquestions
configure log4j to log to custom file at runtime
log4j trying to log in the file
log4j setting log file name @ runtime not working
1
stackoverflowdupquestions
Java Swing. Opening a new JPanel from a JButton and making the buttons pretty
How to open a new JPanel with a JButton?
Java swing JButton order and size
1
stackoverflowdupquestions
Yield Return In Java
Is there a Java equivalent to C#'s 'yield' keyword?
Why does this basic java code yield different outputs?
1
stackoverflowdupquestions
Mapping ManyToMany with composite Primary key and Annotation:
ManyToMany Mapping (Helper Table) + extra Field + Composite Primary Key
how to write hibernate mapping for below table structure with composite primary key
1
stackoverflowdupquestions
Hibernate table not mapped error in HQL query
Hibernate "is not mapped" exception
Hibernate says: table is not mapped -is it true?
1
stackoverflowdupquestions
Jsonparsing error with @JsonIgnore on Hibernate
Only using @JsonIgnore during serialization, but not deserialization
What is the difference between a property with @JsonIgnore and one with no annotation?
1
stackoverflowdupquestions
HttpServletResponse.flushBuffer() on timed out connection does not throw IOException
Java's HttpServletResponse doesn't have isClientConnected method
java.net.ConnectException timed out
1
stackoverflowdupquestions
Flood Fill Optimization: Attempting to Using a Queue
Flood fill using a stack
Tomcat and flood protection
1
stackoverflowdupquestions
Maven dependency for Servlet 3.0 API?
Maven doesn't find dependency
How to find maven dependency that are not used?
1
stackoverflowdupquestions
What is the actual use of the default constructor in java?
Java default constructor
Why would you need to use more than one constructor?
1
stackoverflowdupquestions
CSRF issue while sending POST request from Angular 2 to Spring-backed Java app
Angular 2/Spring Security CSRF implementation problems
How get value element by id - Angular 4
1
stackoverflowdupquestions
Hibernate does not create tables automatically
Does Hibernate create tables in the database automatically
Hibernate join 3 tables
1
stackoverflowdupquestions
Convert HTML Character Back to Text Using Java Standard Library
Convert HTML character code to char in Java
can we convert integer into character
1
stackoverflowdupquestions
How to make JTable column contain checkboxes?
Jtable checkboxes are not editable
How to add checkboxes in list in java
1
stackoverflowdupquestions
Best practices for injecting Swing components using Guice?
How to use Guice in Swing application
Guice injecting only some of the constructor
1
stackoverflowdupquestions
Java generics: Wildcard capture compilation error
Java Generics: Wildcard capture misunderstanding
How do I fix this Java generics wildcard error?
1
stackoverflowdupquestions
permanent background image on a JPanel
JPanel background image
How do I add a background image to a JPanel?
1
stackoverflowdupquestions
java.rmi.ConnectException: Connection refused to host: 127.0.1.1;
java.rmi.ConnectException: Connection refused to host: 10.0.0.57
java.rmi.ConnectException: Connection refused to host when exporting an object client-side
1
stackoverflowdupquestions
How to run TestNG from command line
Running TestNG via Command Line
TestNG run method as last
1
stackoverflowdupquestions
Using a larger prime as a multiplier when overriding hashCode()
Why does Java's hashCode() in String use 31 as a multiplier?
Does hashCode() have to return a prime number?
1
stackoverflowdupquestions
Hibernate one-to-one mapping with a reference column (XML mapping)
Hibernate one-to-one XML mapping
Hibernate list and Set mapping
1
stackoverflowdupquestions
Java google checkstyle Maven
Error using checkstyle/google_checks.xml with maven-checkstyle-plugin
Maven - Dependency on module for Checkstyle not working
1
stackoverflowdupquestions
AspectJ in Maven project, not working/weaving
AspectJ with Maven (still) not working
How to enable aspectj compile time weaving with Java 7 and maven
1
stackoverflowdupquestions