OSDN Git Service

62980cd9ea7e9e1a76ba7effd26199b2cea8a3dc
[jindolf/JinParser.git] / src / main / java / jp / sourceforge / jindolf / parser / package-info.java
1 /*
2  * JinParser パッケージコメント
3  *
4  * このファイルは、SunJDK5.0以降に含まれるJavadoc用に用意された、
5  * 特別な名前を持つソースファイルです。
6  * このファイルはソースコードを含まず、
7  * パッケージコメントとパッケージ宣言のみが含まれます。
8  *
9  * License : The MIT License
10  * Copyright(c) 2009 olyutorskii
11  */
12
13 /**
14  * これは Jindolf プロジェクトにおける、
15  * XHTML文書のパース部分を構成するパッケージです。
16  *
17  * <p>
18  * JinParserライブラリは、CGIゲーム「人狼BBS」のクライアント制作者向けに
19  * 作られたJavaライブラリです。
20  * JinParserライブラリは、人狼BBSの専用クライアント開発プロジェクト
21  * 「Jindolf」から派生しました。
22  * </p>
23  *
24  * <hr>
25  *
26  * <p>
27  * 任意のバイトストリームから、
28  * デコードエラー情報付き文字列{@code DecodedContent}を得るには、
29  * 次のようにします。
30  * <pre>
31  * {@code
32  * InputStream is = .....
33  * StreamDecoder decoder = new SjisDecoder();
34  * ContentBuilder builder = new ContentBuilder();
35  * decoder.setDecodeHandler(builder);
36  * try{
37  *     decoder.decode(is);
38  * }catch(IOException e){
39  *     // ERROR!
40  * }catch(DecodeException e){
41  *     // ERROR!
42  * }
43  * DecodedContent content = builder.getContent();
44  * }
45  * </pre>
46  * </p>
47  *
48  * <p>
49  * このようにして得られた文字列をパースして、
50  * あなたの実装したハンドラ{@code YourHandler}に通知するには、
51  * 以下のようにします。
52  * <pre>
53  * {@code
54  * HtmlParser parser = new HtmlParser();
55  * HtmlHandler handler = new YourHandler();
56  * parser.setBasicHandler(handler);
57  * parser.setTalkHandler(handler);
58  * parser.setSysEventHandler(handler);
59  * try{
60  *     parser.parseAutomatic(content);
61  * }catch(HtmlParseException e){
62  *     // ERROR!
63  * }
64  * }
65  * </pre>
66  * </p>
67  *
68  * <p>
69  * ハンドラ内部で、パース元となった文字列の一部を切り出したい場合は、
70  * {@code EntityConverter}を使うのが便利です。
71  * </p>
72  *
73  * <hr>
74  *
75  * <p>
76  * The MIT License
77  * </p>
78  * <p>
79  * Copyright(c) 2009 olyutorskii
80  * </p>
81  * <p>
82  * Permission is hereby granted, free of charge, to any person obtaining a
83  * copy of this software and associated documentation files (the "Software"),
84  * to deal in the Software without restriction, including without limitation
85  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
86  * and/or sell copies of the Software, and to permit persons to whom the
87  * Software is furnished to do so, subject to the following conditions:
88  * </p>
89  * <p>
90  * The above copyright notice and this permission notice shall be included in
91  * all copies or substantial portions of the Software.
92  * </p>
93  * <p>
94  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
95  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
96  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
97  * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
98  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
99  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
100  * OTHER DEALINGS IN THE SOFTWARE.
101  * </p>
102  *
103  * <hr>
104  *
105  * @see <a href="http://jindolf.osdn.jp/">
106  * Jindolfポータルサイト</a>
107  * @see <a href="https://osdn.jp/projects/jindolf/devel/">
108  * Jindolf開発プロジェクト</a>
109  */
110
111 package jp.sourceforge.jindolf.parser;
112
113 /* EOF */