All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.snapscript.core.error.ErrorCauseExtractor Maven / Gradle / Ivy

package org.snapscript.core.error;

import org.snapscript.core.scope.Scope;

public class ErrorCauseExtractor {

   public ErrorCauseExtractor() {
      super();
   }
   
   public Object extract(Scope scope, Object cause) {
      if(InternalError.class.isInstance(cause)) {
         InternalError error = (InternalError)cause;
         return error.getValue();
      }
      return cause;
   }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy