Importable

Trait Importable 

Source
pub trait Importable {
    const IMPORTER_PARAMETERS: &[ImporterParameter];
    const FILE_FORMAT_SPECIFICATION_LATEX: &str;

    // Required methods
    fn import_as_object(
        reader: &mut dyn BufRead,
        parameter_values: &ImporterParameterValues,
    ) -> Result<EbiObject>;
    fn import(
        reader: &mut dyn BufRead,
        parameter_values: &ImporterParameterValues,
    ) -> Result<Self>
       where Self: Sized;

    // Provided method
    fn default_importer_parameter_values() -> ImporterParameterValues { ... }
}

Required Associated Constants§

Source

const IMPORTER_PARAMETERS: &[ImporterParameter]

Defines the parameters that the importer expects.

Source

const FILE_FORMAT_SPECIFICATION_LATEX: &str

A latex piece that describes the file format.

Required Methods§

Source

fn import_as_object( reader: &mut dyn BufRead, parameter_values: &ImporterParameterValues, ) -> Result<EbiObject>

Source

fn import( reader: &mut dyn BufRead, parameter_values: &ImporterParameterValues, ) -> Result<Self>
where Self: Sized,

Attempts to import from the reader. The parameter_values must match the order given in IMPORTER_PARAMETERS.

Provided Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl Importable for CompressedEventLog

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = CompressedEventLogXes::FILE_FORMAT_SPECIFICATION_LATEX

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter] = EventLogXes::IMPORTER_PARAMETERS

Source§

impl Importable for CompressedEventLogTraceAttributes

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = CompressedEventLogXes::FILE_FORMAT_SPECIFICATION_LATEX

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter] = EventLogXes::IMPORTER_PARAMETERS

Source§

impl Importable for CompressedEventLogXes

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A compressed event log is a gzipped event log file in the IEEE XES format~\\cite{DBLP:journals/cim/AcamporaVSAGV17}. Parsing is performed by the Rust4PM crate~\\cite{DBLP:conf/bpm/KustersA24}."

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter] = EventLogXes::IMPORTER_PARAMETERS

Source§

impl Importable for DeterministicFiniteAutomaton

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A deterministic finite automaton is a JSON structure with the top level being an object. This object contains the following key-value pairs: \\begin{itemize} \\item \\texttt{initialState} being the index of the initial state. This field is optional: if omitted, the DFA has an empty language. \\item \\texttt{finalStates} being a list of indices of the final states. A final state is not necessarily a deadlock state. \\item \\texttt{transitions} being a list of transitions. Each transition is an object with \\texttt{from} being the source state index of the transition, \\texttt{to} being the target state index of the transition, and \texttt{{label}} being the activity of the transition. Silent transitions are not supported. The file format supports deadlocks and livelocks. \\end{itemize} For instance: \\lstinputlisting[language=json, style=boxed]{../testfiles/aa-ab-ba.dfa}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for DirectlyFollowsGraph

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A directly follows graph is a JSON structure.\n \n For instance:\n \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba.dfg}\n \n The following table gives an overview of several directly follows-based file types and their features:\n \\begin{center}\n \\begin{tabularx}{\\linewidth}{Xlll}\n \\toprule\n File type & stochastic & multiple nodes with the same label & file syntax \\\\\n \\midrule\n \\hyperref[filehandler:directly follows graph]{directly follows graph (.dfg)} & yes & no & JSON \\\\\n \\hyperref[filehandler:directly follows model]{directly follows model (.dfm)} & no & yes & line-based \\\\\n \\hyperref[filehandler:stochastic directly follows model]{stochastic directly follows model (.sdfm)} & yes & yes & line-based \\\\\n \\bottomrule\n \\end{tabularx}\n \\end{center}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for DirectlyFollowsModel

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A directly follows model is a line-based structure. Lines starting with a \\# are ignored.\n This first line is exactly `directly follows model\'.\\\n The second line is a boolean indicating whether the model supports empty traces.\\\n The third line is the number of activities in the model.\\\n The following lines each contain an activity. Duplicated labels are accepted.\\\n The next line contains the number of start activities, followed by, for each start activity, a line with the index of the start activity.\\\n The next line contains the number of end activities, followed by, for each end activity, a line with the index of the end activity.\\\n The next line contains the number of edges, followed by, for each edge, a line with first the index of the source activity, then the `>` symbol, then the index of the target activity.\n \n For instance:\n \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/a-b_star.dfm}\n \n The following table gives an overview of several directly follows-based file types and their features:\n \\begin{center}\n \\begin{tabularx}{\\linewidth}{Xlll}\n \\toprule\n File type & stochastic & multiple nodes with the same label & file syntax \\\\\n \\midrule\n \\hyperref[filehandler:directly follows graph]{directly follows graph (.dfg)} & yes & no & JSON \\\\\n \\hyperref[filehandler:directly follows model]{directly follows model (.dfm)} & no & yes & line-based \\\\\n \\hyperref[filehandler:stochastic directly follows model]{stochastic directly follows model (.sdfm)} & yes & yes & line-based \\\\\n \\bottomrule\n \\end{tabularx}\n \\end{center}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for EventLog

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = EventLogXes::FILE_FORMAT_SPECIFICATION_LATEX

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter] = EventLogXes::IMPORTER_PARAMETERS

