Skip to content

Commit 42fd091

Browse files
Fix a couple javadoc mistakes
1 parent 06d7cb9 commit 42fd091

File tree

2 files changed

+35
-36
lines changed

2 files changed

+35
-36
lines changed

src/main/java/org/assertj/core/api/AbstractClassAssert.java

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@
1818

1919
/**
2020
* Base class for all implementations of assertions for {@link Class}es.
21-
*
21+
*
2222
* @param <SELF> the "self" type of this assertion class. Please read &quot;<a href="http://bit.ly/1IZIRcY"
2323
* target="_blank">Emulating 'self types' using Java Generics to simplify fluent API implementation</a>&quot;
2424
* for more details.
25-
*
25+
*
2626
* @author William Delanoue
2727
* @author Mikhail Mazursky
2828
*/
@@ -41,13 +41,13 @@ public AbstractClassAssert(Class<?> actual, Class<?> selfType) {
4141
* Example:
4242
* <pre><code class='java'> class Jedi {}
4343
* class HumanJedi extends Jedi {}
44-
*
44+
*
4545
* // this assertion succeeds:
4646
* assertThat(Jedi.class).isAssignableFrom(HumanJedi.class);
47-
*
47+
*
4848
* // this assertion fails:
4949
* assertThat(HumanJedi.class).isAssignableFrom(Jedi.class);</code></pre>
50-
*
50+
*
5151
* @see Class#isAssignableFrom(Class)
5252
* @param others {@code Class} who can be assignable from.
5353
* @return {@code this} assertions object
@@ -66,13 +66,13 @@ public SELF isAssignableFrom(Class<?>... others) {
6666
* Example:
6767
* <pre><code class='java'> interface Jedi {}
6868
* class HumanJedi implements Jedi {}
69-
*
69+
*
7070
* // this assertion succeeds:
7171
* assertThat(HumanJedi.class).isNotInterface();
72-
*
72+
*
7373
* // this assertion fails:
7474
* assertThat(Jedi.class).isNotInterface();</code></pre>
75-
*
75+
*
7676
* @return {@code this} assertions object
7777
* @throws AssertionError if {@code actual} is {@code null}.
7878
* @throws AssertionError if the actual {@code Class} is not an interface.
@@ -88,13 +88,13 @@ public SELF isNotInterface() {
8888
* Example:
8989
* <pre><code class='java'> interface Jedi {}
9090
* class HumanJedi implements Jedi {}
91-
*
91+
*
9292
* // this assertion succeeds:
9393
* assertThat(Jedi.class).isInterface();
94-
*
94+
*
9595
* // this assertion fails:
9696
* assertThat(HumanJedi.class).isInterface();</code></pre>
97-
*
97+
*
9898
* @return {@code this} assertions object
9999
* @throws AssertionError if {@code actual} is {@code null}.
100100
* @throws AssertionError if the actual {@code Class} is not an interface.
@@ -132,15 +132,15 @@ public SELF isAbstract() {
132132
* <p>
133133
* Example:
134134
* <pre><code class='java'> public @interface Jedi {}
135-
*
135+
*
136136
* // these assertions succeed:
137137
* assertThat(Jedi.class).isAnnotation();
138138
* assertThat(Override.class).isAnnotation();
139139
* assertThat(Deprecated.class).isAnnotation();
140-
*
140+
*
141141
* // this assertion fails:
142142
* assertThat(String.class).isAnnotation();</code></pre>
143-
*
143+
*
144144
* @return {@code this} assertions object
145145
* @throws AssertionError if {@code actual} is {@code null}.
146146
* @throws AssertionError if the actual {@code Class} is not an annotation.
@@ -155,15 +155,15 @@ public SELF isAnnotation() {
155155
* <p>
156156
* Example:
157157
* <pre><code class='java'> public @interface Jedi {}
158-
*
158+
*
159159
* // this assertion succeeds:
160160
* assertThat(String.class).isNotAnnotation();
161-
*
161+
*
162162
* // these assertions fail:
163163
* assertThat(Jedi.class).isNotAnnotation();
164164
* assertThat(Override.class).isNotAnnotation();
165165
* assertThat(Deprecated.class).isNotAnnotation();</code></pre>
166-
*
166+
*
167167
* @return {@code this} assertions object
168168
* @throws AssertionError if {@code actual} is {@code null}.
169169
* @throws AssertionError if the actual {@code Class} is an annotation.
@@ -294,24 +294,24 @@ public SELF isPackagePrivate() {
294294
* <pre><code class='java'> &#64;Target(ElementType.TYPE)
295295
* &#64;Retention(RetentionPolicy.RUNTIME)
296296
* private static @interface Force { }
297-
*
297+
*
298298
* &#64;Target(ElementType.TYPE)
299299
* &#64;Retention(RetentionPolicy.RUNTIME)
300300
* private static @interface Hero { }
301-
*
301+
*
302302
* &#64;Target(ElementType.TYPE)
303303
* &#64;Retention(RetentionPolicy.RUNTIME)
304304
* private static @interface DarkSide { }
305-
*
305+
*
306306
* &#64;Hero &#64;Force
307307
* class Jedi implements Jedi {}
308-
*
308+
*
309309
* // this assertion succeeds:
310310
* assertThat(Jedi.class).containsAnnotations(Force.class, Hero.class);
311-
*
311+
*
312312
* // this assertion fails:
313313
* assertThat(Jedi.class).containsAnnotations(Force.class, DarkSide.class);</code></pre>
314-
*
314+
*
315315
* @param annotations annotations who must be attached to the class
316316
* @return {@code this} assertions object
317317
* @throws AssertionError if {@code actual} is {@code null}.
@@ -331,13 +331,13 @@ public SELF hasAnnotations(@SuppressWarnings("unchecked") Class<? extends Annota
331331
* private static @interface Force { }
332332
* &#64;Force
333333
* class Jedi implements Jedi {}
334-
*
334+
*
335335
* // this assertion succeeds:
336336
* assertThat(Jedi.class).containsAnnotation(Force.class);
337-
*
337+
*
338338
* // this assertion fails:
339339
* assertThat(Jedi.class).containsAnnotation(DarkSide.class);</code></pre>
340-
*
340+
*
341341
* @param annotation annotations who must be attached to the class
342342
* @return {@code this} assertions object
343343
* @throws AssertionError if {@code actual} is {@code null}.
@@ -402,7 +402,7 @@ public SELF hasSuperclass(Class<?> superclass) {
402402
* assertThat(Void.TYPE).hasNoSuperclass();
403403
*
404404
* // this assertion fails as Integer has Number as superclass:
405-
* assertThat(Integer.class).hasSuperclass(Number.class);</code></pre>
405+
* assertThat(Integer.class).hasNoSuperclass(Number.class);</code></pre>
406406
*
407407
* @return {@code this} assertions object
408408
* @throws AssertionError if {@code actual} is {@code null}.
@@ -435,18 +435,18 @@ public SELF hasFields(String... fields) {
435435
* String fieldThree;
436436
* private String fieldFour;
437437
* }
438-
*
438+
*
439439
* // this assertion succeeds:
440440
* assertThat(MyClass.class).hasPublicFields("fieldOne");
441-
*
441+
*
442442
* // these assertions fail:
443443
* assertThat(MyClass.class).hasPublicFields("fieldTwo");
444444
* assertThat(MyClass.class).hasPublicFields("fieldThree");
445445
* assertThat(MyClass.class).hasPublicFields("fieldFour");
446446
* assertThat(MyClass.class).hasPublicFields("unknownField");</code></pre>
447447
* <p>
448448
* The assertion succeeds if no given fields are passed and the actual {@code Class} has no accessible public fields.
449-
*
449+
*
450450
* @see Class#getField(String)
451451
* @param fields the fields who must be in the class.
452452
* @return {@code this} assertions object
@@ -459,7 +459,7 @@ public SELF hasPublicFields(String... fields) {
459459
}
460460

461461
/**
462-
* Verifies that the actual {@code Class} <b>only</b> has the given accessible public
462+
* Verifies that the actual {@code Class} <b>only</b> has the given accessible public
463463
* fields (as in {@link Class#getFields()}) and nothing more <b>in any order</b>.
464464
* <p>
465465
* Example:
@@ -499,15 +499,15 @@ public SELF hasOnlyPublicFields(String... fields) {
499499
* public String fieldOne;
500500
* private String fieldTwo;
501501
* }
502-
*
502+
*
503503
* // this assertion succeeds:
504504
* assertThat(MyClass.class).hasDeclaredFields("fieldOne", "fieldTwo");
505-
*
505+
*
506506
* // this assertion fails:
507507
* assertThat(MyClass.class).hasDeclaredFields("fieldThree");</code></pre>
508508
* <p>
509509
* The assertion succeeds if no given fields are passed and the actual {@code Class} has no declared fields.
510-
*
510+
*
511511
* @see Class#getDeclaredField(String)
512512
* @param fields the fields who must be declared in the class.
513513
* @return {@code this} assertions object
@@ -520,7 +520,7 @@ public SELF hasDeclaredFields(String... fields) {
520520
}
521521

522522
/**
523-
* Verifies that the actual {@code Class} <b>only</b> has the given declared {@code fields} and nothing more <b>in any order</b>
523+
* Verifies that the actual {@code Class} <b>only</b> has the given declared {@code fields} and nothing more <b>in any order</b>
524524
* (as in {@link Class#getDeclaredFields()}).
525525
* <p>
526526
* Example:

src/main/java/org/assertj/core/api/AbstractMapAssert.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1868,7 +1868,6 @@ public AbstractListAssert<?, List<?>, Object, ObjectAssert<Object>> flatExtracti
18681868
* Person sheldon = new Person("Sheldon Cooper", true);
18691869
* Person leonard = new Person("Leonard Hofstadter", true);
18701870
* Person raj = new Person("Raj Koothrappali", true);
1871-
* Person howard = new Person("Howard Wolowitz", false);
18721871
*
18731872
* Map&lt;String, Doctor&gt; doctors = mapOf(entry(drSheldon.name, drSheldon),
18741873
* entry(drLeonard.name, drLeonard),

0 commit comments

Comments
 (0)