|
Generated by JDiff |
||||||||
| PREV PACKAGE NEXT PACKAGE FRAMES NO FRAMES | |||||||||
This file contains all the changes in documentation in the packagejava.awt.image.renderableas colored differences. Deletions are shownlike this, and additions are shown like this.
If no deletions or additions are shown in an entry, the HTML tags will be what has changed. The new HTML tags are shown in the differences. If no documentation existed, and then some was added in a later version, this change is noted in the appropriate class pages of differences, but the change is not shown on this page. Only changes in existing text are shown here. Similarly, documentation which was inherited from another class or interface is not shown here.
Note that an HTML error in the new documentation may cause the display of other documentation changes to be presented incorrectly. For instance, failure to close a <code> tag will cause all subsequent paragraphs to be displayed differently.
AClass ParameterBlock, constructor ParameterBlock(Vector)ParameterBlockencapsulates all the information about sources and parameters (Objects) required by a RenderableImageOp or other classes that process images.Although it is possible to place arbitrary objects in the source Vector users of this class may impose semantic constraints such as requiring all sources to be RenderedImages or RenderableImage.
ParameterBlockitself is merely a container and performs no checking on source or parameter types.All parameters in a
ParameterBlockare objects; convenience add and set methods are available that take arguments of base type and construct the appropriate subclass of Number (such as Integer or Float). Corresponding get methods perform a downward cast and have return values of base type; an exception will be thrown if the stored values do not have the correct type. There is no way to distinguish between the results of "short s; add(s)" and "add(new Short(s))".Note that the get and set methods operate on references. Therefore one must be careful not to share references between
ParameterBlocksParameterBlocks when this is inappropriate. For example to create a newParameterBlockthat is equal to an old one except for an added source one might be tempted to write:ParameterBlock addSource(ParameterBlock pb RenderableImage im) { ParameterBlock pb1 = new ParameterBlock(pb.getSources()); pb1.addSource(im); return pb1; }This code will have the side effect of altering the original
ParameterBlocksince the getSources operation returned a reference to its source Vector. Both pb and pb1 share their source Vector and a change in either is visible to both.A correct way to write the addSource function is to clone the source Vector:
ParameterBlock addSource (ParameterBlock pb RenderableImage im) { ParameterBlock pb1 = new ParameterBlock(pb.getSources().clone()); pb1.addSource(im); return pb1; }The clone method of
ParameterBlockhas been defined to perform a clone of both the source and parameter Vectors for this reason. A standard shallow clone is available as shallowClone.The addSource setSource add and set methods are defined to return 'this' after adding their argument. This allows use of syntax like:
ParameterBlock pb = new ParameterBlock(); op = new RenderableImageOp("operation" pb.add(arg1).add(arg2));
Constructs a ParameterBlock with a given Vector of sources.
Class ParameterBlock, constructor ParameterBlock(Vector, Vector)Constructs a ParameterBlock with a given Vector of sources and Vector of parameters.
Class ParameterBlock, Object clone()Creates a copy of aClass ParameterBlock, byte getByteParameter(int)ParameterBlock. The source and parameter Vectors are cloned but the actual sources and parameters are copied by reference. This allows modifications to the order and number of sources and parameters in the clone to be invisible to the originalParameterBlock. Changes to the shared sources or parameters themselves will still be visible. @return an Object clone of theParameterBlock.
A convenience method to return a parameter as a byte. An exceptionClass ParameterBlock, char getCharParameter(int)will beis thrown if the parameter isnullor not aByte. @param index the index of the parameter to be returned. @return the parameter at the specified index as abytevalue. @throws ClassCastException if the parameter at the specified index is not aByte@throws NullPointerException if the parameter at the specified index isnull@throws ArrayIndexOutOfBoundsException ifindexis negative or not less than the current size of thisParameterBlockobject
A convenience method to return a parameter as a char. An exceptionClass ParameterBlock, double getDoubleParameter(int)will beis thrown if the parameter isnullor not aCharacter. @param index the index of the parameter to be returned. @return the parameter at the specified index as acharvalue. @throws ClassCastException if the parameter at the specified index is not aCharacter@throws NullPointerException if the parameter at the specified index isnull@throws ArrayIndexOutOfBoundsException ifindexis negative or not less than the current size of thisParameterBlockobject
A convenience method to return a parameter as a double. An exceptionClass ParameterBlock, float getFloatParameter(int)will beis thrown if the parameter isnullor not aDouble. @param index the index of the parameter to be returned. @return the parameter at the specified index as adoublevalue. @throws ClassCastException if the parameter at the specified index is not aDouble@throws NullPointerException if the parameter at the specified index isnull@throws ArrayIndexOutOfBoundsException ifindexis negative or not less than the current size of thisParameterBlockobject
A convenience method to return a parameter as a float. An exceptionClass ParameterBlock, int getIntParameter(int)will beis thrown if the parameter isnullor not aFloat. @param index the index of the parameter to be returned. @return the parameter at the specified index as afloatvalue. @throws ClassCastException if the parameter at the specified index is not aFloat@throws NullPointerException if the parameter at the specified index isnull@throws ArrayIndexOutOfBoundsException ifindexis negative or not less than the current size of thisParameterBlockobject
A convenience method to return a parameter as an int. An exceptionClass ParameterBlock, long getLongParameter(int)will beis thrown if the parameter isnullor not anInteger. @param index the index of the parameter to be returned. @return the parameter at the specified index as aintvalue. @throws ClassCastException if the parameter at the specified index is not aInteger@throws NullPointerException if the parameter at the specified index isnull@throws ArrayIndexOutOfBoundsException ifindexis negative or not less than the current size of thisParameterBlockobject
A convenience method to return a parameter as a long. An exceptionClass ParameterBlock, short getShortParameter(int)will beis thrown if the parameter isnullor not aLong. @param index the index of the parameter to be returned. @return the parameter at the specified index as alongvalue. @throws ClassCastException if the parameter at the specified index is not aLong@throws NullPointerException if the parameter at the specified index isnull@throws ArrayIndexOutOfBoundsException ifindexis negative or not less than the current size of thisParameterBlockobject
A convenience method to return a parameter as a short. An exceptionClass ParameterBlock, Object shallowClone()will beis thrown if the parameter isnullor not aShort. @param index the index of the parameter to be returned. @return the parameter at the specified index as ashortvalue. @throws ClassCastException if the parameter at the specified index is not aShort@throws NullPointerException if the parameter at the specified index isnull@throws ArrayIndexOutOfBoundsException ifindexis negative or not less than the current size of thisParameterBlockobject
Creates a shallow copy of aParameterBlock. The source and parameter Vectors are copied by reference -- additions or changes will be visible to both versions. @return an Object clone of theParameterBlock.
Modifies the current user-to-device transform by appending another transform. In matrix notation the operation is:Class RenderContext, void preConcetenateTransform(AffineTransform)[this] = [this] x [modTransform]This method does the same thing as the concatenateTransform method. It is here for backward compatibility with previous releases which misspelled the method name. @param modTransform the AffineTransform to append to the current usr2dev transform. @deprecated replaced byconcatenateTransform(AffineTransform).
Modifies the current user-to-device transform by prepending another transform. In matrix notation the operation is:[this] = [modTransform] x [this]This method does the same thing as the preConcatenateTransform method. It is here for backward compatibility with previous releases which misspelled the method name. @param modTransform the AffineTransform to prepend to the current usr2dev transform. @deprecated replaced bypreConcatenateTransform(AffineTransform).