Source§

impl Importable for EventLogCsv

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A text file, of which each row is a comma-separated list of attribute values. The first row contains the names of the attributes (unless the no-header flag is provided). You'll likely need to set some import parameters to make importing succeed. A restriction imposed by Ebi is that there must be at least two attributes and at least two events. For instance: \\lstinputlisting[style=boxed]{../testfiles/a-b.csv}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for EventLogPython

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A Pm4py log can be imported by Ebi from Python. Ensure to set \\texttt{{return\\_legacy\\_log\\_object=True}} at importing."

Source§

impl Importable for EventLogTraceAttributes

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = EventLogXes::FILE_FORMAT_SPECIFICATION_LATEX

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter] = EventLogXes::IMPORTER_PARAMETERS

Source§

impl Importable for EventLogXes

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "An event log file follows the IEEE XES format~\\cite{DBLP:journals/cim/AcamporaVSAGV17}. Parsing is performed by the Rust4PM crate~\\cite{DBLP:conf/bpm/KustersA24}. For instance: \\lstinputlisting[language=xml, style=boxed]{../testfiles/a-b.xes}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for Executions

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A JSON-formatted list of executions. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/a-b.exs}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for FiniteLanguage

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A finite language is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `finite language'. The second line is the number of traces in the language. For each trace, the first line contains the number of events in the trace. Then, each subsequent line contains the activity name of one event. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba.lang}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for FiniteStochasticLanguage

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A finite language is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `finite stochastic language'. The second line is the number of traces in the language. For each trace, the first line is the probability of the trace as a positive fraction or a decimal value. The second line contains the number of events in the trace. Then, each subsequent line contains the activity name of one event. The sum of the probabilities of the traces in the language needs to be $\\leq$ 1. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba.slang}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for LabelledPetriNet

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A labelled Petri net is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `labelled Petri net'. The second line is the number of places in the net. The lines thereafter contain the initial marking: each place has its own line with the number of tokens on that place in the initial marking. The next line is the number of transitions in the net. Then, for each transition, the following lines are next: (i) the word `silent' or the word `label' followed by a space and the name of the activity with which the transition is labelled; (ii) the number of input places, followed by a line for each input place with the index of the place; (iii) the number of output places, followed by a line for each output place with the index of the place. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba.lpn}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for LanguageOfAlignments

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A language of alignments is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `language of alignments'. The second line is the number of alignments in the language. For each alignment, the first line contains the number of moves in the alignment. Then, each move is given as either \\begin{itemize} \\item `synchronous move', followed by a line with the word `label' followed by a space and the activity label, which is followed with a line with the index of the involved transition. \\item `silent move', followed by a line with the index of the silent transition. \\item `log move', followed by a line with the word `label', then a space, and then the activity label. \\item `model move', followed by a line with the word `label' followed by a space and the activity label, which is followed with a line with the index of the involved ransition. \\end{itemize} Note that the Semantics trait of Ebi, which is what most alignment computations use, requires that every final marking is a deadlock. Consequently, an implicit silent transition may be added by the Semantics trait that is not in the model. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba.ali}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for LolaNet

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A LoLA Petri net language file adheres to the grammar described in~\\cite{DBLP:conf/apn/Wolf18a}. Note that Ebi does not support place bounds or fairness, and that LoLA nets do not support silent transitions, and has some restrictions on labeling. For instance: \\lstinputlisting[language=xml, style=boxed]{../testfiles/mutex.lola}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for PetriNetMarkupLanguage

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A Petri net markup language file follows the ISO 15909-2:2011 format~\\cite{pnml}. Parsing is performed by the Rust4PM crate~\\cite{DBLP:conf/bpm/KustersA24}. Please note that Ebi ignores any final markings. Instead, every deadlock is considered a final marking. For instance: \\lstinputlisting[language=xml, style=boxed]{../testfiles/a.pnml}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for ProcessTree

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A process tree is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `process tree'. The subsequent lines contain the nodes: Each node is either: \\begin{itemize} \\item A line with the word `activity' followed on the same line by a space and the label of the activity leaf; \\item The word `tau'; \\item The name of an operator (`sequence', `xor', `concurrent', `loop', `interleaved', or `or') on its own line. The line thereafter contains the number of children of the node, after which the nodes are given. An operator node must have at least one child. \\end{itemize} Indentation of nodes is allowed, but not mandatory. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/all_operators.ptree}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for ProcessTreeMarkupLanguage

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A process tree markup language file. For instance: \\lstinputlisting[language=xml, style=boxed]{../testfiles/aa-ab-ba.ptml}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for StochasticDeterministicFiniteAutomaton

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A stochastic deterministic finite automaton is a JSON structure with the top level being an object. This object contains the following key-value pairs: \\begin{itemize} \\item \\texttt{initialState} being the index of the initial state. This field is optional: if omitted, the SDFA has an empty stochastic language. \\item \\texttt{transitions} being a list of transitions. Each transition is an object with \\texttt{from} being the source state index of the transition, \\texttt{to} being the target state index of the transition, \\texttt{label} being the activity of the transition, and \\texttt{prob} being the probability of the transition (may be given as a fraction in a string or a float value. Must be $\\leq 1$). Silent transitions are not supported. The file format supports deadlocks and livelocks. The probability that a trace terminates in a state is 1 - the sum probability of the outgoing transitions of the state. \\end{itemize} For instance: \\lstinputlisting[language=json, style=boxed]{../testfiles/aa-ab-ba.sdfa}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for StochasticDirectlyFollowsModel

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A stochstic directly follows model is a line-based structure. Lines starting with a \\# are ignored.\n This first line is exactly `directly follows model\'.\\\n The second line is a boolean indicating whether the model supports empty traces.\\\n The third line is the number of activities in the model.\\\n The following lines each contain an activity. Duplicated labels are accepted.\\\n The next line contains the number of start activities, followed by, for each start activity, a line with the index of the start activity, followed by a `w` and the weight of the start activity.\\\n The next line contains the number of end activities, followed by, for each end activity, a line with the index of the end activity, followed by a `w` and the weight of the end activity.\\\n The next line contains the number of edges, followed by, for each edge, a line with first the index of the source activity, then the `>` symbol, then the index of the target activity, then a `w`, and then the weight of the transition.\n \n For instance:\n \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba.sdfm}\n \n The following table gives an overview of several directly follows-based file types and their features:\n \\begin{center}\n \\begin{tabularx}{\\linewidth}{Xlll}\n \\toprule\n File type & stochastic & multiple nodes with the same label & file syntax \\\\\n \\midrule\n \\hyperref[filehandler:directly follows graph]{directly follows graph (.dfg)} & yes & no & JSON \\\\\n \\hyperref[filehandler:directly follows model]{directly follows model (.dfm)} & no & yes & line-based \\\\\n \\hyperref[filehandler:stochastic directly follows model]{stochastic directly follows model (.sdfm)} & yes & yes & line-based \\\\\n \\bottomrule\n \\end{tabularx}\n \\end{center}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for StochasticLabelledPetriNet

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A stochastic labelled Petri net is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `stochastic labelled Petri net'. The second line is the number of places in the net. The lines thereafter contain the initial marking: each place has its own line with the number of tokens on that place in the initial marking. The next line is the number of transitions in the net. Then, for each transition, the following lines are next: (i) the word `silent' or the word `label' followed by a space and the name of the activity with which the transition is labelled; (ii) the weight of the transition, which may be any fraction or decimal number, even 0 or negative; (iii) the number of input places, followed by a line for each input place with the index of the place; (iiii) the number of output places, followed by a line for each output place with the index of the place. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba_ali.slpn}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for StochasticLanguageOfAlignments

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A stochastic language of alignments is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `stochastic language of alignments'. The second line is the number of alignments in the language. For each alignment, the first line contains the probability of the alignment in the language, which is either a positive fraction or a decimal value. The second line contains the number of moves in the alignment. Then, each move is given as either \\begin{itemize} \\item `synchronous move', followed by a line with the word `label' followed by a space and the activity label, which is followed with a line with the index of the involved transition. \\item `silent move', followed by a line with the index of the silent transition. \\item `log move', followed by a line with the word `label', then a space, and then the activity label. \\item `model move', followed by a line with the word `label' followed by a space and the activity label, which is followed with a line with the index of the involved ransition. \\end{itemize} For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/aa-ab-ba.sali}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]

Source§

impl Importable for StochasticProcessTree

Source§

const FILE_FORMAT_SPECIFICATION_LATEX: &str = "A stochastic process tree is a line-based structure. Lines starting with a \\# are ignored. This first line is exactly `stochastic process tree'. The subsequent lines contain the nodes: Each node is either: \\begin{itemize} \\item A line with the word `activity' followed on the same line by a space and the label of the activity leaf. The next line contains the weight of the activity; \\item The word `tau', followed on the next line by the weight of the leaf; \\item The name of an operator (`sequence', `xor', `concurrent', `loop', `interleaved', or `or') on its own line. The line thereafter contains the number of children of the node, after which the nodes are given. An operator node must have at least one child. \\end{itemize} Indentation of nodes is allowed, but not mandatory.\\ The last line of the file contains the weight of termination. For instance: \\lstinputlisting[language=ebilines, style=boxed]{../testfiles/all_operators.sptree}"

Source§

const IMPORTER_PARAMETERS: &[ImporterParameter]