Questions tagged [java]

Java (not to be confused with JavaScript or JScript or JS) is a general-purpose object-oriented programming language designed to be used in conjunction with the Java Virtual Machine (JVM). "Java platform" is the name for a computing system that has installed tools for developing and running Java ...

0
votes
2answers
11 views

java.security.cert.CertPathValidatorException: Certificate chaining error upon webservice call

I have added a server cert on my machine and trying to make a webservice call to server through a java program. If I run the java application while connected to ethernet, I am able to get ...
0
votes
1answer
23 views

How to use FAB to cycle between options?

I have a fragment in which I want to have a main ImageButton in the center and 2 FAB's on either side that would go to the previous or next Image respectively. I have this set up in XML but can't ...
-1
votes
1answer
27 views

How to pass Custom Object from one Activity to Another Activity in Android?

I want to send a custom Object from on Activity to Another. And Somehow i can't use Serializable or Parcelable. This is what i am doing.from A -> BResult<String> res=(Result<String>) ...
0
votes
0answers
7 views

org.openqa.selenium.WebDriverException: unknown error: session deleted because of page crash from tab crashed

I am using Chrome 66, chromedriver 2.38 On linux through a jenkins joband getting org.openqa.selenium.WebDriverException: unknown error: session deleted because of page crash from tab crashed , when ...
0
votes
0answers
9 views

Amazon Cognito error from android studio (java)

I am trying to call an Amazon Lambda function from my android app using java. I get this error: com.amazonaws.AmazonClientException: Unable to execute HTTP request: Unable to resolve host "cognito-...
-1
votes
1answer
47 views

How to remove largest number in binary search tree?

I know how to build a binary tree, but I need a methodpublic void delMax() which removes the largest number of the tree. So that means I have to remove the value which is in the last position on the ...
0
votes
0answers
16 views

Convert spark row object to java pojo

In Spark we can convert the Dataset to Java POJO using df.as[POJO].I have a use case where I am joining two datasets and want to convert the Row object to Java POJO.Row Object Schema after join:...
0
votes
0answers
7 views

Separating out test results with Maven Surefire when in parallel

I've recently begun using the Maven Surefire fork parameter in order to run my unit tests in parallel. It works great, except that the output is completely interleaved from the different tests. I'm ...
-1
votes
2answers
17 views

JAR resource inputstream does not read requested size [on hold]

