jp.hishidama.ant.types.htlex
クラス TextType

java.lang.Object
  上位を拡張 org.apache.tools.ant.ProjectComponent
      上位を拡張 org.apache.tools.ant.types.DataType
          上位を拡張 jp.hishidama.ant.types.htlex.TextType
すべての実装されたインタフェース:
Cloneable

public class TextType
extends org.apache.tools.ant.types.DataType

HtHtmlLexerテキストタイプ.

HTMLファイル内のテキストの条件判断・置換を行うデータタイプ。

導入されたバージョン:
2009.01.28
バージョン:
2009.02.17
作成者:
ひしだま

入れ子のクラスの概要
 class TextType.NestedString
           
static class TextType.TextEnum
          テキスト種類.
 
コンストラクタの概要
TextType()
           
 
メソッドの概要
 boolean convert(TextToken token, HtElement he)
          テキスト変換実行.
 TextType.NestedString createNewText()
          置換先文字列(要素)作成.
 TextType.NestedString createText()
          検索文字列(要素)作成.
 void setLines(boolean b)
          複数行指定.
 void setNewText(String s)
          置換先文字列設定.
 void setNewTextOperation(StringOpeEnum ope)
          テキスト置換方法設定.
 void setText(String s)
          検索文字列設定.
 void setTextMatch(MatchEnum match)
          テキストマッチ方法設定.
 void setTextType(TextType.TextEnum type)
          テキスト種類設定.
 void validate(HtLexerConverter conv)
          精査実行.
 
クラス org.apache.tools.ant.types.DataType から継承されたメソッド
clone, getRefid, invokeCircularReferenceCheck, isReference, setRefid, toString
 
クラス org.apache.tools.ant.ProjectComponent から継承されたメソッド
getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProject
 
クラス java.lang.Object から継承されたメソッド
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

コンストラクタの詳細

TextType

public TextType()
メソッドの詳細

setText

public void setText(String s)
検索文字列設定.

パラメータ:
s - 文字列

createText

public TextType.NestedString createText()
検索文字列(要素)作成.

戻り値:
token要素

setNewText

public void setNewText(String s)
置換先文字列設定.

パラメータ:
s - 文字列

createNewText

public TextType.NestedString createNewText()
置換先文字列(要素)作成.

戻り値:
replacevalue要素

setTextMatch

public void setTextMatch(MatchEnum match)
テキストマッチ方法設定.

パラメータ:
match - マッチング方法

setNewTextOperation

public void setNewTextOperation(StringOpeEnum ope)
テキスト置換方法設定.

パラメータ:
ope - 置換方法

setTextType

public void setTextType(TextType.TextEnum type)
テキスト種類設定.

パラメータ:
type - テキスト種類

setLines

public void setLines(boolean b)
複数行指定.

パラメータ:
b - trueの場合、改行を含んだ複数行を一つの文字列として検索・置換する。
falseの場合、行ごとに検索・置換する。

validate

public void validate(HtLexerConverter conv)
              throws org.apache.tools.ant.BuildException
精査実行.

パラメータ:
conv - コンバーター
例外:
org.apache.tools.ant.BuildException - 精査エラー時

convert

public boolean convert(TextToken token,
                       HtElement he)
テキスト変換実行.

パラメータ:
token - テキスト
he - テキストの属している要素(解析されていない場合、null)
戻り値:
内容を変更した場合、true