This commit is contained in:
Arjen Poutsma 2011-05-12 09:00:39 +00:00
parent 580f35f6ee
commit 8190b4f70a
1 changed files with 18 additions and 18 deletions

View File

@ -187,7 +187,7 @@ public class MediaType implements Comparable<MediaType> {
/** /**
* Create a new {@link MediaType} for the given primary type. * Create a new {@code MediaType} for the given primary type.
* <p>The {@linkplain #getSubtype() subtype} is set to <code>&#42;</code>, parameters empty. * <p>The {@linkplain #getSubtype() subtype} is set to <code>&#42;</code>, parameters empty.
* @param type the primary type * @param type the primary type
* @throws IllegalArgumentException if any of the parameters contain illegal characters * @throws IllegalArgumentException if any of the parameters contain illegal characters
@ -197,7 +197,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Create a new {@link MediaType} for the given primary type and subtype. * Create a new {@code MediaType} for the given primary type and subtype.
* <p>The parameters are empty. * <p>The parameters are empty.
* @param type the primary type * @param type the primary type
* @param subtype the subtype * @param subtype the subtype
@ -208,7 +208,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Create a new {@link MediaType} for the given type, subtype, and character set. * Create a new {@code MediaType} for the given type, subtype, and character set.
* @param type the primary type * @param type the primary type
* @param subtype the subtype * @param subtype the subtype
* @param charSet the character set * @param charSet the character set
@ -219,7 +219,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Create a new {@link MediaType} for the given type, subtype, and quality value. * Create a new {@code MediaType} for the given type, subtype, and quality value.
* *
* @param type the primary type * @param type the primary type
* @param subtype the subtype * @param subtype the subtype
@ -231,7 +231,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Copy-constructor that copies the type and subtype of the given {@link MediaType}, * Copy-constructor that copies the type and subtype of the given {@code MediaType},
* and allows for different parameter. * and allows for different parameter.
* @param other the other media type * @param other the other media type
* @param parameters the parameters, may be <code>null</code> * @param parameters the parameters, may be <code>null</code>
@ -242,7 +242,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Create a new {@link MediaType} for the given type, subtype, and parameters. * Create a new {@code MediaType} for the given type, subtype, and parameters.
* @param type the primary type * @param type the primary type
* @param subtype the subtype * @param subtype the subtype
* @param parameters the parameters, may be <code>null</code> * @param parameters the parameters, may be <code>null</code>
@ -372,9 +372,9 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Indicate whether this {@link MediaType} includes the given media type. * Indicate whether this {@code MediaType} includes the given media type.
* <p>For instance, {@code text/*} includes {@code text/plain}, {@code text/html}, and {@code application/*+xml} * <p>For instance, {@code text/*} includes {@code text/plain} and {@code text/html}, and {@code application/*+xml}
* includes {@code application/soap+xml}, etc. This method is non-symmetic. * includes {@code application/soap+xml}, etc. This method is <b>not</b> symmetric.
* @param other the reference media type with which to compare * @param other the reference media type with which to compare
* @return <code>true</code> if this media type includes the given media type; <code>false</code> otherwise * @return <code>true</code> if this media type includes the given media type; <code>false</code> otherwise
*/ */
@ -407,9 +407,9 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Indicate whether this {@link MediaType} is compatible with the given media type. * Indicate whether this {@code MediaType} is compatible with the given media type.
* <p>For instance, {@code text/*} is compatible with {@code text/plain}, {@code text/html}, and vice versa. * <p>For instance, {@code text/*} is compatible with {@code text/plain}, {@code text/html}, and vice versa.
* In effect, this method is similar to {@link #includes(MediaType)}, except that it's symmetric. * In effect, this method is similar to {@link #includes(MediaType)}, except that it <b>is</b> symmetric.
* @param other the reference media type with which to compare * @param other the reference media type with which to compare
* @return <code>true</code> if this media type is compatible with the given media type; <code>false</code> otherwise * @return <code>true</code> if this media type is compatible with the given media type; <code>false</code> otherwise
*/ */
@ -444,7 +444,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Compares this {@link MediaType} to another alphabetically. * Compares this {@code MediaType} to another alphabetically.
* @param other media type to compare to * @param other media type to compare to
* @see #sortBySpecificity(List) * @see #sortBySpecificity(List)
*/ */
@ -533,7 +533,7 @@ public class MediaType implements Comparable<MediaType> {
/** /**
* Parse the given String value into a {@link MediaType} object, * Parse the given String value into a {@code MediaType} object,
* with this method name following the 'valueOf' naming convention * with this method name following the 'valueOf' naming convention
* (as supported by {@link org.springframework.core.convert.ConversionService}. * (as supported by {@link org.springframework.core.convert.ConversionService}.
* @see #parseMediaType(String) * @see #parseMediaType(String)
@ -543,7 +543,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Parse the given String into a single {@link MediaType}. * Parse the given String into a single {@code MediaType}.
* @param mediaType the string to parse * @param mediaType the string to parse
* @return the media type * @return the media type
* @throws IllegalArgumentException if the string cannot be parsed * @throws IllegalArgumentException if the string cannot be parsed
@ -586,7 +586,7 @@ public class MediaType implements Comparable<MediaType> {
/** /**
* Parse the given, comma-separated string into a list of {@link MediaType} objects. * Parse the given, comma-separated string into a list of {@code MediaType} objects.
* <p>This method can be used to parse an Accept or Content-Type header. * <p>This method can be used to parse an Accept or Content-Type header.
* @param mediaTypes the string to parse * @param mediaTypes the string to parse
* @return the list of media types * @return the list of media types
@ -605,7 +605,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Return a string representation of the given list of {@link MediaType} objects. * Return a string representation of the given list of {@code MediaType} objects.
* <p>This method can be used to for an {@code Accept} or {@code Content-Type} header. * <p>This method can be used to for an {@code Accept} or {@code Content-Type} header.
* @param mediaTypes the string to parse * @param mediaTypes the string to parse
* @return the list of media types * @return the list of media types
@ -624,7 +624,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Sorts the given list of {@link MediaType} objects by specificity. * Sorts the given list of {@code MediaType} objects by specificity.
* <p>Given two media types: * <p>Given two media types:
* <ol> * <ol>
* <li>if either media type has a {@linkplain #isWildcardType() wildcard type}, then the media type without the * <li>if either media type has a {@linkplain #isWildcardType() wildcard type}, then the media type without the
@ -657,7 +657,7 @@ public class MediaType implements Comparable<MediaType> {
} }
/** /**
* Sorts the given list of {@link MediaType} objects by quality value. * Sorts the given list of {@code MediaType} objects by quality value.
* <p>Given two media types: * <p>Given two media types:
* <ol> * <ol>
* <li>if the two media types have different {@linkplain #getQualityValue() quality value}, then the media type * <li>if the two media types have different {@linkplain #getQualityValue() quality value}, then the media type