equal
deleted
inserted
replaced
69 * |
69 * |
70 * @param detailMessage value to be used in constructing detail message |
70 * @param detailMessage value to be used in constructing detail message |
71 * @see Throwable#getCause() |
71 * @see Throwable#getCause() |
72 */ |
72 */ |
73 public AssertionError(Object detailMessage) { |
73 public AssertionError(Object detailMessage) { |
74 this("" + detailMessage); |
74 this(String.valueOf(detailMessage)); |
75 if (detailMessage instanceof Throwable) |
75 if (detailMessage instanceof Throwable) |
76 initCause((Throwable) detailMessage); |
76 initCause((Throwable) detailMessage); |
77 } |
77 } |
78 |
78 |
79 /** |
79 /** |
83 * <cite>The Java™ Language Specification</cite>. |
83 * <cite>The Java™ Language Specification</cite>. |
84 * |
84 * |
85 * @param detailMessage value to be used in constructing detail message |
85 * @param detailMessage value to be used in constructing detail message |
86 */ |
86 */ |
87 public AssertionError(boolean detailMessage) { |
87 public AssertionError(boolean detailMessage) { |
88 this("" + detailMessage); |
88 this(String.valueOf(detailMessage)); |
89 } |
89 } |
90 |
90 |
91 /** |
91 /** |
92 * Constructs an AssertionError with its detail message derived |
92 * Constructs an AssertionError with its detail message derived |
93 * from the specified <code>char</code>, which is converted to a |
93 * from the specified <code>char</code>, which is converted to a |
95 * <cite>The Java™ Language Specification</cite>. |
95 * <cite>The Java™ Language Specification</cite>. |
96 * |
96 * |
97 * @param detailMessage value to be used in constructing detail message |
97 * @param detailMessage value to be used in constructing detail message |
98 */ |
98 */ |
99 public AssertionError(char detailMessage) { |
99 public AssertionError(char detailMessage) { |
100 this("" + detailMessage); |
100 this(String.valueOf(detailMessage)); |
101 } |
101 } |
102 |
102 |
103 /** |
103 /** |
104 * Constructs an AssertionError with its detail message derived |
104 * Constructs an AssertionError with its detail message derived |
105 * from the specified <code>int</code>, which is converted to a |
105 * from the specified <code>int</code>, which is converted to a |
107 * <cite>The Java™ Language Specification</cite>. |
107 * <cite>The Java™ Language Specification</cite>. |
108 * |
108 * |
109 * @param detailMessage value to be used in constructing detail message |
109 * @param detailMessage value to be used in constructing detail message |
110 */ |
110 */ |
111 public AssertionError(int detailMessage) { |
111 public AssertionError(int detailMessage) { |
112 this("" + detailMessage); |
112 this(String.valueOf(detailMessage)); |
113 } |
113 } |
114 |
114 |
115 /** |
115 /** |
116 * Constructs an AssertionError with its detail message derived |
116 * Constructs an AssertionError with its detail message derived |
117 * from the specified <code>long</code>, which is converted to a |
117 * from the specified <code>long</code>, which is converted to a |
119 * <cite>The Java™ Language Specification</cite>. |
119 * <cite>The Java™ Language Specification</cite>. |
120 * |
120 * |
121 * @param detailMessage value to be used in constructing detail message |
121 * @param detailMessage value to be used in constructing detail message |
122 */ |
122 */ |
123 public AssertionError(long detailMessage) { |
123 public AssertionError(long detailMessage) { |
124 this("" + detailMessage); |
124 this(String.valueOf(detailMessage)); |
125 } |
125 } |
126 |
126 |
127 /** |
127 /** |
128 * Constructs an AssertionError with its detail message derived |
128 * Constructs an AssertionError with its detail message derived |
129 * from the specified <code>float</code>, which is converted to a |
129 * from the specified <code>float</code>, which is converted to a |
131 * <cite>The Java™ Language Specification</cite>. |
131 * <cite>The Java™ Language Specification</cite>. |
132 * |
132 * |
133 * @param detailMessage value to be used in constructing detail message |
133 * @param detailMessage value to be used in constructing detail message |
134 */ |
134 */ |
135 public AssertionError(float detailMessage) { |
135 public AssertionError(float detailMessage) { |
136 this("" + detailMessage); |
136 this(String.valueOf(detailMessage)); |
137 } |
137 } |
138 |
138 |
139 /** |
139 /** |
140 * Constructs an AssertionError with its detail message derived |
140 * Constructs an AssertionError with its detail message derived |
141 * from the specified <code>double</code>, which is converted to a |
141 * from the specified <code>double</code>, which is converted to a |
143 * <cite>The Java™ Language Specification</cite>. |
143 * <cite>The Java™ Language Specification</cite>. |
144 * |
144 * |
145 * @param detailMessage value to be used in constructing detail message |
145 * @param detailMessage value to be used in constructing detail message |
146 */ |
146 */ |
147 public AssertionError(double detailMessage) { |
147 public AssertionError(double detailMessage) { |
148 this("" + detailMessage); |
148 this(String.valueOf(detailMessage)); |
149 } |
149 } |
150 |
150 |
151 /** |
151 /** |
152 * Constructs a new {@code AssertionError} with the specified |
152 * Constructs a new {@code AssertionError} with the specified |
153 * detail message and cause. |
153 * detail message and cause. |