[OpenJDK 2D-Dev] [9] RFR JDK-8149562: TIFFField#createFromMetadataNode javadoc should provide information about sibling/child nodes that should be part of parameter node
Brian Burkhalter
brian.burkhalter at oracle.com
Tue Aug 23 18:17:26 UTC 2016
Here is a revision based on the CCC request discussion:
http://cr.openjdk.java.net/~bpb/8149562/webrev.01/
It was necessary slightly to modify one test as well.
Thanks,
Brian
On Aug 17, 2016, at 10:39 AM, Phil Race <philip.race at oracle.com> wrote:
> +1
>
> -phil.
>
> On 08/16/2016 09:02 AM, Brian Burkhalter wrote:
>> Please review at your convenience.
>>
>> Issue: https://bugs.openjdk.java.net/browse/JDK-8149562
>> Patch: [1]
>>
>> Add one sentence to the TIFFField.createFromMetadataNode method specification stating that the supplied Node parameter must adhere to the TIFFField element structure defined by the TIFF native image metadata DTD.
>>
>> Thanks,
>>
>> Brian
>>
>> [1] diff
>>
>> --- a/src/java.desktop/share/classes/javax/imageio/plugins/tiff/TIFFField.java
>> +++ b/src/java.desktop/share/classes/javax/imageio/plugins/tiff/TIFFField.java
>>
>> /**
>> * Creates a {@code TIFFField} from a TIFF native image
>> * metadata node. If the value of the {@code “number"} attribute
>> * of the node is not found in {@code tagSet} then a new
>> * {@code TIFFTag} with name {@code TIFFTag.UNKNOWN_TAG_NAME}
>> - * will be created and assigned to the field.
>> + * will be created and assigned to the field. If the {@code Node}
>> + * parameter content does not adhere to the {@code TIFFField} element
>> + * structure defined by the
>> + * <a href="../../metadata/doc-files/tiff_metadata.html#ImageMetadata">
>> + * TIFF native image metadata format specification</a>
>> + * an {@code Exception} will be thrown.
>> *
>> * @param tagSet The {@code TIFFTagSet} to which the
>> * {@code TIFFTag} of the field belongs.
>> * @param node A native TIFF image metadata {@code TIFFField} node.
>> * @throws NullPointerException if {@code node} is
>> * {@code null}.
>> * @throws IllegalArgumentException if the name of the node is not
>> * {@code "TIFFField"}.
>> * @throws NullPointerException if the node does not contain any data.
>> * @throws IllegalArgumentException if the combination of node attributes
>> * and data is not legal per the {@link #TIFFField(TIFFTag,int,int,Object)}
>> * constructor specification.
>> * @return A new {@code TIFFField}.
>> */
>> public static TIFFField createFromMetadataNode(TIFFTagSet tagSet,
>> Node node) {
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/2d-dev/attachments/20160823/d68ff3f1/attachment.html>
More information about the 2d-dev
mailing list