Package org.olat.core.logging

Examples of org.olat.core.logging.OLATRuntimeException


    OutputStream out = target.getOutputStream(false);
    if (out == null) {
      String name = target.getName();
      if (target instanceof LocalImpl)
        name = ((LocalImpl)target).getBasefile().getAbsolutePath();
      throw new OLATRuntimeException(ZipUtil.class, "Error getting output stream for file: " + name, null);
    }
    ZipOutputStream zipOut = new ZipOutputStream(out);
    for (Iterator<VFSItem> iter = vfsFiles.iterator(); iter.hasNext();) {
      success = success && addToZip(iter.next(), "", zipOut);
    }
View Full Code Here


  /**
   * Used by framework startup mechanism, don't call this yourself
   */
  public I18nModule() {
    super();
    if (INSTANCE != null) { throw new OLATRuntimeException("Tried to construct I18nModule, but module was already loaded!", null); }
    INSTANCE = this;
  }
View Full Code Here

    }
    //
    // Finished detecting available languages
    //
    // Proceed with some sanity checks
    if (availableLanguages.size() == 0 || !availableLanguages.contains(Locale.ENGLISH.toString())) { throw new OLATRuntimeException(
        "Did not find any language files, not even 'en'! At least 'en' must be available. NOTE: IN DEVELOPMENT ENVIRONMENTS, try setting brasato.src in the build.properties file to something like <your_workspace_dir>/olatcore/src/main/java/", null); }
    List<String> toRemoveLangs = new ArrayList<String>();
    //
    // Build list of all locales and the overlay locales if available
    for (String langKey : availableLanguages) {
View Full Code Here

   */
  public void setValues(String[] values) {
    if (values == null) { // no selection made (possible for radioboxes, but not
      // for dropdown list) -> selected = -1
      //selected = -1;
      throw new OLATRuntimeException(StaticSingleSelectionElement.class, "error.noformpostdata", null, PACKAGE, "no value submitted!, name of element:"+getName(), null);
    }
    if (values.length != 1) throw new AssertException("got multiple values in singleselectionelement:" + getName());
    String key = values[0];
    selected = findPosByKey(key);
  }
View Full Code Here

   */
  public int getIntvalue() {
      if (this.checked)
          return intvalue;
      else
          throw new OLATRuntimeException(IntegerElement.class,
                "You must call isInteger() in the form validate method prior to calling getIntvalue!", null);
  }
View Full Code Here

            }
          }
        }
      }
    } catch (IOException e) {
      throw new OLATRuntimeException("Error while copying files from jar::" + sourceFile.getAbsolutePath()
          + " - Delete all copied static resources in " + classPathStaticDir.getAbsolutePath() + "and restart tomcat", e);
    }
  }
View Full Code Here

  /**
   * @see org.olat.core.gui.formelements.FormElement#isDirty()
   */
  public boolean isDirty() {
    throw new OLATRuntimeException(StaticMultipleSelectionElement.class, "isDirty not implemented for StaticMultipleSelectionElement", null);
  }
View Full Code Here

      this.cache = config.createCache(cacheName);
      try {
        cachemanager.addCache(this.cache);
      }
      catch (CacheException e) {
        throw new OLATRuntimeException("Problem when initializing the caches", e);
      }
    }
  }
View Full Code Here

    try {
      synchronized (cache) {//cluster_ok by definition of this class as used in single vm
        elem = cache.get(key);       
      }
    } catch (IllegalStateException e) {
      throw new OLATRuntimeException("cache state error for cache "+cache.getName(), e);
    } catch (CacheException e) {
      throw new OLATRuntimeException("cache error for cache "+cache.getName(), e);
    }
    return elem == null? null : elem.getValue();
  }
View Full Code Here

    for (int i = 0; i < sRowIds.length; i++) {
      String sRowId = sRowIds[i];
      try {
        rowIds.add(new Integer(sRowId));
      } catch (NumberFormatException nfe) {
        throw new OLATRuntimeException("Invalid rowID submitted as table multiselect parameter", nfe);
      }
    }
   
    int rows = getRowCount();
    int startRowId = 0;
View Full Code Here

TOP

Related Classes of org.olat.core.logging.OLATRuntimeException

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.