Package com.sun.jini.tool.envcheck.Reporter

Examples of com.sun.jini.tool.envcheck.Reporter.Message


     *               the subtask was launched
     */
    protected void handleUnexpectedSubtaskReturn(Object returnedValue,
             String source)
    {
  Message message;
  if (returnedValue == null) {
      message = new Message(Reporter.ERROR,
          Util.getString("abstractPlugin.nullvalue",
             abstractBundle),
          null);
      Reporter.print(message, source);
      Thread.dumpStack();
  } else if (!(returnedValue instanceof Throwable)) {
      message = new Message(Reporter.ERROR,
          Util.getString("abstractPlugin.unknownObject",
             abstractBundle,
             returnedValue.toString()),
          null);
      Reporter.print(message, source);
      Thread.dumpStack();
  } else { // force stack trace, don't pass exception in the message
      Throwable t = (Throwable) returnedValue;
      message = new Message(Reporter.ERROR,
          Util.getString("abstractPlugin.excReturn",
             abstractBundle,
             t.getMessage()),
          null);
      System.err.println(Util.getString("abstractPlugin.excReturn",
View Full Code Here


  String source =
      gd == null ? getString("vmsource")
                 : getString("groupsource", gd.getServerCommand());
  Object o = envCheck.launch(null, gd, taskName("JSKPolicyTask"));
  if (o instanceof Boolean) {
      Message message;
      if (((Boolean) o).booleanValue()) {
    message = new Message(Reporter.INFO,
              getString("policyOK"),
              getString("policyExp"));
      } else {
    message = new Message(Reporter.ERROR,
              getString("policyBad"),
              getString("missingPolicyExp"));
      }
      Reporter.print(message, source);
  } else {
View Full Code Here

    /**
     * Performs the check
     */
    private void checkAvailability() {
  Message message;
  String taskName = taskName("CheckActivationTask");
  // OK if envCheck.getGroupDescriptor() returns null
  Object launchReturn = envCheck.launch(null,
                envCheck.getGroupDescriptor(),
                taskName);
  if (launchReturn == null) {
      message = new Message(Reporter.INFO,
          getString("running"),
          getString("explanationString"));
  } else {
      Throwable ex = (Throwable) launchReturn;
      Throwable t = ex.getCause();
      if (t == null) {
    t = ex;
      }
      if (t instanceof java.rmi.ConnectException) {
    message = new Message(Reporter.WARNING,
              getString("notRunning"),
              t,
              getString("explanationString"));
      } else if (t instanceof AccessControlException) {
    message = new Message(Reporter.WARNING,
              getString("nopermission"),
              t,
              getString("noPermExplanationString"));
      } else {
    message = new Message(Reporter.WARNING,
              getString("unexpectedException"),
              ex,
              getString("unexpectedExplanationString"));
      }
  }
View Full Code Here

TOP

Related Classes of com.sun.jini.tool.envcheck.Reporter.Message

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.