001 package org.qedeq.kernel.bo.module;
002
003 import org.qedeq.kernel.bo.common.Element2Latex;
004 import org.qedeq.kernel.bo.common.Element2Utf8;
005 import org.qedeq.kernel.bo.common.QedeqBo;
006 import org.qedeq.kernel.se.common.LogicalModuleState;
007 import org.qedeq.kernel.se.common.ModuleDataException;
008 import org.qedeq.kernel.se.common.Plugin;
009 import org.qedeq.kernel.se.common.SourceFileException;
010 import org.qedeq.kernel.se.common.SourceFileExceptionList;
011
012 /**
013 * Kernel internal QedeqBo with additional methods.
014 *
015 * @author Michael Meyling
016 */
017 public interface KernelQedeqBo extends QedeqBo {
018
019 /**
020 * Get internal kernel services.
021 *
022 * @return Internal kernel services.
023 */
024 public InternalKernelServices getKernelServices();
025
026 /**
027 * Get labels and URLs of all referenced modules.
028 *
029 * @return URLs of all referenced modules.
030 */
031 public KernelModuleReferenceList getKernelRequiredModules();
032
033 /**
034 * Get label references for QEDEQ module.
035 *
036 * @return Label references.
037 */
038 public ModuleLabels getLabels();
039
040 /**
041 * Return mapper for transforming elements into LaTeX.
042 *
043 * @return Transformer to get LaTeX out of elements.
044 */
045 public Element2Latex getElement2Latex();
046
047 /**
048 * Return mapper for transforming elements into UTF-8 text.
049 *
050 * @return Transformer to get UTF-8 text out of elements.
051 */
052 public Element2Utf8 getElement2Utf8();
053
054 /**
055 * Create exception out of {@link ModuleDataException}.
056 *
057 * @param plugin This plugin generated the error.
058 * @param exception Take this exception.
059 * @return Newly created instance.
060 */
061 public SourceFileException createSourceFileException(Plugin plugin, ModuleDataException
062 exception);
063
064 /**
065 * Add errors and warnings for plugin.
066 *
067 * @param plugin Add errors for this plugin.
068 * @param errors These errors occurred.
069 * @param warnings These warnings occurred.
070 */
071 public void addPluginErrorsAndWarnings(Plugin plugin, SourceFileExceptionList errors,
072 SourceFileExceptionList warnings);
073
074
075 /**
076 * Remove all errors and warnings for all plugins.
077 */
078 public void clearAllPluginErrorsAndWarnings();
079
080 /**
081 * Get the predicate and function existence checker. Is only not <code>null</code>
082 * if logic was successfully checked.
083 *
084 * @return Checker. Checks if a predicate or function constant is defined.
085 */
086 public ModuleConstantsExistenceChecker getExistenceChecker();
087
088 /**
089 * Set failure module state.
090 *
091 * @param stateExternalCheckingFailed Module state.
092 * @param sfl Exception that occurred during loading.
093 * @throws IllegalArgumentException <code>state</code> is no failure state
094 */
095 public void setLogicalFailureState(LogicalModuleState stateExternalCheckingFailed,
096 final SourceFileExceptionList sfl);
097
098 /**
099 * Set loading progress module state. Must not be <code>null</code>.
100 *
101 * @param stateInternalChecking module state
102 */
103 public void setLogicalProgressState(LogicalModuleState stateInternalChecking);
104
105 /**
106 * Set {@link ModuleConstantsExistenceCheckerImpl}. Doesn't do any status handling.
107 *
108 * @param existence Set this checker.
109 */
110 public void setExistenceChecker(ModuleConstantsExistenceChecker existence);
111
112 /**
113 * Set logic checked state. Also set the predicate and function existence checker.
114 *
115 * @param checker Checks if a predicate or function constant is defined.
116 */
117 public void setChecked(final ModuleConstantsExistenceChecker checker);
118
119
120 }
|