Questions tagged [runtimeexception]

RuntimeException is the superclass of those exceptions that can be thrown during the normal operation of the Virtual Machine.

RuntimeException is the superclass of those exceptions that can be thrown during the normal operation of the Virtual Machine.

1062 questions
4
votes
2 answers

When does java.lang.EnumConstantNotPresentException gets thrown?

As per java API EnumConstantNotPresentException gets thrown when an application tries to access an enum constant by name and the enum type contains no constant with the specified name. Thus I decided to come up with a scenario where…
sactiw
  • 21,935
  • 4
  • 41
  • 28
4
votes
0 answers

How to send a message to Handler on a dead thread

I have a start and stop job method that checks to see if my connection is maintained. This is for a softphone app so the connection needs to be on as long as the user has the app opened. The code for these methods are below public void startJob(){ …
BigT
  • 1,413
  • 5
  • 24
  • 52
4
votes
1 answer

java.net.MalformedURLException - at parsing XML file by StAX

I have to parse XML file with StAX. I caught bunch of exceptions: javax.xml.stream.XMLStreamException: java.net.MalformedURLException at com.sun.org.apache.xerces.internal.impl.XMLStreamReaderImpl.setInputSource(XMLStreamReaderImpl.java:217) …
catch23
  • 17,519
  • 42
  • 144
  • 217
4
votes
4 answers

RuntimeException: native typeface cannot be made or memory leak for custom TextView loading font

There's a HUGE problem in my code wherein I am loading a font in my assets\fonts\ folder from a custom TextView class. The first problem is that it crashes on 4.0 devices with the exception Caused by: java.lang.RuntimeException: native typeface…
4
votes
3 answers

Proguard and libgdx: RuntimeException

I'm developing an android live wallpaper with libgdx and I've got a big problem when I use proguard. This is the error when my livewallpaper is starting: 08-17 13:55:50.755: E/AndroidRuntime(28276): FATAL EXCEPTION: main 08-17 13:55:50.755:…
Domenico Maiuri
  • 191
  • 1
  • 1
  • 10
4
votes
2 answers

int i=99 is working however int i = 099 not working

In Java, I noticed that when I write int i = 99; it works fine. However when I say int i = 099; I get an exception: java.lang.RuntimeException: Uncompilable source code - Erroneous tree type: In my IDE, I see a red dot saying integer…
Fahim Parkar
  • 30,974
  • 45
  • 160
  • 276
4
votes
1 answer

Method Over riding and Inheritance and Exceptions

Can a method in a subclass override a method in the parent class and throw a run time exception when the method in the parent class throws no exception? Something like this: class X { public void foo() { System.out.print("X "); } } public class…
praxmon
  • 5,009
  • 22
  • 74
  • 121
4
votes
1 answer

What is causing this in android webView?

I am getting the following exception and not able to debug it. Please help. Code: public class HybridActivity extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle…
Smitha
  • 6,110
  • 24
  • 90
  • 161
3
votes
4 answers

Design issue: to what extent should I rely on exceptions for the flow of control?

I am working on a java web application and I have a few questions regarding design. Basically in its current version, it relies heavily on catching exceptions to determine the flow of control. For instance in one of my spring service classes, I have…
balteo
  • 23,602
  • 63
  • 219
  • 412
3
votes
2 answers

how to resolve org.eclipse.core.internal.resources.ResourceException

I never encountered this exception before org.eclipse.core.internal.resources.ResourceException: Resource '/External Plug-in Libraries' is not open. at org.eclipse.core.internal.resources.Project.checkAccessible(Project.java:137) at…
Arifah Azhar
  • 227
  • 1
  • 5
  • 17
3
votes
1 answer

Why am I getting a nullPointerException when Clojure code calls a JPanel function?

I am having trouble determining why my code gets a nullPointer exception. I'm trying to write a swing application using a combination of Java and Clojure. I have a Clojure function that calls a function in my JPanel subclass, and I'm getting a lot…
Joel
  • 1,437
  • 2
  • 18
  • 28
3
votes
0 answers

takePicture RuntimeException Android

I've developed an app which has got a service taking snapshots in the background. Whilst this app runs okay in all the devices I've tried so far (not Motorola ones), I found that running it on a Bionic Droid, crashes. Basically, what I'm doing…
mindless
  • 51
  • 1
  • 3
3
votes
0 answers

How to define a no-argument constructor in Kotlin file with @Parcelize annotation

I am making an app using Firebase Firestore and Authentication. It is logging the user properly but as soon as the user gets authenticated, the app crashes. It gives a runtime exception. Could not deserialize object. Class…
3
votes
2 answers

How to stop my App from crashing after switching back from another app?

When I run my app and press home button and then come back to my app, I get RunTimeException and IllegalStateException errors. I made a simple Android Alphabet game with sounds where at the end of the game, the amount of time and the number of…
user258959
  • 91
  • 6
3
votes
1 answer

java.lang.RuntimeException: Unsupported literal type class org.joda.time.DateTime

I work on a project where I use a library, which is very new to me, although I was using it in other projects, without any problems. org.joda.time.DateTime So I work with Scala, and run the project as a job on Databricks. scalaVersion :=…
Eve
  • 604
  • 8
  • 26