I run the following code:public static void main(String[] args) {InputStream stream=ClassLoader.getSystemResourceAsStream("resources/fonts/calibri.texture");try {int n=458343;...
-1
votes
0answers
15 views

Load pagination when you click a button

I'm following this tutorial, I just rephrase that same code. But it loads the page all at once. And I wanted a button and when I clicked to load the next page instead of pulling all the pages at once...
0
votes
0answers
17 views

Restrict access outside corporate network

I hope I can get some idea for my requirement. I am working on an application which is hosted on cloud. This application can be accessed from outside company network too. It is a web based spring boot ...
0
votes
0answers
18 views

Maven Deploy ignore already uploaded artifacts

I am using the maven deploy command to upload generated artifacts to jfrog artifactory. This command works well, but in sometimes the Jfrog returns to me an error 500 Internal server error for any ...
0
votes
0answers
15 views

custom FXML component not loading - classnotfoundexception

I have followed tutorials and created my own custom element. It is an AnchorPane containing 6 overlapped canvases to create a graphing framework.Below is the magnitudeGraph.fxml<?xml version="1....
-1
votes
1answer
15 views

Watson Speech to Text request using Websockets and JAVA

I am trying to request a transcription of an MP3 file using Websockets and Java. The following is a snippet of my Maven dependency followed by the java code . I've put breakpoints in each of the ...
-1
votes
1answer
30 views

Redundant Value Elimination from a File in java

I have a datafile name Test_1.txt. This data file consist of 12 rows and 3 columns.The Column which is extreme left known as ID column. This Id has a redundant Ids. I want to write a Java program ...
0
votes
1answer
33 views

Jackson json two way object reference

I have a pair of objects likepublic class Obj1 {public int id;public String name;public Obj2 obj2;}public class Obj2 {public int id;public String name;public List<...
1
vote
1answer
22 views

chef-run windows unexpected end-of-input, expecting keyword_end

I'm trying to install java jdk 8 onto an ubuntu 16.04 instance using chef-run. Although when it attempts to install I get Failed to converge target, when I open the logs I have the following:[2018-...
0
votes
2answers
26 views

Get reference from a String variable at defined position

I've a String variable named paths which has AbsolutePath to all files named as "micky"in a directory.The value of paths variable is-sdcard/0/albums/micky1.jpgsdcard/0/albums/micky2.jpgsdcard/0/...
0
votes
2answers
64 views

for loop is not working correctly after first loop [duplicate]

I wish to create a simple TicTacToe GUI Game by using Swing;I created JFrame called TicTacToe and put JPanel in it called gamePanel with GridLayout(3,3). Then I created a button array called buttons[]...
0
votes
0answers
11 views

Wildfly 12 unable to lookup java:jboss/UserTransaction

I have configured hibernate 4.3 with wildfly 12. In hibernate I have set the following properties for transactions.<property name="hibernate.transaction.jta.platform" value="org.hibernate.engine....
1
vote
0answers
16 views

How to create RealmList<RealmList<Object>> in android

I am trying to get a RealmList of RealmList from server (JSON) into realm object. I am gettingerror: Element type of RealmList must be a class implementing 'RealmModel' or one of the 'java.lang....
2
votes
1answer
17 views

Multiple Java installation pointing to one cacert file in a share path

I have many applications on different servers and each application uses many versions of Java. Now whenever we renew SSL certificate we have to copy imported cacerts file to all the Java on all the ...
2
votes
0answers
16 views

IllegalStateException on setRequestedOrientation

i have a question about getting an IllegalStateException by calling setRequestedOrientation. So in order that we have the portrait orientation globally I do it the following way:...
1
vote
0answers
20 views

how to retrive images in android image view

please am working on a class project which i will submit soon and i need your help.am trying to get image saved in varbinary format in my sql server 2016 into my android Image view.i have been stock ...
0
votes
0answers
8 views

get relationId from image in paragraph

Hello I have a doc with image and I'm looking for how retrieve relationId of an image in one of my paragraph.Currently I have document.getParagraphs() When my paragraph contain a picture I create ...
0
votes
1answer
22 views

ArrayList groupby in java android based on same attributes without java 8 stream and lambda

My object looks something like belowclass Item{String color;int price;int size;}Now my arraylist contains objects of type item I want to create sublist of items having same ...
0
votes
1answer
14 views

Send json using jackson and spring boot

I need to send a json to a web address where this json will be consumed, basically I have a list of Dto's that I need to turn into a Json (with jackson).Some information must be passed in the header:...
0
votes
0answers
7 views

Registering a custom ValueParamProvider in Jersey 2.27

I realize that these are internal APIs, but if they're available internally why not make them usable by the less privileged masses, and they're also extremely useful. Even though these APIs were ...
0
votes
0answers
3 views

Play video in View pager itself in recycleview

Hi everyone I made a recycleview auto play video and I set video in view pager like Instagram does Video view pager Here a Video if you dont understand What I mean , My problem is the video still ...
1
vote
2answers
30 views

Best approach to store a set of static String values

I have a requirement to retrieve query params lets say clId,clCtx and clName from an odata uri and use them throughout the program across many classes. Retrieving the query params is an expensive ...
0
votes
0answers
7 views

How do I get solver tasks in ojalgo to return the correct size result

I am trying various implementers of SolverTask with the intent of solving A * x=b, where A is 601 x 1100 and b is 601 x 1 in my tests. So far I have tried GaussSeidelSolver and JacobiSolver, both by ...
-2
votes
0answers
46 views

What's the difference between mBirthMonth + 1 & mBirthMonth+1? [on hold]

I'm using birthday month in Android. I changed above mBirthMonth + 1 to mBirthMonth+1 while saving it and it changed the result. Month was going +1 or -1 before. Now it looks fine. Below is my code ...
0
votes
0answers
8 views

Data Driven using TestNG whith Selenium WebDriver Erro [duplicate]

I'm trying to use DataDriven with TESTNG in Selenium WebDriver. At http://toolsqa.com/selenium-webdriver/testng-data-provider-excel/, has a tutorial teaching how to do. As described on the site, I ...
-3
votes
1answer
9 views

Error:Execution failed for task ':app:javaPreCompileDebug'

android {compileSdkVersion 27defaultConfig {applicationId "downloader.video.full.videodownloader"minSdkVersion 15targetSdkVersion 27versionCode 1versionName "1.1"useLibrary 'org....
0
votes
0answers
14 views

Java - FileWatcher for Directory - Rename Implementation

I have the following code which watches the files in the directory recursively. The ouput when I rename a file looks like this:ENTRY_DELETE: C:\Users\Robin\Desktop\cloud\Name1.txtENTRY_CREATE: C:\...
-1
votes
1answer
52 views

What's the time complexity for downcasting an object?

I received a generic Object type instance from a RPC service that I want to cast to a MyClass type instance, what is the time complexity for this operation? Performance is critical to my application. (...
1
vote
1answer
31 views

Can't fix android.content.res.Resources$NotFoundException

My app keeps crushing, please help.06-21 18:46:01.110 4932-4932/plusultra.customdice E/AndroidRuntime: FATAL EXCEPTION: mainProcess: plusultra.customdice, PID: 4932android.content.res.Resources$...
1
vote
1answer
31 views

Getting subset of application.properties by prefix

I have (partly) this application.properties in my Spring Boot app:spring.main.banner-mode=offapp.set.a=100app.set.b=abcapp.set.c# ...I want to get injected a Properties object with all ...
0
votes
0answers
10 views

How to fix SSL handshake timed out in Retrofit on Android

In my application I want get data from server and show this into RecyclerView.For get data from server I use Retrofit2 and I write below codes.But when running application after some time show me E/...
0
votes
2answers
100 views

Ajax POST FormData throw exception in Spring MVC

Yesterday I had a similar problem where Ajax POST method returned 405 error which was caused by csrf token. Someone helped mi with this, but now I'm powerless what is happening. I have an Ajax POST ...
1
vote
0answers
19 views

Hibernate - handling SQLException

All,I am working on a project to upgrade hibernate from 4.1.4.FINAL to 5.2.17.FINAL. We have a bunch of Sybase stored procedures executed using org.hibernate.jdbc.Work. These stored procedures raise ...
0
votes
0answers
12 views

DropWizard Mustache View Configuration

Edit: I am using dropwizard 1.3.4I'm looking to disable the caching of Mustache views within drop wizard. The documentation https://www.dropwizard.io/1.3.4/docs/manual/views.html says that this is ...
1
vote
0answers
6 views

Spring boot project unable to resolve symbol SpringockitoContextLoader

I am getting error " cant resolve symbol SpringockitoContextLoader" on this following line in test package@ContextConfiguration(loader=SpringockitoContextLoader.class .... I have migrated to ...
0
votes
0answers
10 views

How to convert a tif image and create a jpg thumnail in java?

I have a tif image and i need convert this image to a thumbnail file 200x200 and 1200x1200I do the tif convert using this code:import java.awt.image.RenderedImage;import java.awt.image.renderable....
-1
votes
0answers
14 views

C# equivalent for @AndroidFindBy which is used in Java?

I am doing an Appium automation project for a hybrid app. So I need the same script to run both in IOS and Android. To locate some native elements, I need something like @AndroidFindBy and @IOSFindBy ...
-3
votes
1answer
36 views

getting StringIndexOutOfBound Exception [duplicate]

I am writing a program to accept user name and password using following conditions- username must be min 8 characters. Password must have min 10 characters, 1 lowerCase, 1 upperCase, 1 digit should ...
1
vote
0answers
11 views

Android troubles with Image compression to reduce size

I chose an image to be shown on the screen, then I can choose to upload it to firebase. However the images are 2-4mb, and I want to make them smaller without much loss in quality. Is there anyway I ...
0
votes
0answers
14 views

Not able to post unicode characters to ElasticSearch, they show up as question marks

I am storing emails to ElasticSearch but whenever they have a character not from iso latin like "コニカミノルタ", they get changed to ? in ES:"content": """????????? ??????????????????I am ...
-1
votes
0answers
15 views

Is there library for serializing a list of thrift object to file and deserializing the file to a list of thrift object? [on hold]

I want to encode and serialize a list of data into a large file and send the file over network.Right now I am custom encoding these data into a file and sending them over the network.But this is ...
0
votes
0answers
8 views

EDGE crashes with webDriver

I’m using,◦Selenium 3.12.0 ◦Java binding ◦Windows 10 (build 15063.1029) ◦EDGE driver (Version: 4.15063 | Edge version supported: 15.15063 )Here is my code to open the browserimport org....

153050per page
angop.ao, elkhabar.com, noa.al, afghanpaper.com, bbc.com, time.com, cdc.gov, nih.gov, xnxx.com, github.com,