本文整理汇总了Java中org.semanticweb.owlapi.model.OWLException.printStackTrace方法的典型用法代码示例。如果您正苦于以下问题:Java OWLException.printStackTrace方法的具体用法?Java OWLException.printStackTrace怎么用?Java OWLException.printStackTrace使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.semanticweb.owlapi.model.OWLException
的用法示例。
在下文中一共展示了OWLException.printStackTrace方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: run
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
@Override
public void run() {
this.finished = false;
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
try {
xevents = ebdaR.retrieveXEvents16(attributes);
} catch (OWLException e) {
e.printStackTrace();
}
this.finished = true;
synchronized(lock){
lock.notifyAll();
}
}
示例2: run
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
@Override
public void run() {
this.finished = false;
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
try {
xtraces = retrieveXTraces17();
} catch (OWLException e) {
e.printStackTrace();
}
this.finished = true;
synchronized(caller){
caller.notify();
}
}
示例3: getXESLog17
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / sant[email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog getXESLog17(EBDAModelWithOptimizedXAttributesEncoding ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImplWithParallelProcessing ebdaR = new EBDAReasonerImplWithParallelProcessing(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//Create XLogOnProm
XLogOnProm xlog = ebdaR.extractXLog();
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例4: extractOnPromXESLogUsingParallelAndOptimizedXAttributesProcessing
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* <br /><br />
* Feature(s)/Note(s):
* <ul>
* <li>It encodes/extracts the XAttributes information (i.e., key, type, values) in/from the Attributes URI</li>
* <li>It must use EBDAModelWithOptimizedXAttributesEncoding</li>
* <li>It runs some tasks in parallel</li>
* </ul>
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog extractOnPromXESLogUsingParallelAndOptimizedXAttributesProcessing(EBDAModelWithOptimizedXAttributesEncoding ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImplWithParallelProcessing ebdaR = new EBDAReasonerImplWithParallelProcessing(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//Create XLogOnProm
XLogOnProm xlog = ebdaR.extractXLog();
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例5: extractXESLog16
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog extractXESLog16(EBDAModelWithOptimizedXAttributesEncoding ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
Hashtable<String,XAttribute> attributes = new Hashtable<String,XAttribute>();
HashMap<String, XTrace> xtraces = null;
try{
Object lock = new Object();
EBDAReasonerImplExperiment ebdaR1 = new EBDAReasonerImplExperiment(ebdaModel);
ebdaR1.setExecutionLogListener(this);
EventExtractor16 eventExtractor = new EventExtractor16(attributes, ebdaR1, lock);
eventExtractor.start();
EBDAReasonerImplExperiment ebdaR2 = new EBDAReasonerImplExperiment(ebdaModel);
ebdaR2.setExecutionLogListener(this);
TraceExtractor16 traceExtractor = new TraceExtractor16(attributes, ebdaR2, lock);
traceExtractor.start();
//Create XLogOnProm
XLogOnProm xlog = xfact.createXLogOnProm(true);
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//combine extracted traces and events
EBDAReasonerImplExperiment ebdaR3 = new EBDAReasonerImplExperiment(ebdaModel);
ebdaR3.setExecutionLogListener(this);
xtraces = ebdaR3.combineTracesEventsExtractor(eventExtractor, traceExtractor, lock);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Add traces to the log
xlog.addAll(xtraces.values());
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例6: extractXESLogSimplImpl
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
*/
public XLog extractXESLogSimplImpl(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try {
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttribute> xatts = ebdaR.getXAttributesSimpleImpl();
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEvent> xevents = ebdaR.getXEventsSimpleImpl(xatts);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesSimpleImpl(xevents, xatts);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm();
//Add traces to the log
xlog.addAll(xtraces.values());
//Add default Trace/Event Global Attribute information and also classifier
xlog = addDefaultGlobalAttributesAndClassifiers(xlog);
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例7: extractXESLog
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @deprecated this one is only maintained for backward compatibility with the other OnProm plug in, at some point it should be removed
*/
public static XLog extractXESLog(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
try {
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttribute> xatts = ebdaR.getXAttributesSimpleImpl();
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEvent> xevents = ebdaR.getXEventsSimpleImpl(xatts);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesSimpleImpl(xevents, xatts);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm();
//Add traces to the log
xlog.addAll(xtraces.values());
XESLogExtractorExperimental xle = new XESLogExtractorExperimental();
//Add default Trace/Event Global Attribute information and also classifier
xlog = xle.addDefaultGlobalAttributesAndClassifiers(xlog);
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例8: getXESLog5
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog getXESLog5(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttribute> xatts = ebdaR.getXAttributes();
if(xatts == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_ATTRIBUTES_RETRIEVAL_FAILURE);
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEvent> xevents = ebdaR.getXEventsWithEventMandatoryAttributesCheckInQuery(xatts);
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesWithEventMandatoryAttributesCheckInQuery(xevents, xatts);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm();
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
//Add default Trace/Event Global Attribute information and also classifier
xlog = addDefaultGlobalAttributesAndClassifiers(xlog);
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例9: getXESLog6
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog getXESLog6(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttribute> xatts = ebdaR.getXAttributes();
if(xatts == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_ATTRIBUTES_RETRIEVAL_FAILURE);
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEvent> xevents = ebdaR.getXEventsUsingAtomicQuery(xatts);
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesUsingAtomicQueries(xevents, xatts);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm();
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
//Add default Trace/Event Global Attribute information and also classifier
xlog = addDefaultGlobalAttributesAndClassifiers(xlog);
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例10: getXESLog10
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
*/
public XLog getXESLog10(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEvent> xevents = ebdaR.getXEventsUsingMediumSizeQuery();
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesUsingMediumSizeQueries(xevents);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm();
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
//Add default Trace/Event Global Attribute information and also classifier
xlog = addDefaultGlobalAttributesAndClassifiers(xlog);
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例11: getXESLog12
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog getXESLog12(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttributeOnProm> xatts = ebdaR.getXAttributesWithSplitQuery();
if(xatts == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_ATTRIBUTES_RETRIEVAL_FAILURE);
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEventOnProm> xevents = ebdaR.getXEventsOnPromUsingAtomicQuery(xatts);
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesUsingAtomicQueriesAndWithEventMandatoryAttributesCheck(xevents, xatts);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm();
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
//Add default Trace/Event Global Attribute information and also classifier
xlog = addDefaultGlobalAttributesAndClassifiers(xlog);
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例12: getXESLog15
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog getXESLog15(EBDAModelWithOptimizedXAttributesEncoding ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImplWithXAttributesOptimization ebdaR = new EBDAReasonerImplWithXAttributesOptimization(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
HashMap<String,XAttribute> attributes = new HashMap<String,XAttribute>();
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEventOnProm> xevents = ebdaR.getXEventsAndXAttributes(attributes);
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesAndXAttributes(attributes);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//combine extracted traces and events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Combining XES traces and events"));
xtraces = ebdaR.mergeXTracesXEvents(xtraces, xevents);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm();
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
//Add default Trace/Event Global Attribute information and also classifier
xlog = addDefaultGlobalAttributesAndClassifiers(xlog);
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例13: extractXESLogNoMandatoryAttributesCheck
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* <br /><br />
* Feature(s)/Note(s):
* <ul>
* <li>The query for retrieving XAttributes information is large</li>
* <li>It can use either EBDAModelNaiveImpl, EBDAModelImpl2 or EBDAModelImpl3</li>
* <li>No OnProm Event Mandatory Attributes check</li>
* </ul>
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog extractXESLogNoMandatoryAttributesCheck(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttribute> xatts = ebdaR.getXAttributes();
if(xatts == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_ATTRIBUTES_RETRIEVAL_FAILURE);
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEvent> xevents = ebdaR.getXEventsUsingAtomicQuery(xatts);
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesUsingAtomicQueries(xevents, xatts);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm(true);
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例14: extractOnPromXESLog
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* <br /><br />
* Feature(s)/Note(s):
* <ul>
* <li>The query for retrieving XAttributes information is large</li>
* <li>It can use either EBDAModelNaiveImpl, EBDAModelImpl2 or EBDAModelImpl3</li>
* <li>There are OnProm Event Mandatory Attributes check (in the program)</li>
* </ul>
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog extractOnPromXESLog(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttribute> xatts = ebdaR.getXAttributes();
if(xatts == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_ATTRIBUTES_RETRIEVAL_FAILURE);
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEventOnProm> xevents = ebdaR.getXEventsOnPromUsingAtomicQuery2(xatts);
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesUsingAtomicQueriesAndWithEventMandatoryAttributesCheck2(xevents, xatts);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm(true);
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}
示例15: extractXESLogWithMandatoryAttributesCheckUsingQueries
import org.semanticweb.owlapi.model.OWLException; //导入方法依赖的package包/类
/**
*
* Generates XES log based on the given particular OBDA model that connects a
* Database to the Event Ontology (i.e., EBDA).
*
* <br /><br />
* Feature(s)/Note(s):
* <ul>
* <li>It still divides the main processes into three parts, namely XAttributes extraction, XEvents extraction, and XTraces extraction</li>
* <li>It checks the Event Mandatory Attributes using Queries
* <ul>
* <li>i.e., it only retrieves events that have mandatory attributes and </li>
* <li>only put those kind of events in the trace</li>
* </ul>
* </li>
* <li>So far it is only implemented using EBDAModelNaiveImpl (However, it might be possible to use another EBDAModel)</li>
* </ul>
*
* @author Ario Santoso ([email protected] / [email protected])
* @param ebdaModel - an Event OBDA model (i.e., a particular OBDA model) that
* connects a Database to the Event Ontology
* @return event log - XLog
* @throws OWLException
*/
public XLog extractXESLogWithMandatoryAttributesCheckUsingQueries(EBDAModel ebdaModel) throws XESLogExtractionFailureException{
logger.info(String.format(
LEConstants.LOG_INFO_TEMPLATE, "Start extracting XES Log from the EBDA Model"));
EBDAReasonerImpl ebdaR = new EBDAReasonerImpl(ebdaModel);
ebdaR.setExecutionLogListener(this);
try{
//extract all attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES attributes information"));
HashMap<String,XAttribute> xatts = ebdaR.getXAttributes();
if(xatts == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_ATTRIBUTES_RETRIEVAL_FAILURE);
//extract all events and associate each event with their attributes
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES events information"));
HashMap<String, XEvent> xevents = ebdaR.getXEventsWithEventMandatoryAttributesCheckInQuery(xatts);
if(xevents == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_EVENTS_RETRIEVAL_FAILURE);
//extract all traces and associate each trace with their events
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Retrieving XES traces information"));
HashMap<String, XTrace> xtraces = ebdaR.getXTracesWithEventMandatoryAttributesCheckInQuery(xevents, xatts);
if(xtraces == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_TRACES_RETRIEVAL_FAILURE);
//add the traces into the log
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Constructing XES log"));
//Create XLogOnProm
XLogOnProm xlog = XFactoryOnProm.getInstance().createXLogOnProm(true);
if(xlog == null)
throw new XESLogExtractionFailureException(LEConstants.MSG_LOG_CREATION_FAILURE);
//Add traces to the log
xlog.addAll(xtraces.values());
logger.info(String.format(LEConstants.LOG_INFO_TEMPLATE, "Finish extracting XES Log from the EBDA Model"));
//return the log
return xlog;
} catch (OWLException e) {
e.printStackTrace();
throw new XESLogExtractionFailureException();
}
}