< prev index next >

test/java/awt/font/LineBreakMeasurer/FRCTest.java

Print this page




   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 /*
  25  * @test
  26  * @bug 6448405 6519513 6745225
  27  * @summary static HashMap cache in LineBreakMeasurer can grow wihout bounds
  28  * @run main/othervm/timeout=600 -client -Xms16m -Xmx16m FRCTest

  29  */
  30 import java.awt.*;
  31 import java.awt.image.*;
  32 import java.awt.font.*;
  33 import java.awt.geom.*;
  34 import java.text.*;
  35 import java.util.Hashtable;
  36 
  37 public class FRCTest {
  38 
  39     static AttributedString vanGogh = new AttributedString(
  40         "Many people believe that Vincent van Gogh painted his best works " +
  41         "during the two-year period he spent in Provence. Here is where he " +
  42         "painted The Starry Night--which some consider to be his greatest " +
  43         "work of all. However, as his artistic brilliance reached new " +
  44         "heights in Provence, his physical and mental health plummeted. ",
  45         new Hashtable());
  46 
  47     public static void main(String[] args) {
  48 




   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 /*
  25  * @test
  26  * @bug 6448405 6519513 6745225
  27  * @summary static HashMap cache in LineBreakMeasurer can grow wihout bounds
  28  * @run main/othervm/timeout=600 -client -Xms16m -Xmx16m FRCTest
  29  * @key randomness
  30  */
  31 import java.awt.*;
  32 import java.awt.image.*;
  33 import java.awt.font.*;
  34 import java.awt.geom.*;
  35 import java.text.*;
  36 import java.util.Hashtable;
  37 
  38 public class FRCTest {
  39 
  40     static AttributedString vanGogh = new AttributedString(
  41         "Many people believe that Vincent van Gogh painted his best works " +
  42         "during the two-year period he spent in Provence. Here is where he " +
  43         "painted The Starry Night--which some consider to be his greatest " +
  44         "work of all. However, as his artistic brilliance reached new " +
  45         "heights in Provence, his physical and mental health plummeted. ",
  46         new Hashtable());
  47 
  48     public static void main(String[] args) {
  49 


< prev index next >