|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectts.util.resource.AbstractResource
public abstract class AbstractResource
リソースクラスの抽象クラス。
リソースクラスに共通の実装を定義する。
| フィールドの概要 |
|---|
| インタフェース ts.util.resource.Resource から継承されたフィールド |
|---|
EMPTY |
| コンストラクタの概要 | |
|---|---|
AbstractResource()
デフォルトコンストラクタ。 |
|
AbstractResource(AbstractResource res)
コピーコンストラクタ。 |
|
| メソッドの概要 | |
|---|---|
java.lang.String |
attributeMatchMark()
キーの属性の名前と値を結び付ける文字を取得する。 |
java.lang.String[] |
attributeParenthesis()
キーの属性を囲む文字を取得する。 |
java.lang.String |
attributeSeparator()
キーの属性の区切り文字を取得する。 |
java.lang.String |
elementSeparator()
キーの要素の区切り文字を取得する。 |
char |
getAttributeMatchMark()
推奨されていません。 attributeMatchMark()を使用して下さい。 |
char[] |
getAttributeParenthesis()
推奨されていません。 attributeParenthesis()を使用して下さい。 |
char |
getAttributeSeparator()
推奨されていません。 attributeSeparator()を使用して下さい。 |
char |
getElementSeparator()
推奨されていません。 elementSeparator()を使用して下さい。 |
protected java.io.InputStream |
getInputStream(java.lang.String path)
指定されたパスから入力ストリームを取得する。 |
protected java.lang.String |
getNameOfKeyElement(java.lang.String keyElem)
指定されたキー要素の要素名を取得する。 |
protected java.io.OutputStream |
getOutputStream(java.lang.String path)
指定されたパスの出力ストリームを取得する。 |
java.lang.String |
getPath()
ロードしたリソースファイルのパスを取得する。 |
protected java.util.List<java.lang.String[]> |
listAttributesOfKeyElement(java.lang.String keyElem)
指定されたキー要素の属性の名前と値の組を列挙する。 |
protected abstract void |
load(java.io.InputStream stream)
引数の入力ストリームからリソースファイルの内容を読み込む。 |
void |
load(java.lang.String path)
指定されたパスのリソースファイルを読み込む。 |
protected abstract void |
save(java.io.OutputStream stream)
引数の出力ストリームに、このオブジェクトが保持している内容を保存する。 |
void |
save(java.lang.String path)
指定されたパスのファイルに、このオブジェクトが保持している内容を保存する。 |
protected void |
setAttributeMatchMark(char mark)
推奨されていません。 setAttributeMatchMark(String)を使用して下さい。 |
protected void |
setAttributeMatchMark(java.lang.String mark)
キーの属性の名前と値を結び付ける文字を設定する。 |
protected void |
setAttributeParenthesis(char openPar,
char closePar)
推奨されていません。 setAttributeParenthesis(String,String)を使用して下さい。 |
protected void |
setAttributeParenthesis(java.lang.String openPar,
java.lang.String closePar)
キーの属性を囲む文字を設定する。 |
protected void |
setAttributeSeparator(char separator)
推奨されていません。 setAttributeSeparator(char)を使用して下さい。 |
protected void |
setAttributeSeparator(java.lang.String separator)
キーの属性の区切り文字を設定する。 |
protected void |
setElementSeparator(char separator)
推奨されていません。 setElementSeparator(String)を使用して下さい。 |
protected void |
setElementSeparator(java.lang.String separator)
キーの要素の区切り文字を設定する。 |
protected java.util.List<java.lang.String> |
splitKey(java.lang.String key)
キーを要素ごとに分割する。 |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| インタフェース ts.util.resource.Resource から継承されたメソッド |
|---|
getAttributes, getBaseElementName, getChildren, getFirstAttribute, getFirstChild, getFirstValue, getOrCreateFirstChild, getValues, removeChildren, setFirstValue |
| コンストラクタの詳細 |
|---|
public AbstractResource()
public AbstractResource(AbstractResource res)
res - コピー元のリソースオブジェクト。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。| メソッドの詳細 |
|---|
@Deprecated protected void setElementSeparator(char separator)
setElementSeparator(String)を使用して下さい。
separator - キーの要素の区切り文字。protected void setElementSeparator(java.lang.String separator)
separator - キーの要素の区切り文字。
java.lang.IllegalArgumentException - 引数の文字列が1文字でない場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグ・モードのみ)@Deprecated public char getElementSeparator()
elementSeparator()を使用して下さい。
public java.lang.String elementSeparator()
@Deprecated
protected void setAttributeParenthesis(char openPar,
char closePar)
setAttributeParenthesis(String,String)を使用して下さい。
openPar - キーの属性を囲む開き括弧。closePar - キーの属性を囲む閉じ括弧。
protected void setAttributeParenthesis(java.lang.String openPar,
java.lang.String closePar)
openPar - キーの属性を囲む開き括弧。closePar - キーの属性を囲む閉じ括弧。
java.lang.IllegalArgumentException - 引数の文字列が1文字でない場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグ・モードのみ)@Deprecated public char[] getAttributeParenthesis()
attributeParenthesis()を使用して下さい。
public java.lang.String[] attributeParenthesis()
@Deprecated protected void setAttributeSeparator(char separator)
setAttributeSeparator(char)を使用して下さい。
separator - キーの属性の区切り文字。protected void setAttributeSeparator(java.lang.String separator)
separator - キーの属性の区切り文字。
java.lang.IllegalArgumentException - 引数の文字列が1文字でない場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグ・モードのみ)@Deprecated public char getAttributeSeparator()
attributeSeparator()を使用して下さい。
public java.lang.String attributeSeparator()
@Deprecated protected void setAttributeMatchMark(char mark)
setAttributeMatchMark(String)を使用して下さい。
mark - キーの属性の名前と値を結び付ける文字。protected void setAttributeMatchMark(java.lang.String mark)
mark - キーの属性の名前と値を結び付ける文字。
java.lang.IllegalArgumentException - 引数の文字列が1文字でない場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグ・モードのみ)@Deprecated public char getAttributeMatchMark()
attributeMatchMark()を使用して下さい。
public java.lang.String attributeMatchMark()
protected java.lang.String getNameOfKeyElement(java.lang.String keyElem)
splitKeyメソッドによって分割されたキー要素から
要素名を取り出す。
keyElem - キー要素。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。protected java.util.List<java.lang.String[]> listAttributesOfKeyElement(java.lang.String keyElem)
splitKeyメソッドによって分割されたキー要素から
属性を取り出し、属性の名前と値の配列を列挙オブジェクトに格納して返す。
keyElem - キー要素。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。
protected java.util.List<java.lang.String> splitKey(java.lang.String key)
throws IllegalKeyException
key - キー。
IllegalKeyException - キーが不正な場合。public java.lang.String getPath()
public void load(java.lang.String path)
throws java.io.FileNotFoundException,
java.io.IOException
path - リソースファイルのパス。
java.io.FileNotFoundException - 指定されたパスのファイルが見つからなかった
場合。
java.io.IOException - ファイルの読み込み中に例外が発生した場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。
protected java.io.InputStream getInputStream(java.lang.String path)
throws java.io.FileNotFoundException,
java.io.IOException
path - リソースファイルのパス。
java.io.FileNotFoundException - 指定されたパスのファイルが見つからなかった
場合。
java.io.IOException - 入力ストリームのオープン時に例外が発生した場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。
protected abstract void load(java.io.InputStream stream)
throws java.io.IOException
stream - 入力ストリーム。
java.io.IOException - 読み込み中に例外が発生した場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。
public void save(java.lang.String path)
throws java.io.IOException
path - 保存先のファイルのパス。
java.io.IOException - ファイルの保存中に例外が発生した場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。
protected java.io.OutputStream getOutputStream(java.lang.String path)
throws java.io.IOException
path - 保存先のファイルのパス。
java.io.IOException - 指定されたパスのオープン時に例外が発生した場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。
protected abstract void save(java.io.OutputStream stream)
throws java.io.IOException
stream - 保存先の出力ストリーム。
java.io.IOException - ファイルの保存中に例外が発生した場合。
java.lang.AssertionError - 引数がヌルの場合(デバッグモードのみ)。
|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||