Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
ConversionFailure |
|
| 1.0;1 |
1 | /* | |
2 | * Copyright 2004-2010 the Seasar Foundation and the Others. | |
3 | * | |
4 | * Licensed under the Apache License, Version 2.0 (the "License"); | |
5 | * you may not use this file except in compliance with the License. | |
6 | * You may obtain a copy of the License at | |
7 | * | |
8 | * http://www.apache.org/licenses/LICENSE-2.0 | |
9 | * | |
10 | * Unless required by applicable law or agreed to in writing, software | |
11 | * distributed under the License is distributed on an "AS IS" BASIS, | |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, | |
13 | * either express or implied. See the License for the specific language | |
14 | * governing permissions and limitations under the License. | |
15 | */ | |
16 | ||
17 | package org.seasar.cubby.internal.controller; | |
18 | ||
19 | import org.seasar.cubby.action.FieldInfo; | |
20 | import org.seasar.cubby.action.MessageInfo; | |
21 | ||
22 | /** | |
23 | * 型変換の失敗を表すクラスです。 | |
24 | * | |
25 | * @author baba | |
26 | */ | |
27 | public class ConversionFailure { | |
28 | ||
29 | /** フィールド名。 */ | |
30 | private final String fieldName; | |
31 | ||
32 | /** メッセージ情報。 */ | |
33 | private final MessageInfo messageInfo; | |
34 | ||
35 | /** フィールド情報。 */ | |
36 | private final FieldInfo[] fieldInfos; | |
37 | ||
38 | /** | |
39 | * インスタンス化します。 | |
40 | * | |
41 | * @param fieldName | |
42 | * フィールド名 | |
43 | * @param messageInfo | |
44 | * メッセージ情報 | |
45 | * @param fieldInfos | |
46 | * フィールド情報 | |
47 | */ | |
48 | public ConversionFailure(final String fieldName, | |
49 | 38 | final MessageInfo messageInfo, final FieldInfo... fieldInfos) { |
50 | 38 | this.fieldName = fieldName; |
51 | 38 | this.messageInfo = messageInfo; |
52 | 38 | this.fieldInfos = fieldInfos; |
53 | 38 | } |
54 | ||
55 | /** | |
56 | * フィールド名を取得します。 | |
57 | * | |
58 | * @return フィールド名 | |
59 | */ | |
60 | public String getFieldName() { | |
61 | 38 | return fieldName; |
62 | } | |
63 | ||
64 | /** | |
65 | * メッセージ情報を取得します。 | |
66 | * | |
67 | * @return メッセージ情報 | |
68 | */ | |
69 | public MessageInfo getMessageInfo() { | |
70 | 38 | return messageInfo; |
71 | } | |
72 | ||
73 | /** | |
74 | * フィールド情報を取得します。 | |
75 | * | |
76 | * @return フィールド情報 | |
77 | */ | |
78 | public FieldInfo[] getFieldInfos() { | |
79 | 38 | return fieldInfos; |
80 | } | |
81 | ||
82 | } |