|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.infoteria.asteria.flowengine2.compile.AbstractCompiler | +--com.infoteria.asteria.flowengine2.compile.CompilerBase | +--com.infoteria.asteria.flowengine2.flow.ComponentCompiler
標準のコンポーネントコンパイラです。
自作のコンパイラを作成する場合はこのクラスを継承して作成します。
Field Summary | |
protected Component |
_component
コンパイル中のコンポーネント。 |
Fields inherited from class com.infoteria.asteria.flowengine2.compile.CompilerBase |
_A_ACCESS, _A_BREAKPOINT, _A_CATEGORY, _A_CONNECTOR, _A_DEFAULT, _A_ENABLED, _A_EXPAND, _A_FILENAME, _A_FILEPATH, _A_FORMAT, _A_FRACTION_LENGTH, _A_ID, _A_LENGTH, _A_MACRO, _A_NAME, _A_NODETYPE, _A_PARTS, _A_PREFIX, _A_PRIORITY, _A_REPEAT, _A_REPEAT_AREA, _A_START_POSITION, _A_STATE, _A_STREAM, _A_TYPE, _A_URI, _A_VERSION, _E_COMPONENT, _E_EXTERNAL, _E_FIELD, _E_FLOW, _E_INPUT, _E_ITEM, _E_LINK, _E_LOG, _E_NAMESPACE, _E_OUTPUT, _E_PROJECT, _E_PROPERTY, _E_ROW, _E_VARIABLE, _E_VARIABLES, _E_WEBSERVICE, _V_ALLOW_INVOKE, _V_CACHE_TYPE, _V_DEBUG_LOG, _V_DEFAULT, _V_EXCEPTION, _V_FIELDS, _V_LOGLEVEL, _V_LOGNAME, _V_OUTPUT_DEFAULT, _V_PRIVATE, _V_PROJECT, _V_PUBLIC, _V_SESSION, _V_SESSION_VARIABLES, _V_SYSTEM_VARIABLES, _V_TIMEOUT, _V_VARIABLES |
Fields inherited from class com.infoteria.asteria.flowengine2.compile.AbstractCompiler |
log, WARN_0, WARN_1 |
Constructor Summary | |
ComponentCompiler(Component component)
コンパイル対象のコンポーネントを引数にComponentCompilerを作成します。 |
Method Summary | |
Logger |
getLogger()
Loggerを返します。 |
protected org.w3c.dom.Element |
getPropertyElement(org.w3c.dom.Element el,
java.lang.String name)
引数の要素直下の「fe:Property[@name="xxxx"]」要素を返します。 preCompileメソッド内でPropertyの定義要素を取得するために使用します。 |
protected java.lang.String |
getPropertyValue(org.w3c.dom.Element el,
java.lang.String name)
引数の要素直下の「fe:Property[@name="xxxx"]」要素の設定値を返します。 preCompileメソッド内でProperty値を取得するために使用します。 |
protected void |
onComponentError(ErrorInfo info)
ユーザが作成したサブクラスで使用するエラー通知メソッドです。 |
protected void |
onComponentError(int code)
ユーザが作成したサブクラスで使用するエラー通知メソッドです。 エラーメッセージをxscファイルから取得することができます。 |
protected void |
onComponentError(int code,
java.lang.Object o1)
ユーザが作成したサブクラスで使用するエラー通知メソッドです。 エラーメッセージをxscファイルから取得することができます。 |
protected void |
onComponentError(int code,
java.lang.Object o1,
java.lang.Object o2)
ユーザが作成したサブクラスで使用するエラー通知メソッドです。 エラーメッセージをxscファイルから取得することができます。 |
protected void |
onComponentError(int code,
java.lang.Object o1,
java.lang.Object o2,
java.lang.Object o3)
ユーザが作成したサブクラスで使用するエラー通知メソッドです。 エラーメッセージをxscファイルから取得することができます。 |
protected void |
onComponentError(java.lang.String msg)
ユーザが作成したサブクラスで使用するエラー通知メソッドです。 |
protected void |
onComponentWarning(ErrorInfo info,
int level)
ユーザが作成したサブクラスで使用する警告通知メソッドです。 |
protected void |
onComponentWarning(int code,
int level)
ユーザが作成したサブクラスで使用する警告通知メソッドです。 警告メッセージをxscファイルから取得することができます。 |
protected void |
onComponentWarning(int code,
int level,
java.lang.Object o1)
ユーザが作成したサブクラスで使用する警告通知メソッドです。 警告メッセージをxscファイルから取得することができます。 |
protected void |
onComponentWarning(int code,
int level,
java.lang.Object o1,
java.lang.Object o2)
ユーザが作成したサブクラスで使用する警告通知メソッドです。 警告メッセージをxscファイルから取得することができます。 |
protected void |
onComponentWarning(int code,
int level,
java.lang.Object o1,
java.lang.Object o2,
java.lang.Object o3)
ユーザが作成したサブクラスで使用する警告通知メソッドです。 警告メッセージをxscファイルから取得することができます。 |
protected void |
onComponentWarning(java.lang.String msg,
int level)
ユーザが作成したサブクラスで使用する警告通知メソッドです。 |
protected void |
postCompile()
このメソッドはコンポーネントのMapを引数とするpostCompile(Map)メソッドに置き換えられました。 今後postCompileメソッドをオーバーライドする場合はMapを引数とするメソッドを使用してください。 |
protected void |
postCompile(java.util.Map componentMap)
プロジェクトファイル中に定義されているすべてのPropertyが設定された後に呼び出されます。 このメソッドをオーバーライドすることによりプロパティの整合性のチェックなどを行うことができます。 |
void |
preCompile(org.w3c.dom.Element el)
フローのコンパイル時にComponentのインスタンスが作成された直後に呼び出されます。 このメソッドの実行時にはコンポーネントのコンパイルはまだ行われていないのでプロパティなどは設定されていません。 通常コンパイラを拡張する場合はpostCompileメソッドをオーバーライドしてそちらで行いますが、動的にコネクタを追加する 場合などリンク処理よりも先に処理を行う必要がある場合はこちらのメソッドを使用します。 引数のElementはxfp2ファイルのComponent要素ですので、処理に必要な情報を取得するためには自分でNodeをトラバースする 必要があります。 |
protected boolean |
processOtherProperty(Property property,
org.w3c.dom.Element el)
独自のPropertyTypeを定義した場合にオーバーライドします。 自作PropertyのProperty#getTypeメソッドが独自のPropertyTypeを返すように作成した場合、 このメソッドをオーバーライドすることによりProperty要素の内容を自由にコンパイルすることができます。 |
Methods inherited from class com.infoteria.asteria.flowengine2.compile.CompilerBase |
createErrorInfo, fireOnError, fireOnWarning, getComponentName, getFlowName, getProjectName, isFlowNode, isIgnoreNode |
Methods inherited from class com.infoteria.asteria.flowengine2.compile.AbstractCompiler |
getErrorCount, getWarningCount, logElement, onError, onError, onError, onError, onError, onError, onWarning, onWarning, onWarning, onWarning, onWarning, onWarning, setLogger |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected Component _component
Constructor Detail |
public ComponentCompiler(Component component)
Method Detail |
public Logger getLogger()
getLogger
in class AbstractCompiler
protected boolean processOtherProperty(Property property, org.w3c.dom.Element el)
public void preCompile(org.w3c.dom.Element el)
protected void postCompile(java.util.Map componentMap)
componentMap
- ownerFlowに含まれるコンポーネント名とコンポーネントインスタンスのMapprotected void postCompile()
protected void onComponentError(int code)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentError(int code, java.lang.Object o1)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentError(int code, java.lang.Object o1, java.lang.Object o2)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentError(int code, java.lang.Object o1, java.lang.Object o2, java.lang.Object o3)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentError(ErrorInfo info)
protected void onComponentError(java.lang.String msg)
protected void onComponentWarning(int code, int level)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentWarning(int code, int level, java.lang.Object o1)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentWarning(int code, int level, java.lang.Object o1, java.lang.Object o2)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentWarning(int code, int level, java.lang.Object o1, java.lang.Object o2, java.lang.Object o3)
code
- xscファイルで定義したMessage要素のkeyを指定します。protected void onComponentWarning(ErrorInfo info, int level)
protected void onComponentWarning(java.lang.String msg, int level)
protected org.w3c.dom.Element getPropertyElement(org.w3c.dom.Element el, java.lang.String name)
el
- 通常はfe:Component要素name
- 取得するPropertyの名前protected java.lang.String getPropertyValue(org.w3c.dom.Element el, java.lang.String name)
el
- 通常はfe:Component要素name
- 取得するPropertyの名前
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |