Java
-
[in java.lang.string; cannot be cast to java.lang.string
I'm getting vector from the product's API Vector<?> dataVector = dataAPI.getReturnVector(); The expected vector …… -
Java – how to get a class literal from a general specific class
Such a method requires class text as a parameter Collection<EmpInfo> emps = SomesqlUtil.select( EmpInfo.…… -
Make the Java program return value to call the shell script
UNIX master! I have a java program that passes some parameters to a servlet The servlet inputs the information into a …… -
Java – reference classes are constructed by classes
I am a web developer (game developer as a hobby) and I have seen myself using the following example several times (bot…… -
Java – creates a heap dump from within the application without the need for a hotspot diagnostic mxbean
How to create heap dumps in my application without using the hotspotdiagnosticmxbean class >This solution does not …… -
Java – how do I ignore certain types of uncapped exceptions in eclipse?
I use third - party libraries in my java applications This third - party library throws a custom uncapped exception wh…… -
Java – logback file error: [rollingpolicy] has no applicable operation. The current mode is [[configuration] [appender] [rollingpolicy]]
I am using login akka to write the log to the file. Everything is good until my log file stops writing the log. Maybe …… -
Java – the keyword “class” is in the declaration
I was faced with a rather simple question in the interview Why do we use the class keyword to declare classes? Solutio…… -
Java – use system exit(0)
public class WrapperTest { public class WrapperTest { static { print(10); } static void print(int…… -
Unable to find Java nio. File package
My java compiler can't find Java nio. File package consider: import java.nio.file.*; public class Test { public st…… -
Java – pdfbox: attempt to decrypt pdf
The following this answer I tried to use pdf@R_300_2419 @Decrypt PDF document: PDDocument pd = PDDocument.load(path); …… -
Java – a design pattern that transforms one model into another
Basically, there are some objects in my application that I have to convert to another third-party object before sendin…… -
Java – generic image loader: bad bitmap attached to ImageView
I've been evaluating Nostra's universal image loader library to asynchronously download images and display them in lis…… -
How to print string with newline character in Java
I need to use java to print a string, so I like the following solutions, which have been searched a lot by Google I ma…… -
Java – form field values set using pdfbox are not visible in adobe reader
I tried to use some Apache PDF@R_493_2419 @(1.8.5) to set some problems I have several different static PDFs that I us…… -
Illegalcomponentstateexception in Java Swing
When making the basic Java Swing program, I made a strange mistake. I only made it on my computer (I tried the other t…… -
Java antivirus… Is it possible? What about?
Can I write anti-virus programs in Java, for example, can I intercept the execution of programs? Can I have such deep …… -
Java – why string Indexof does not use exceptions, but returns – 1 when no substring is found?
Why string Indexof does not use exceptions, but returns - 1 if no substring is found? The purpose of this problem is: …… -
Java – retrieves the subdocuments in the array as dbobjects
I'm new to mongodb. I'm using a Java driver I have this file structure: { "_id" : ObjectId("4f7d2ba6fd5a306d82687d48")…… -
How to use generics in Java to return numbers?
I have a class similar to the following, but I have a question about using generic return values import java.util.Arra…… -
Perform: creates a local backup of the current pending list
In perforce, I have a list of files to change Now I want to go back to the base, but I haven't loosened my changes, so…… -
Java – multithreaded gae servlet to handle concurrent users
I want to multithread my gae servlet so that the same servlet on the same instance can process up to 10 concurrent req…… -
Opencv – how to interpolate between data points?
I am developing a software using OpenCV and QT to draw data points I need images that can fill in incomplete data I wa…… -
Java – enable lambda expressions
In the program entities.stream().filter(m->m.getId()==id).findAny().get(); Where entities are lists Set all librari…… -
Java – get only the date of the timestamp
This is my following function. I'm passing a timestamp. I just need to return the date from the timestamp, not the hou…… -
Java – how to create MVC based applications without using frameworks
Struts, spring and several other frameworks implement MVC architecture to separate the representation of information f…… -
Java – set the default value to a variable when deserializing with gson
I'm trying to convert JSON to Java objects When a value of a pair is empty, some default values should be set This is …… -
Java – why are private fields on enumeration types visible to containing classes?
public class Parent { public class Parent { public enum ChildType { FIRST_CHILD("I am the first."),SECON…… -
Declare a byte array in Java
How to declare a finite byte array? That's what I'm thinking, but it doesn't work. I can't find anything private Integ…… -
Java – how to put scanner input into an array… For example, several numbers
Scanner scan = new Scanner(system.in); Scanner scan = new Scanner(system.in); double numbers = scan.nextDouble(); doub…… -
Java – JPS does not display Tomcat processes
I run Tomcat 6.0 on Ubuntu 10.10 31, and use tge sun JDK (java-6-sun) Although Tomcat is running, when I run JPS (Java…… -
java. Lang.illegalaccesserror: attempt to access field concreteentity. From class entity instance
OK, so here's the deal I'm trying to access concreteentity Instance, which is the default field of the access type exi……