Codota Logo
RuntimeErrorException
Code IndexAdd Codota to your IDE (free)

How to use
RuntimeErrorException
in
javax.management

Best Java code snippets using javax.management.RuntimeErrorException (Showing top 20 results out of 369)

Refine searchRefine arrow

  • RuntimeOperationsException
  • MBeanException
  • Common ways to obtain RuntimeErrorException
private void myMethod () {
RuntimeErrorException r =
  • Codota IconString str;new RuntimeErrorException(new Error(str))
  • Codota IconThrowable throwable;new RuntimeErrorException((Error)throwable)
  • Codota IconString str;new RuntimeErrorException(null, str)
  • Smart code suggestions by Codota
}
origin: apache/geode

 throw new MBeanException(new ServiceNotFoundException(
   "Could not find target"));
 throw new ReflectionException(x);
} catch (IllegalArgumentException x) {
 throw new MBeanException(x);
} catch (InvocationTargetException x) {
 Throwable t = x.getTargetException();
 if (t instanceof Error)
  throw new MBeanException(new RuntimeErrorException((Error) t));
 else
  throw new MBeanException((Exception) t);
origin: spring-projects/spring-framework

throw ex.getTargetException();
throw ex.getTargetError();
RuntimeException rex = ex.getTargetException();
if (rex instanceof RuntimeMBeanException) {
  throw ((RuntimeMBeanException) rex).getTargetException();
  throw ((RuntimeErrorException) rex).getTargetError();
origin: org.jboss.mx/jboss-mbeans

throw new RuntimeOperationsException(new IllegalArgumentException("attribute cannot be null"));
 throw new MBeanException((Exception) t, "Exception in MBean when getting attribute '" + attribute + "'");
 throw new RuntimeErrorException((Error) t, "Error in MBean when getting attribute '" + attribute + "'");
throw new RuntimeErrorException(e, "Error in AttributeProvider for getting '" + attribute + "'");
origin: ninjaframework/ninja

/**
 * Simply reads a property resource file that contains the version of this
 * Ninja build. Helps to identify the Ninja version currently running.
 * 
 * @return The version of Ninja. Eg. "1.6-SNAPSHOT" while developing of "1.6" when released.
 */
private final String readNinjaVersion() {
  
  // location of the properties file
  String LOCATION_OF_NINJA_BUILTIN_PROPERTIES = "ninja/ninja-builtin.properties";
  // and the key inside the properties file.
  String NINJA_VERSION_PROPERTY_KEY = "ninja.version";
  
  String ninjaVersion;
  try (InputStream stream = Thread.currentThread().getContextClassLoader().getResourceAsStream(LOCATION_OF_NINJA_BUILTIN_PROPERTIES)){
    Properties prop = new Properties();
    prop.load(stream);
    
    ninjaVersion = prop.getProperty(NINJA_VERSION_PROPERTY_KEY);
  
  } catch (Exception e) {
    //this should not happen. Never.
    throw new RuntimeErrorException(new Error("Something is wrong with your build. Cannot find resource " + LOCATION_OF_NINJA_BUILTIN_PROPERTIES));
  }
  
  return ninjaVersion;
  
}

origin: org.jboss.mx/jboss-jmx

 t = e.getTargetException();
 if (t instanceof InstanceAlreadyExistsException)
   throw (InstanceAlreadyExistsException) t;
 throw new RuntimeMBeanException((RuntimeException) result);
if (result instanceof Error)
 throw new RuntimeErrorException((Error) result);
origin: org.jboss.jbossas/jboss-as-j2se

/**
* Handles runtime exceptions and rethrows them wraped if neccessary, arccording to the spec.
*
* @param e the exception thrown by the invocation
*/
private static void handleRuntimeExceptionOrError(Throwable e)
{
 // is already of throwable type
 if (e instanceof RuntimeOperationsException)
   throw (RuntimeOperationsException)e;
 if (e instanceof RuntimeErrorException)
   throw (RuntimeErrorException)e;
 if (e instanceof RuntimeMBeanException)
   throw (RuntimeMBeanException)e;
 // wrap java core runtime exceptions
 if (e instanceof IllegalArgumentException)
   throw new RuntimeOperationsException((IllegalArgumentException)e);
 if (e instanceof IndexOutOfBoundsException)
   throw new RuntimeOperationsException((IndexOutOfBoundsException)e);
 if (e instanceof NullPointerException)
   throw new RuntimeOperationsException((NullPointerException)e);
 // wrap any error
 if (e instanceof Error)
   throw new RuntimeErrorException((Error)e);
 // wrap any runtime exception
 if (e instanceof RuntimeException)
   throw new RuntimeMBeanException((RuntimeException)e);
}
origin: org.eclipse.microprofile.fault-tolerance/microprofile-fault-tolerance-tck

Thread.sleep(millis / 2);
fails--;
RuntimeErrorException e = new RuntimeErrorException(new Error("fake error for Retry Testing"));
Utils.log(e.toString());
origin: org.jboss.seam/jboss-seam

public Object handleRuntimeError(ProxyContext ctx, RuntimeErrorException e,
                Method m, Object[] args)
                throws Exception
{
 // just unwrap and throw the actual error
 throw e.getTargetError();
}
origin: org.jboss.jbossas/jboss-as-mbeans

throw new RuntimeOperationsException(new IllegalArgumentException("attribute cannot be null"));
 throw new MBeanException((Exception) t, "Exception in MBean when getting attribute '" + attribute + "'");
 throw new RuntimeErrorException((Error) t, "Error in MBean when getting attribute '" + attribute + "'");
throw new RuntimeErrorException(e, "Error in AttributeProvider for getting '" + attribute + "'");
origin: nodebox/nodebox

public Image(File file) {
  if (file == null || file.getPath().equals(BLANK_IMAGE)) {
    image = blankImage;
  } else {
    try {
      image = ImageIO.read(file);
    } catch (IOException e) {
      throw new RuntimeErrorException(null, "Could not read image " + file);
    }
  }
}
origin: org.jboss.jbossas/jboss-as-jmx

 t = e.getTargetException();
 if (t instanceof InstanceAlreadyExistsException)
   throw (InstanceAlreadyExistsException) t;
 throw new RuntimeMBeanException((RuntimeException) result);
if (result instanceof Error)
 throw new RuntimeErrorException((Error) result);
origin: org.jboss.mx/jboss-mbeans

/**
* Handles runtime exceptions and rethrows them wraped if neccessary, arccording to the spec.
*
* @param e the exception thrown by the invocation
*/
private static void handleRuntimeExceptionOrError(Throwable e)
{
 // is already of throwable type
 if (e instanceof RuntimeOperationsException)
   throw (RuntimeOperationsException)e;
 if (e instanceof RuntimeErrorException)
   throw (RuntimeErrorException)e;
 if (e instanceof RuntimeMBeanException)
   throw (RuntimeMBeanException)e;
 // wrap java core runtime exceptions
 if (e instanceof IllegalArgumentException)
   throw new RuntimeOperationsException((IllegalArgumentException)e);
 if (e instanceof IndexOutOfBoundsException)
   throw new RuntimeOperationsException((IndexOutOfBoundsException)e);
 if (e instanceof NullPointerException)
   throw new RuntimeOperationsException((NullPointerException)e);
 // wrap any error
 if (e instanceof Error)
   throw new RuntimeErrorException((Error)e);
 // wrap any runtime exception
 if (e instanceof RuntimeException)
   throw new RuntimeMBeanException((RuntimeException)e);
}
origin: org.jboss.jbossas/jboss-as-j2se

public Object handleRuntimeError(ProxyContext ctx, RuntimeErrorException e,
                Method m, Object[] args)
                throws Exception
{
 // just unwrap and throw the actual error
 throw e.getTargetError();
}
origin: org.apache.coyote.springsource/com.springsource.org.apache.coyote.springsource

  throw new RuntimeOperationsException
    (new IllegalArgumentException("Attribute name is null"),
     "Attribute name is null");
    t = e;
  if (t instanceof RuntimeException)
    throw new RuntimeOperationsException
      ((RuntimeException) t, "Exception invoking method " + name);
  else if (t instanceof Error)
    throw new RuntimeErrorException
      ((Error) t, "Error invoking method " + name);
  else
    throw new MBeanException
      (e, "Exception invoking method " + name);
} catch (Exception e) {
  throw new MBeanException
    (e, "Exception invoking method " + name);
origin: org.jboss.mx/jboss-mbeans

private void rethrowAsMBeanException(Throwable t) throws MBeanException
{
 if (t instanceof RuntimeException)
   throw new RuntimeMBeanException((RuntimeException) t);
 else if (t instanceof Error)
   throw new RuntimeErrorException((Error) t);
 else
   throw new MBeanException((Exception) t);
}
origin: org.springframework/spring-context

throw ex.getTargetException();
throw ex.getTargetError();
RuntimeException rex = ex.getTargetException();
if (rex instanceof RuntimeMBeanException) {
  throw ((RuntimeMBeanException) rex).getTargetException();
  throw ((RuntimeErrorException) rex).getTargetError();
origin: nodebox/nodebox

public static Image fromData(byte[] data) {
  InputStream istream = new BufferedInputStream(new ByteArrayInputStream(data));
  try {
    return new Image(ImageIO.read(istream));
  } catch (IOException e) {
    throw new RuntimeErrorException(null, "Could not read image data.");
  }
}
origin: org.jboss.mx/jboss-jmx

 t = e.getTargetException();
 if (t instanceof InstanceNotFoundException)
   throw (InstanceNotFoundException) t;
 throw new RuntimeMBeanException((RuntimeException) result);
if (result instanceof Error)
 throw new RuntimeErrorException((Error) result);
origin: apache/felix

throw new RuntimeOperationsException(new IllegalArgumentException("ObjectName cannot be null or a pattern ObjectName"));
throw new RuntimeOperationsException(new IllegalArgumentException("Domain 'JMImplementation' is reserved for the JMX Agent"));
throw new MBeanRegistrationException(new RuntimeErrorException(x));
origin: org.jboss.jbossas/jboss-as-mbeans

throw new RuntimeOperationsException(new IllegalArgumentException("attribute cannot be null"));
 throw new MBeanException((Exception) t, "Exception in MBean when setting attribute '" + attribute.getName() + "'");
 throw new RuntimeErrorException((Error) t, "Error in MBean when setting attribute '" + attribute.getName() + "'");
throw new RuntimeErrorException(e, "Error in AttributeProvider for setting '" + attribute.getName() + "'");
javax.managementRuntimeErrorException

Most used methods

  • <init>
  • getTargetError
  • toString

Popular in Java

  • Making http requests using okhttp
  • setScale (BigDecimal)
  • scheduleAtFixedRate (Timer)
    Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay.
  • requestLocationUpdates (LocationManager)
  • Component (java.awt)
    A component is an object having a graphical representation that can be displayed on the screen and t
  • DateFormat (java.text)
    Formats or parses dates and times.This class provides factories for obtaining instances configured f
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • TimeZone (java.util)
    TimeZone represents a time zone offset, and also figures out daylight savings. Typically, you get a
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now