JBoss Rich Faces SVN: r12110 - in trunk/test-applications/realworld/web/src/main/webapp: WEB-INF/tags and 9 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: amarkhel
Date: 2009-01-05 11:51:42 -0500 (Mon, 05 Jan 2009)
New Revision: 12110
Added:
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/lib/metadata-extractor-2.3.1.jar
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/realWorld-taglib.xml
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/album.xhtml
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/comment.xhtml
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/image.xhtml
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/linkPanel.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/image/comments.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/image/imagePreview.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/image/imageScroller.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/image/mainImage.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/image/slideshow.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/imagePreview.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/index/about.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/index/login.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/messages.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/misc/messagePooler.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/misc/modalPanels.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/misc/slideShowPooler.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/friends.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/sharedAlbums.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/tree.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/search.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/search/advancedSearch.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/search/searchResults.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs/loginPrefsTab.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs/userPrefsTab.xhtml
trunk/test-applications/realworld/web/src/main/webapp/layout/panelBar.xhtml
Log:
Added: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/lib/metadata-extractor-2.3.1.jar
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/lib/metadata-extractor-2.3.1.jar
___________________________________________________________________
Name: svn:mime-type
+ application/x-jar
Added: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/realWorld-taglib.xml
===================================================================
--- trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/realWorld-taglib.xml (rev 0)
+++ trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/realWorld-taglib.xml 2009-01-05 16:51:42 UTC (rev 12110)
@@ -0,0 +1,31 @@
+<?xml version="1.0"?>
+<!DOCTYPE facelet-taglib PUBLIC
+ "-//Sun Microsystems, Inc.//DTD Facelet Taglib 1.0//EN"
+ "facelet-taglib_1_0.dtd">
+<facelet-taglib>
+ <namespace>http://richfaces.org/richx</namespace>
+ <tag>
+ <tag-name>album</tag-name>
+ <source>templates/album.xhtml</source>
+ </tag>
+ <tag>
+ <tag-name>confirmation</tag-name>
+ <source>templates/confirmation.xhtml</source>
+ </tag>
+ <tag>
+ <tag-name>image</tag-name>
+ <source>templates/image.xhtml</source>
+ </tag>
+ <tag>
+ <tag-name>comment</tag-name>
+ <source>templates/comment.xhtml</source>
+ </tag>
+ <tag>
+ <tag-name>message</tag-name>
+ <source>templates/message.xhtml</source>
+ </tag>
+ <tag>
+ <tag-name>linkPanel</tag-name>
+ <source>templates/linkPanel.xhtml</source>
+ </tag>
+</facelet-taglib>
\ No newline at end of file
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/realWorld-taglib.xml
___________________________________________________________________
Name: svn:mime-type
+ text/xml
Name: svn:eol-style
+ native
Added: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/album.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/album.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/comment.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/comment.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/image.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/image.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/linkPanel.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/tags/templates/linkPanel.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/image/comments.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/image/comments.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/image/imagePreview.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/image/imagePreview.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/image/imageScroller.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/image/imageScroller.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/image/mainImage.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/image/mainImage.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/image/slideshow.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/image/slideshow.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/imagePreview.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/imagePreview.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/index/about.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/index/about.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/index/login.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/index/login.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/messages.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/messages.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/misc/messagePooler.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/misc/messagePooler.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/misc/modalPanels.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/misc/modalPanels.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/misc/slideShowPooler.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/misc/slideShowPooler.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/friends.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/friends.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/sharedAlbums.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/sharedAlbums.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/tree.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/tree.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/search/advancedSearch.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/search/advancedSearch.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/search/searchResults.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/search/searchResults.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/search.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/search.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs/loginPrefsTab.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs/loginPrefsTab.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs/userPrefsTab.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs/userPrefsTab.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Added: trunk/test-applications/realworld/web/src/main/webapp/layout/panelBar.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/layout/panelBar.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
16 years
JBoss Rich Faces SVN: r12109 - in trunk/test-applications/realworld/web/src/main/webapp: includes and 1 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: amarkhel
Date: 2009-01-05 11:45:35 -0500 (Mon, 05 Jan 2009)
New Revision: 12109
Added:
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/lib/
trunk/test-applications/realworld/web/src/main/webapp/includes/gallery/
trunk/test-applications/realworld/web/src/main/webapp/includes/gallery/gallery.xhtml
trunk/test-applications/realworld/web/src/main/webapp/includes/image/
trunk/test-applications/realworld/web/src/main/webapp/includes/index/
trunk/test-applications/realworld/web/src/main/webapp/includes/misc/
trunk/test-applications/realworld/web/src/main/webapp/includes/panelBar/
trunk/test-applications/realworld/web/src/main/webapp/includes/search/
trunk/test-applications/realworld/web/src/main/webapp/includes/userPrefs/
Log:
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/gallery/gallery.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/gallery/gallery.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
16 years
JBoss Rich Faces SVN: r12108 - in trunk/test-applications/realworld: Upload/amarkhel/Cars and 23 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: amarkhel
Date: 2009-01-05 11:44:21 -0500 (Mon, 05 Jan 2009)
New Revision: 12108
Added:
trunk/test-applications/realworld/Upload/amarkhel/Cars/Pagani_Zonda_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/Pagani_Zonda_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/aston_martin_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/aston_martin_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/ferrari_profile_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/ferrari_profile_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/holden-efijy-1809_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/holden-efijy-1809_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/hulme_supercar_side_parked_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/hulme_supercar_side_parked_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/spadaconcept codatronca_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/spadaconcept codatronca_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/supercar_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Cars/supercar_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Audrey_Tautou_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Audrey_Tautou_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Juliette_Binoche_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Juliette_Binoche_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Penelope_Cruz_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Penelope_Cruz_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Rihanna_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Rihanna_mini.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Uma_Turman_medium.jpg
trunk/test-applications/realworld/Upload/amarkhel/Tetki/Uma_Turman_mini.jpg
trunk/test-applications/realworld/Upload/galleries/
trunk/test-applications/realworld/Upload/galleries/Fun/
trunk/test-applications/realworld/Upload/galleries/Fun/img-20d46.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-20d46_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-25386.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-25386_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-2e015.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-2e015_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-31c2e.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-31c2e_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-334ee.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-334ee_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-6537e.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-6537e_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-69fe6.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-69fe6_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-7141c.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-7141c_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-828dd.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-828dd_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-99215.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-99215_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-9b1c2.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-9b1c2_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-a9307.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-a9307_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-b8d37.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-b8d37_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-be1c0.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-be1c0_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-cf3ee.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-cf3ee_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ada.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ada_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ed3.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ed3_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-d966e.jpg
trunk/test-applications/realworld/Upload/galleries/Fun/img-d966e_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/
trunk/test-applications/realworld/Upload/galleries/Sport/1.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/10.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/10_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/11.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/11_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/12.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/12_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/13.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/13_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/14.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/14_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/15.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/15_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/16.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/16_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/17.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/17_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/1_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/2.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/2_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/3.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/3_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/4.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/4_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/5.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/5_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/6.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/6_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/7.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/7_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/8.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/8_mini.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/9.jpg
trunk/test-applications/realworld/Upload/galleries/Sport/9_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/Haruki_Murakami_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/Haruki_Murakami_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/Japanese_Street_Fashion_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/Japanese_Street_Fashion_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/Kendo_Championship_2006_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/Kendo_Championship_2006_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/birds_fly_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/birds_fly_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/live_in_piece_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/live_in_piece_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/modern_japanesse_family_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/modern_japanesse_family_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/zen-garden_landscape_design_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Japan/zen-garden_landscape_design_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/Babkin_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/Babkin_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/Bob_Marley_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/Bob_Marley_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/Infected_Mushroom_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/Infected_Mushroom_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/StreetMusician_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/StreetMusician_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/massiveAttack_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/massiveAttack_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/system-of-a-down_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/system-of-a-down_mini.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/tobin_medium.jpg
trunk/test-applications/realworld/Upload/qqqq/Music/tobin_mini.jpg
trunk/test-applications/realworld/Upload/root/Avatars/pupkind_medium.jpg
trunk/test-applications/realworld/Upload/root/Avatars/pupkind_mini.jpg
trunk/test-applications/realworld/Upload/root/Avatars/pupkind_mini_medium.jpg
trunk/test-applications/realworld/Upload/root/Football/Basketball_soccer_medium.jpg
trunk/test-applications/realworld/Upload/root/Football/Basketball_soccer_mini.jpg
trunk/test-applications/realworld/Upload/root/Football/Soccer_medium.jpg
trunk/test-applications/realworld/Upload/root/Football/Soccer_mini.jpg
trunk/test-applications/realworld/Upload/root/Football/bdysch!!!_medium.jpg
trunk/test-applications/realworld/Upload/root/Football/bdysch!!!_mini.jpg
trunk/test-applications/realworld/Upload/root/Football/euro2008_holland_wideweb__470x321,0_medium.jpg
trunk/test-applications/realworld/Upload/root/Football/euro2008_holland_wideweb__470x321,0_mini.jpg
trunk/test-applications/realworld/Upload/root/Football/flag_football_medium.jpg
trunk/test-applications/realworld/Upload/root/Football/flag_football_mini.jpg
trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Gallery.java
trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/GalleryImage.java
trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/GalleryAction.java
trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/IGalleryAction.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/gallery/
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/gallery/GalleryBean.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/FileHelper.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/PictureServlet.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/WebUtil.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/LinkBuilder.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/test.java
trunk/test-applications/realworld/web/src/main/webapp/includes/fileUpload/fileUploadPanel.xhtml
Removed:
trunk/test-applications/realworld/Upload/root/Football/Soccer416x594.jpg
Modified:
trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Image.java
trunk/test-applications/realworld/ejb/src/main/resources/import.sql
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileManager.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileUploadBean.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/ImageLoader.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationEnum.java
trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationHelper.java
trunk/test-applications/realworld/web/src/main/resources/messages_en.properties
trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/components.xml
trunk/test-applications/realworld/web/src/main/webapp/img/Thumbs.db
trunk/test-applications/realworld/web/src/main/webapp/layout/menu.xhtml
trunk/test-applications/realworld/web/src/main/webapp/main.xhtml
Log:
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/Pagani_Zonda_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/Pagani_Zonda_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/Pagani_Zonda_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/Pagani_Zonda_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/aston_martin_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/aston_martin_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/aston_martin_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/aston_martin_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/ferrari_profile_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/ferrari_profile_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/ferrari_profile_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/ferrari_profile_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/holden-efijy-1809_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/holden-efijy-1809_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/holden-efijy-1809_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/holden-efijy-1809_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/hulme_supercar_side_parked_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/hulme_supercar_side_parked_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/hulme_supercar_side_parked_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/hulme_supercar_side_parked_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/spadaconcept codatronca_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/spadaconcept codatronca_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/spadaconcept codatronca_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/spadaconcept codatronca_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/supercar_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/supercar_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Cars/supercar_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Cars/supercar_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Audrey_Tautou_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Audrey_Tautou_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Audrey_Tautou_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Audrey_Tautou_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Juliette_Binoche_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Juliette_Binoche_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Juliette_Binoche_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Juliette_Binoche_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Penelope_Cruz_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Penelope_Cruz_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Penelope_Cruz_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Penelope_Cruz_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Rihanna_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Rihanna_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Rihanna_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Rihanna_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Uma_Turman_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Uma_Turman_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Uma_Turman_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/amarkhel/Tetki/Uma_Turman_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-20d46.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-20d46.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-20d46_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-20d46_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-25386.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-25386.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-25386_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-25386_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-2e015.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-2e015.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-2e015_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-2e015_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-31c2e.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-31c2e.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-31c2e_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-31c2e_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-334ee.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-334ee.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-334ee_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-334ee_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-6537e.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-6537e.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-6537e_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-6537e_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-69fe6.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-69fe6.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-69fe6_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-69fe6_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-7141c.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-7141c.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-7141c_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-7141c_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-828dd.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-828dd.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-828dd_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-828dd_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-99215.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-99215.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-99215_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-99215_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-9b1c2.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-9b1c2.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-9b1c2_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-9b1c2_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-a9307.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-a9307.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-a9307_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-a9307_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-b8d37.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-b8d37.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-b8d37_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-b8d37_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-be1c0.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-be1c0.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-be1c0_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-be1c0_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-cf3ee.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-cf3ee.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-cf3ee_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-cf3ee_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ada.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ada.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ada_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ada_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ed3.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ed3.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ed3_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-d5ed3_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-d966e.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-d966e.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Fun/img-d966e_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Fun/img-d966e_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/1.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/1.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/10.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/10.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/10_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/10_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/11.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/11.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/11_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/11_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/12.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/12.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/12_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/12_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/13.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/13.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/13_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/13_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/14.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/14.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/14_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/14_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/15.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/15.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/15_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/15_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/16.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/16.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/16_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/16_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/17.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/17.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/17_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/17_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/1_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/1_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/2.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/2.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/2_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/2_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/3.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/3.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/3_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/3_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/4.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/4.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/4_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/4_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/5.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/5.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/5_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/5_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/6.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/6.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/6_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/6_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/7.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/7.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/7_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/7_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/8.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/8.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/8_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/8_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/9.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/9.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/galleries/Sport/9_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/galleries/Sport/9_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/Haruki_Murakami_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/Haruki_Murakami_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/Haruki_Murakami_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/Haruki_Murakami_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/Japanese_Street_Fashion_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/Japanese_Street_Fashion_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/Japanese_Street_Fashion_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/Japanese_Street_Fashion_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/Kendo_Championship_2006_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/Kendo_Championship_2006_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/Kendo_Championship_2006_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/Kendo_Championship_2006_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/birds_fly_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/birds_fly_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/birds_fly_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/birds_fly_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/live_in_piece_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/live_in_piece_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/live_in_piece_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/live_in_piece_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/modern_japanesse_family_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/modern_japanesse_family_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/modern_japanesse_family_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/modern_japanesse_family_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/zen-garden_landscape_design_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/zen-garden_landscape_design_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Japan/zen-garden_landscape_design_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Japan/zen-garden_landscape_design_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/Babkin_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/Babkin_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/Babkin_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/Babkin_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/Bob_Marley_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/Bob_Marley_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/Bob_Marley_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/Bob_Marley_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/Infected_Mushroom_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/Infected_Mushroom_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/Infected_Mushroom_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/Infected_Mushroom_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/StreetMusician_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/StreetMusician_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/StreetMusician_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/StreetMusician_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/massiveAttack_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/massiveAttack_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/massiveAttack_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/massiveAttack_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/system-of-a-down_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/system-of-a-down_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/system-of-a-down_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/system-of-a-down_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/tobin_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/tobin_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/qqqq/Music/tobin_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/qqqq/Music/tobin_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Avatars/pupkind_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Avatars/pupkind_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Avatars/pupkind_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Avatars/pupkind_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Avatars/pupkind_mini_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Avatars/pupkind_mini_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/Basketball_soccer_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/Basketball_soccer_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/Basketball_soccer_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/Basketball_soccer_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Deleted: trunk/test-applications/realworld/Upload/root/Football/Soccer416x594.jpg
===================================================================
(Binary files differ)
Added: trunk/test-applications/realworld/Upload/root/Football/Soccer_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/Soccer_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/Soccer_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/Soccer_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/bdysch!!!_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/bdysch!!!_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/bdysch!!!_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/bdysch!!!_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/euro2008_holland_wideweb__470x321,0_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/euro2008_holland_wideweb__470x321,0_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/euro2008_holland_wideweb__470x321,0_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/euro2008_holland_wideweb__470x321,0_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/flag_football_medium.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/flag_football_medium.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/Upload/root/Football/flag_football_mini.jpg
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/Upload/root/Football/flag_football_mini.jpg
___________________________________________________________________
Name: svn:mime-type
+ image/jpeg
Added: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Gallery.java
===================================================================
--- trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Gallery.java (rev 0)
+++ trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Gallery.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,113 @@
+package org.richfaces.realworld.domain;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.persistence.CascadeType;
+import javax.persistence.Column;
+import javax.persistence.Entity;
+import javax.persistence.GeneratedValue;
+import javax.persistence.Id;
+import javax.persistence.OneToMany;
+import javax.persistence.Table;
+
+import org.hibernate.validator.Length;
+import org.hibernate.validator.NotEmpty;
+import org.hibernate.validator.NotNull;
+import org.jboss.seam.annotations.Name;
+
+@Entity
+@Name("gallery")
+@Table(name = "galleries")
+public class Gallery implements Serializable {
+
+ private static final long serialVersionUID = -7042878411608396483L;
+
+ @Id
+ @GeneratedValue
+ @Column(name = "GALLERY_ID")
+ private Long id = null;
+
+ @Column(length = 255, nullable = false)
+ @NotNull
+ @NotEmpty
+ @Length(min=3)
+ private String name;
+
+ @OneToMany(cascade = CascadeType.ALL, mappedBy = "gallery")
+ @org.hibernate.annotations.OrderBy(clause = "uploaded desc")
+ @org.hibernate.annotations.Fetch(org.hibernate.annotations.FetchMode.SUBSELECT)
+ private List<GalleryImage> images = new ArrayList<GalleryImage>();
+
+ /**
+ * Getter for property id
+ *
+ * @return id of album
+ */
+ public Long getId() {
+ return id;
+ }
+
+ /**
+ * Getter for property name
+ *
+ * @return name of album
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * Setter for property name
+ *
+ * @param name - name of album
+ */
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ /**
+ * This method add image to collection of images of current album
+ *
+ * @param image - image to add
+ */
+ public void addImage(GalleryImage image) {
+ if (image == null) {
+ throw new IllegalArgumentException("Null image!");
+ }
+ if (image.getGallery() != null && !this.equals(image.getGallery())) {
+ image.getGallery().getImages().remove(image);
+ }
+ image.setGallery(this);
+ images.add(image);
+ }
+
+ /**
+ * This method remove image from collection of images of album
+ *
+ * @param image - image to remove
+ */
+ public void removeImage(GalleryImage image) {
+ if (image == null) {
+ throw new IllegalArgumentException("Null image");
+ }
+ image.setGallery(null);
+ images.remove(image);
+ }
+
+ /**
+ * This method return count of images of current album
+ *
+ * @return count of images of this album
+ */
+ public int getCountImages() {
+ return this.getImages()!= null ? this.getImages().size() : 0;
+
+ }
+
+ public List<GalleryImage> getImages() {
+ return images;
+ }
+
+}
Property changes on: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Gallery.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Added: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/GalleryImage.java
===================================================================
--- trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/GalleryImage.java (rev 0)
+++ trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/GalleryImage.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,157 @@
+package org.richfaces.realworld.domain;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import javax.persistence.Column;
+import javax.persistence.Entity;
+import javax.persistence.FetchType;
+import javax.persistence.GeneratedValue;
+import javax.persistence.Id;
+import javax.persistence.JoinColumn;
+import javax.persistence.ManyToOne;
+import javax.persistence.Table;
+import javax.persistence.Temporal;
+import javax.persistence.TemporalType;
+
+import org.hibernate.validator.Length;
+import org.hibernate.validator.NotEmpty;
+import org.hibernate.validator.NotNull;
+import org.jboss.seam.annotations.Name;
+
+@Entity
+@Name("galleryImage")
+@Table(name = "galleryImages")
+public class GalleryImage implements Serializable {
+
+ private static final long serialVersionUID = -7042878411608396483L;
+
+ @Id
+ @GeneratedValue
+ @Column(name = "GALLERY_IMAGE_ID")
+ private Long id = null;
+
+ @Column(length = 255)
+ private String name;
+
+ @Column(length = 1024)
+ private String path;
+
+ @Column(length = 255)
+ private String cameraModel;
+
+ @Column(length = 255)
+ private String author;
+
+ private int height;
+
+ private double size;
+
+ private int width;
+
+ @Column(length = 1024)
+ private String description;
+
+ @Temporal(TemporalType.TIMESTAMP)
+ private Date created;
+
+ @Temporal(TemporalType.TIMESTAMP)
+ private Date uploaded;
+
+ @ManyToOne(fetch = FetchType.LAZY)
+ @JoinColumn(name="IMG_GALLERY_ID",
+ referencedColumnName="GALLERY_ID")
+ private Gallery gallery;
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public String getCameraModel() {
+ return cameraModel;
+ }
+
+ public void setCameraModel(String cameraModel) {
+ this.cameraModel = cameraModel;
+ }
+
+ public String getAuthor() {
+ return author;
+ }
+
+ public void setAuthor(String author) {
+ this.author = author;
+ }
+
+ public int getHeight() {
+ return height;
+ }
+
+ public void setHeight(int height) {
+ this.height = height;
+ }
+
+ public int getWidth() {
+ return width;
+ }
+
+ public void setWidth(int width) {
+ this.width = width;
+ }
+
+ public String getDescription() {
+ return description;
+ }
+
+ public void setDescription(String description) {
+ this.description = description;
+ }
+
+ public Date getCreated() {
+ return created;
+ }
+
+ public void setCreated(Date created) {
+ this.created = created;
+ }
+
+ public Gallery getGallery() {
+ return gallery;
+ }
+
+ public void setGallery(Gallery gallery) {
+ this.gallery = gallery;
+ }
+
+ public Long getId() {
+ return id;
+ }
+
+ public String getPath() {
+ return path;
+ }
+
+ public void setPath(String path) {
+ this.path = path;
+ }
+
+ public Date getUploaded() {
+ return uploaded;
+ }
+
+ public void setUploaded(Date uploaded) {
+ this.uploaded = uploaded;
+ }
+
+ public double getSize() {
+ return size;
+ }
+
+ public void setSize(double size) {
+ this.size = size;
+ }
+}
Property changes on: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/GalleryImage.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Modified: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Image.java
===================================================================
--- trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Image.java 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/domain/Image.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -64,6 +64,18 @@
@Length(min=3)
private String path;
+ @Column(length = 255)
+ private String cameraModel;
+
+ private int height;
+
+ private double size;
+
+ private int width;
+
+ @Temporal(TemporalType.TIMESTAMP)
+ private Date uploaded;
+
@OneToOne
@JoinColumn(name="RANK_ID")
private Rank rank;
@@ -267,4 +279,44 @@
public void setMeta(List<MetaTag> meta) {
this.meta = meta;
}
+
+ public String getCameraModel() {
+ return cameraModel;
+ }
+
+ public void setCameraModel(String cameraModel) {
+ this.cameraModel = cameraModel;
+ }
+
+ public int getHeight() {
+ return height;
+ }
+
+ public void setHeight(int height) {
+ this.height = height;
+ }
+
+ public double getSize() {
+ return size;
+ }
+
+ public void setSize(double size) {
+ this.size = size;
+ }
+
+ public int getWidth() {
+ return width;
+ }
+
+ public void setWidth(int width) {
+ this.width = width;
+ }
+
+ public Date getUploaded() {
+ return uploaded;
+ }
+
+ public void setUploaded(Date uploaded) {
+ this.uploaded = uploaded;
+ }
}
Added: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/GalleryAction.java
===================================================================
--- trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/GalleryAction.java (rev 0)
+++ trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/GalleryAction.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,45 @@
+package org.richfaces.realworld.service;
+
+import java.util.List;
+
+import javax.ejb.Stateless;
+import javax.persistence.EntityManager;
+
+import org.jboss.seam.annotations.In;
+import org.jboss.seam.annotations.Name;
+import org.richfaces.realworld.domain.Gallery;
+import org.richfaces.realworld.domain.GalleryImage;
+
+@Name("galleryAction")
+@Stateless
+public class GalleryAction implements IGalleryAction {
+
+ @In(value="entityManager")
+ EntityManager em;
+ /* (non-Javadoc)
+ * @see org.richfaces.realworld.service.IGalleryAction#addGallery(java.lang.String)
+ */
+ public void addGallery(String name){
+ Gallery gal = new Gallery();
+ gal.setName(name);
+ em.persist(gal);
+ em.flush();
+ }
+
+ /* (non-Javadoc)
+ * @see org.richfaces.realworld.service.IGalleryAction#addmage(org.richfaces.realworld.domain.Gallery, org.richfaces.realworld.domain.GalleryImage)
+ */
+ public void addImage(Gallery gallery, GalleryImage image){
+ gallery.addImage(image);
+ em.flush();
+ }
+
+ /* (non-Javadoc)
+ * @see org.richfaces.realworld.service.IGalleryAction#getGalleries()
+ */
+ public List<Gallery> getGalleries(){
+ List<Gallery> galleries = em.createQuery("from Gallery")
+ .getResultList();
+ return galleries;
+ }
+}
Property changes on: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/GalleryAction.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Added: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/IGalleryAction.java
===================================================================
--- trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/IGalleryAction.java (rev 0)
+++ trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/IGalleryAction.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,19 @@
+package org.richfaces.realworld.service;
+
+import java.util.List;
+
+import javax.ejb.Local;
+
+import org.richfaces.realworld.domain.Gallery;
+import org.richfaces.realworld.domain.GalleryImage;
+
+@Local
+public interface IGalleryAction {
+
+ public abstract void addGallery(String name);
+
+ public abstract void addImage(Gallery gallery, GalleryImage image);
+
+ public abstract List<Gallery> getGalleries();
+
+}
\ No newline at end of file
Property changes on: trunk/test-applications/realworld/ejb/src/main/java/org/richfaces/realworld/service/IGalleryAction.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Modified: trunk/test-applications/realworld/ejb/src/main/resources/import.sql
===================================================================
--- trunk/test-applications/realworld/ejb/src/main/resources/import.sql 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/ejb/src/main/resources/import.sql 2009-01-05 16:44:21 UTC (rev 12108)
@@ -38,37 +38,37 @@
INSERT INTO Ranks(rank_id, total, hits) VALUES (30, 100, 30);
INSERT INTO Ranks(rank_id, total, hits) VALUES (31, 110, 31);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (1, 'Aston Martin', 'amarkhel/Cars/aston_martin.jpg', 'Where is the Batman?', '2008-12-18', 1, 1);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (2, 'Ferrari', 'amarkhel/Cars/ferrari_profile.jpg', 'Beauty!', '2008-12-18', 1, 2);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (3, 'Australian supercar', 'amarkhel/Cars/holden-efijy-1809.jpg', 'This one glitters in my garage ;)', '2008-12-18', 1, 3);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (4, 'Hulme Supercar', 'amarkhel/Cars/hulme_supercar_side_parked.jpg', 'Saw it in Germany in summer 2007', '2008-12-18', 1, 4);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (5, 'Pagani Zonda', 'amarkhel/Cars/Pagani_Zonda.jpg', 'The picture is provided by my friend photographer', '2008-12-18', 1, 5);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (6, 'Codatronca (concept)', 'amarkhel/Cars/spadaconcept codatronca.jpg', 'Just concept', '2008-12-18', 1, 6);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (7, 'Unknown supercar', 'amarkhel/Cars/supercar.jpg', 'Tell me it name if you know', '2008-12-18', 1, 7);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (8, 'Audrey Tautou', 'amarkhel/Tetki/Audrey_Tautou.jpg', 'Pretty girl!', '2008-12-18', 2, 8);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (9, 'Juliette Binoche', 'amarkhel/Tetki/Juliette_Binoche.jpg', 'Saw her in "Chocolate" at first', '2008-12-18', 2, 9);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (10, 'Penelope Cruz', 'amarkhel/Tetki/Penelope_Cruz.jpg', 'Without comments', '2008-12-18', 2, 10);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (11, 'Rihanna', 'amarkhel/Tetki/Rihanna.jpg', 'Was born in Barbados. True or false?', '2008-12-18', 2, 11);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (12, 'Uma Turman', 'amarkhel/Tetki/Uma_Turman.jpg', 'Share the delight with Tarantino )', '2008-12-18', 2, 12);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (13, 'Basketball soccer', 'root/Football/Basketball_soccer.jpg', 'They never saw camera', '2008-12-18', 3, 13);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (14, 'bdysch!!!', 'root/Football/bdysch!!!.jpg', 'Dermo sluchaetsia', '2008-12-18', 3, 14);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (15, 'Training', 'root/Football/euro2008_holland_wideweb__470x321,0.jpg', ' ) ', '2008-12-18', 3, 15);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (16, 'Also football', 'root/Football/flag_football.jpg', 'This is also football, but I do not understand it at all', '2008-12-18', 3, 16);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (17, 'Soccer', 'root/Football/soccer.jpg', 'Soccer differs from football', '2008-12-18', 3, 17);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (18, 'from birds fly', 'qqqq/Japan/birds_fly.jpg', 'One of the megalopolices', '2008-12-18', 4, 18);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (19, 'Haruki Murakami', 'qqqq/Japan/Haruki_Murakami.jpg', 'World famous aouthor', '2008-12-18', 4, 19);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (20, 'Street fashion', 'qqqq/Japan/Japanese_Street_Fashion.jpg', 'Venture to walk in such in our streets?', '2008-12-18', 4, 20);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (21, 'Kendo Championship', 'qqqq/Japan/Kendo_Championship_2006.jpg', 'Samurais steel alive!', '2008-12-18', 4, 21);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (22, 'Live in peace', 'qqqq/Japan/live_in_piece.jpg', 'The best place for meditation', '2008-12-18', 4, 22);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (23, 'Modern family', 'qqqq/Japan/modern_japanesse_family.jpg', 'Where is his mother?!', '2008-12-18', 4, 23);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (24, 'Zen garden', 'qqqq/Japan/zen-garden_landscape_design.jpg', 'Fen Shui i vsia fignia', '2008-12-18', 4, 24);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (25, 'Sergei Babkin', 'qqqq/Music/Babkin.jpg', 'Also plays in theatre', '2008-12-18', 5, 25);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (26, 'Bob Marley', 'qqqq/Music/Bob_Marley.jpg', 'Everyone should know him', '2008-12-18', 5, 26);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (27, 'Infected Mushroom', 'qqqq/Music/Infected_Mushroom.jpg', 'Famous psyhedelic trance group from Israel', '2008-12-18', 5, 27);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (28, 'Massive Attack', 'qqqq/Music/massiveAttack.jpg', 'They play theme to "House"', '2008-12-18', 5, 28);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (29, 'Street musician', 'qqqq/Music/StreetMusician.jpg', 'unknown musician', '2008-12-18', 5, 29);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (30, 'SOAD', 'qqqq/Music/system-of-a-down.jpg', 'Try not to loose your innervision!', '2008-12-18', 5, 30);
-INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id) VALUES (31, 'Amon Tobin', 'qqqq/Music/tobin.jpg', 'Brasilian, works in London. Try his "Supermodified2000" album', '2008-12-18', 5, 31);
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (1, 'Aston Martin', 'amarkhel/Cars/aston_martin.jpg', 'Where is the Batman?', '2008-12-18', 1, 1,'Canon S3', 500, 20, 375, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (2, 'Ferrari', 'amarkhel/Cars/ferrari_profile.jpg', 'Beauty!', '2008-12-18', 1, 2,'Canon S3', 500, 37.5, 314, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (3, 'Australian supercar', 'amarkhel/Cars/holden-efijy-1809.jpg', 'This one glitters in my garage ;)', '2008-12-18', 1, 3,'Canon S3', 450, 28.1, 221, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (4, 'Hulme Supercar', 'amarkhel/Cars/hulme_supercar_side_parked.jpg', 'Saw it in Germany in summer 2007', '2008-12-18', 1, 4,'Canon S3', 500, 39.8, 239, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (5, 'Pagani Zonda', 'amarkhel/Cars/Pagani_Zonda.jpg', 'The picture is provided by my friend photographer', '2008-12-18', 1, 5,'Canon S3', 500, 49.6, 338, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (6, 'Codatronca (concept)', 'amarkhel/Cars/spadaconcept codatronca.jpg', 'Just concept', '2008-12-18', 1, 6,'Canon S3', 560, 21.7, 360, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (7, 'Unknown supercar', 'amarkhel/Cars/supercar.jpg', 'Tell me it name if you know', '2008-12-18', 1, 7,'Canon S3', 480, 29.7, 360, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (8, 'Audrey Tautou', 'amarkhel/Tetki/Audrey_Tautou.jpg', 'Pretty girl!', '2008-12-18', 2, 8,'Canon S3', 396, 34.7, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (9, 'Juliette Binoche', 'amarkhel/Tetki/Juliette_Binoche.jpg', 'Saw her in "Chocolate" at first', '2008-12-18', 2, 9,'Canon S3', 400, 44.9, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (10, 'Penelope Cruz', 'amarkhel/Tetki/Penelope_Cruz.jpg', 'Without comments', '2008-12-18', 2, 10,'Canon S3', 500, 41.7, 375, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (11, 'Rihanna', 'amarkhel/Tetki/Rihanna.jpg', 'Was born in Barbados. True or false?', '2008-12-18', 2, 11,'Canon S3', 375, 52.5, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (12, 'Uma Turman', 'amarkhel/Tetki/Uma_Turman.jpg', 'Share the delight with Tarantino )', '2008-12-18', 2, 12,'Canon S3', 368, 40.2, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (13, 'Basketball soccer', 'root/Football/Basketball_soccer.jpg', 'They never saw camera', '2008-12-18', 3, 13,'Canon S3', 500, 33.1, 374, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (14, 'bdysch!!!', 'root/Football/bdysch!!!.jpg', 'Dermo sluchaetsia', '2008-12-18', 3, 14,'Canon S3', 500, 50.4, 333, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (15, 'Training', 'root/Football/euro2008_holland_wideweb__470x321,0.jpg', ' ) ', '2008-12-18', 3, 15,'Canon S3', 470, 37.3, 331, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (16, 'Also football', 'root/Football/flag_football.jpg', 'This is also football, but I do not understand it at all', '2008-12-18', 3, 16,'Canon S3', 500, 24.4, 333, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (17, 'Soccer', 'root/Football/soccer.jpg', 'Soccer differs from football', '2008-12-18', 3, 17,'Canon S3', 350, 45.3, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (18, 'from birds fly', 'qqqq/Japan/birds_fly.jpg', 'One of the megalopolices', '2008-12-18', 4, 18,'Canon S3', 500, 53.4, 375, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (19, 'Haruki Murakami', 'qqqq/Japan/Haruki_Murakami.jpg', 'World famous aouthor', '2008-12-18', 4, 19,'Canon S3', 500, 36, 376, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (20, 'Street fashion', 'qqqq/Japan/Japanese_Street_Fashion.jpg', 'Venture to walk in such in our streets?', '2008-12-18', 4, 20,'Canon S3', 367, 59.2, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (21, 'Kendo Championship', 'qqqq/Japan/Kendo_Championship_2006.jpg', 'Samurais steel alive!', '2008-12-18', 4, 21,'Canon S3', 500, 48.7, 332, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (22, 'Live in peace', 'qqqq/Japan/live_in_piece.jpg', 'The best place for meditation', '2008-12-18', 4, 22,'Canon S3', 500, 42.7, 398, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (23, 'Modern family', 'qqqq/Japan/modern_japanesse_family.jpg', 'Where is his mother?!', '2008-12-18', 4, 23,'Canon S3', 500, 43.1, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (24, 'Zen garden', 'qqqq/Japan/zen-garden_landscape_design.jpg', 'Fen Shui i vsia fignia', '2008-12-18', 4, 24,'Canon S3', 500, 46.1, 375, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (25, 'Sergei Babkin', 'qqqq/Music/Babkin.jpg', 'Also plays in theatre', '2008-12-18', 5, 25,'Canon S3', 525, 59.5, 350, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (26, 'Bob Marley', 'qqqq/Music/Bob_Marley.jpg', 'Everyone should know him', '2008-12-18', 5, 26,'Canon S3', 496, 41.7, 384, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (27, 'Infected Mushroom', 'qqqq/Music/Infected_Mushroom.jpg', 'Famous psyhedelic trance group from Israel', '2008-12-18', 5, 27,'Canon S3', 500, 35.4, 334, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (28, 'Massive Attack', 'qqqq/Music/massiveAttack.jpg', 'They play theme to "House"', '2008-12-18', 5, 28,'Canon S3', 500, 47.4, 377, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (29, 'Street musician', 'qqqq/Music/StreetMusician.jpg', 'unknown musician', '2008-12-18', 5, 29,'Canon S3', 336, 60.5, 500, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (30, 'SOAD', 'qqqq/Music/system-of-a-down.jpg', 'Try not to loose your innervision!', '2008-12-18', 5, 30,'Canon S3', 500, 39.5, 323, '2008-12-01');
+INSERT INTO images(image_id, name, path, description, created, img_album_id, rank_id, cameraModel, height, size, width, uploaded) VALUES (31, 'Amon Tobin', 'qqqq/Music/tobin.jpg', 'Brasilian, works in London. Try his "Supermodified2000" album', '2008-12-18', 5, 31,'Canon S3', 450, 37, 302, '2008-12-01');
INSERT INTO metatags(metatag_id, tag, image_metatag_id) VALUES (1, 'Cool', 1);
INSERT INTO metatags(metatag_id, tag, image_metatag_id) VALUES (2, 'Cool2', 1);
INSERT INTO metatags(metatag_id, tag, image_metatag_id) VALUES (3, 'richfaces', 2);
@@ -97,4 +97,42 @@
INSERT INTO shared_albums(album_id, user_id) VALUES(4, 1);
INSERT INTO shared_albums(album_id, user_id) VALUES(5, 1);
INSERT INTO user_friends(user1_id, user2_id) VALUES(1, 2);
-INSERT INTO friendship_requests(REQUEST_ID, USER_ID, FRIEND_ID) VALUES(1, 3, 1);
\ No newline at end of file
+INSERT INTO friendship_requests(REQUEST_ID, USER_ID, FRIEND_ID) VALUES(1, 3, 1);
+INSERT INTO galleries(GALLERY_ID, name) VALUES (1, 'Fun');
+INSERT INTO galleries(GALLERY_ID, name) VALUES (2, 'Sport');
+INSERT INTO galleries(GALLERY_ID, name) VALUES (3, 'Nature');
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (1, 'Picture1','Fun/img-2e015.jpg' ,'Canon ES3', 'Nick', 1280, 145, 1024, 'Description', '1985-01-08', '2008-21-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (2, 'Picture2', 'Fun/img-9b1c2.jpg','Canon ES3', 'Nick', 1024, 129, 768, 'Description', '1985-01-08', '2008-22-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (3, 'Picture3', 'Fun/img-20d46.jpg','Canon ES3', 'Andrey', 1600, 260, 1200, 'Description', '1985-01-08', '2008-23-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (4, 'Picture4','Fun/img-31c2e.jpg' ,'Canon ES3', 'Ilya', 1280, 169, 1024, 'Description', '1985-01-08', '2008-24-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (5, 'Picture5','Fun/img-69fe6.jpg' ,'Canon ES3', 'Nick', 1280, 102, 1024, 'Description', '1985-01-08', '2008-25-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (6, 'Picture6', 'Fun/img-334ee.jpg','Canon ES3', 'aaa', 1024, 90.9, 768, 'Description', '1985-01-08', '2008-21-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (7, 'Picture7','Fun/img-828dd.jpg' ,'Canon ES3', 'qwazar', 1280, 276, 1024, 'Description', '1985-01-08', '2008-27-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (8, 'Picture8','Fun/img-6537e.jpg' ,'Canon ES3', '', 1600, 338, 1200, 'Description', '1985-01-08', '2008-21-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (9, 'Picture9','Fun/img-7141c.jpg' ,'Canon FS', 'Pit', 1024, 159, 768, 'Description', '1985-01-08', '2008-22-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (10, 'Picture10','Fun/img-25386.jpg' ,'Canon ES3', 'Nick', 1600, 217, 1200, 'Description', '1985-01-08', '2008-21-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (11, 'Picture11','Fun/img-99215.jpg' ,'Canon ES3', 'Andrey', 1024, 74, 768, 'Description', '1985-01-08', '2008-24-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (12, 'Picture12', 'Fun/img-a9307.jpg','Canon ES3', 'aaa', 1680, 197, 1050, 'Description', '1985-01-08', '2008-21-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (13, 'Picture13','Fun/img-b8d37.jpg' ,'Canon ES3-2', 'x-files', 1280, 275, 1024, 'Description', '1985-01-08', '2008-11-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (14, 'Picture14','Fun/img-be1c0.jpg' ,'Canon ES3', 'Nk', 1024, 90.4, 768, 'Description', '1985-01-08', '2008-12-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (15, 'Picture15','Fun/img-cf3ee.jpg' ,'Canon ES3', 'Nickolas', 1024, 97.6, 768, 'Description', '1985-01-08', '2008-22-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (16, 'Picture16','Fun/img-d5ada.jpg' ,'Canon ES3', 'Andr', 1024, 192, 768, 'Description', '1985-01-08', '2008-22-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (17, 'Picture17','Fun/img-d5ed3.jpg' ,'Canon ES3', 'adc', 1024, 213, 768, 'Description', '1985-01-08', '2008-23-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (18, 'Picture18','Fun/img-d966e.jpg' ,'Canon ES3', 'Neeek', 1600, 128, 1200, 'Description', '1985-01-08', '2008-24-11', 1 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (19, 'Picture19','Sport/1.jpg' ,'Canon ES3', 'Potk', 1600, 736, 1200, 'Description', '1985-01-08', '2008-25-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (20, 'Picture20','Sport/2.jpg' ,'Canon ES3', 'aqw', 1280, 229, 1024, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (21, 'Picture100','Sport/3.jpg' ,'Canon ES3', 'ass', 1600, 310, 1200, 'Description', '1985-01-08', '2008-27-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (22, 'Picture101','Sport/4.jpg' ,'Canon ES3', 'www', 1600, 728, 1200, 'Description', '1985-01-08', '2008-29-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (23, 'Picture111','Sport/5.jpg' ,'Canon ES3', 'Nwww', 1280, 251, 1024, 'Description', '1985-01-08', '2008-30-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (24, 'Picture1111','Sport/6.jpg' ,'Canon ES3', 'www', 1280, 278, 1024, 'Description', '1985-01-08', '2008-11-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (25, 'Picture113','Sport/7.jpg' ,'Canon ES3-2', 'Nick', 1600, 689, 1200, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (26, 'Picture1s','Sport/8.jpg' ,'Canon ES3', 'Nick', 1280, 285, 1024, 'Description', '1985-01-08', '2008-14-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (27, 'Picture1sd','Sport/9.jpg' ,'Canon ES3', 'Nick', 1600, 468, 1200, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (28, 'Picture1ssd','Sport/10.jpg' ,'Canon ES3', 'Nick', 1600, 313, 1200, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (29, 'Picture1xd','Sport/11.jpg' ,'Canon ES3', 'Nick', 1600, 214, 1200, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (30, 'Picture1dfd','Sport/12.jpg' ,'Canon ES3', 'Nick', 1280, 336, 1024, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (31, 'Picture1ww','Sport/13.jpg' ,'Canon ES3', 'Nick', 1600, 287, 1200, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (32, 'Picture1weqw','Sport/14.jpg' ,'Canon ES3', 'Nick', 1600, 400,1200, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (33, 'Picture1wdfeqw','Sport/15.jpg' ,'Canon ES3', 'Nick', 1280, 194, 1024, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (34, 'Picture1wseqw','Sport/16.jpg' ,'Canon ES3', 'Nick', 1600, 197, 1200, 'Description', '1985-01-08', '2008-21-11', 2 );
+INSERT INTO galleryImages(GALLERY_IMAGE_ID, name, path, cameraModel, author, height, size, width, description, created, uploaded, IMG_GALLERY_ID) VALUES (35, 'Picture1wddeqw','Sport/17.jpg' ,'Canon ES3', 'Nick', 1280, 87.9, 1024, 'Description', '1985-01-08', '2008-21-11', 2 );
\ No newline at end of file
Modified: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileManager.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileManager.java 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileManager.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -20,11 +20,20 @@
*/
package org.richfaces.realworld.fileupload;
+import java.awt.Graphics2D;
+import java.awt.RenderingHints;
+import java.awt.geom.AffineTransform;
+import java.awt.image.BufferedImage;
+import java.io.ByteArrayInputStream;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
+import java.io.InputStream;
+import java.util.HashMap;
+import java.util.Map;
import javax.faces.context.FacesContext;
+import javax.imageio.ImageIO;
import org.jboss.seam.ScopeType;
import org.jboss.seam.annotations.Name;
@@ -95,10 +104,68 @@
public void addImage(String fileName, byte[] data) throws IOException {
createDirectoryIfNotExist(fileName);
- FileOutputStream b = new FileOutputStream(getUploadRoot() + fileName);
- b.write(data);
- b.close();
+ writeFileTodisk(data, fileName, 0, 0, "" );
+ writeFileTodisk(data, fileName, 50, 50, "_mini" );
+ writeFileTodisk(data, fileName, 600, 400, "_medium" );
+ //FileOutputStream b = new FileOutputStream(getUploadRoot() + fileName);
+ //b.write(data);
+ //b.close();
+ /*InputStream inputStream = new ByteArrayInputStream(data);
+ BufferedImage bsrc = ImageIO.read(inputStream);
+ inputStream = new ByteArrayInputStream(data);
+ bsrc = ImageIO.read(inputStream);
+ ImageIO.write(bsrc, "JPG", new File(getUploadRoot() + fileName));
+ int width = 50;
+ int height = 50;
+ BufferedImage bdest = new BufferedImage(width, height,
+ BufferedImage.TYPE_INT_RGB);
+ Graphics2D g = bdest.createGraphics();
+ AffineTransform at = AffineTransform.getScaleInstance((double) width
+ / bsrc.getWidth(), (double) height / bsrc.getHeight());
+ g.drawRenderedImage(bsrc, at);
+ String dest = getUploadRoot() + transformPath(fileName, "_mini");
+ ImageIO.write(bdest, "JPG", new File(dest));
+ width = 600;
+ height = 400;
+ bdest = new BufferedImage(width, height,
+ BufferedImage.TYPE_INT_RGB);
+ g = bdest.createGraphics();
+ at = AffineTransform.getScaleInstance((double) width
+ / bsrc.getWidth(), (double) height / bsrc.getHeight());
+ g.drawRenderedImage(bsrc, at);
+ dest = getUploadRoot() + transformPath(fileName, "_medium");
+ ImageIO.write(bdest, "JPG", new File(dest));
+ inputStream.close();*/
}
+
+ private void writeFileTodisk(byte[] data, String fileName, int width, int height, String format) throws IOException{
+ InputStream inputStream = new ByteArrayInputStream(data);
+ BufferedImage bsrc = ImageIO.read(inputStream);
+ if(width == 0){
+ String dest = getUploadRoot() + fileName;
+ ImageIO.write(bsrc, "JPG", new File(dest));
+ return;
+ }
+ BufferedImage bdest = new BufferedImage(width, height,
+ BufferedImage.TYPE_INT_RGB);
+ Graphics2D g = bdest.createGraphics();
+ AffineTransform at = AffineTransform.getScaleInstance((double) width
+ / bsrc.getWidth(), (double) height / bsrc.getHeight());
+ Map<RenderingHints.Key, Object> hints = new HashMap<RenderingHints.Key, Object>();
+ hints.put(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BILINEAR);
+ g.addRenderingHints(hints);
+ g.drawRenderedImage(bsrc, at);
+
+ String dest = getUploadRoot() + transformPath(fileName, format);
+ ImageIO.write(bsrc, "JPG", new File(dest));
+ inputStream.close();
+ }
+
+ public String transformPath(String target, String substitute){
+ String begin = target.substring(0, target.lastIndexOf("."));
+ String end = target.substring(target.lastIndexOf("."));
+ return begin + substitute + end;
+ }
public void deleteAllFromDirectory(String directory){
String fullPath = getAbsolutePath(directory);
@@ -119,6 +186,14 @@
if(file.exists()){
file.delete();
}
+ file = new File(transformPath(fullPath, "_mini"));
+ if(file.exists()){
+ file.delete();
+ }
+ file = new File(transformPath(fullPath, "_medium"));
+ if(file.exists()){
+ file.delete();
+ }
}
public void renameImage(String fileNameOld, String fileNameNew) {
@@ -130,6 +205,18 @@
fileNew.delete();
}
fileOld.renameTo(fileNew);
+ fileOld = new File(transformPath(fullPath, "_mini"));
+ fileNew = new File(getAbsolutePath(transformPath(fileNameNew, "_mini")));
+ if(fileNew.exists()){
+ fileNew.delete();
+ }
+ fileOld.renameTo(fileNew);
+ fileOld = new File(transformPath(fullPath, "_medium"));
+ fileNew = new File(getAbsolutePath(transformPath(fileNameNew, "_medium")));
+ if(fileNew.exists()){
+ fileNew.delete();
+ }
+ fileOld.renameTo(fileNew);
}
private void createDirectoryIfNotExist(String fileNameNew) {
Modified: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileUploadBean.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileUploadBean.java 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/FileUploadBean.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -21,7 +21,9 @@
package org.richfaces.realworld.fileupload;
+import java.io.ByteArrayInputStream;
import java.io.IOException;
+import java.io.InputStream;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
@@ -39,6 +41,14 @@
import org.richfaces.realworld.domain.User;
import org.richfaces.realworld.util.SelectionHelper;
+import com.drew.imaging.jpeg.JpegMetadataReader;
+import com.drew.imaging.jpeg.JpegProcessingException;
+import com.drew.metadata.Directory;
+import com.drew.metadata.Metadata;
+import com.drew.metadata.MetadataException;
+import com.drew.metadata.exif.ExifDirectory;
+import com.drew.metadata.jpeg.JpegDirectory;
+
/**
* @author $Autor$
*
@@ -75,13 +85,49 @@
file.setData(item.getData());
file.setSelected(false);
Image image = new Image();
- image.setCreated(new Date());
+ image.setUploaded(new Date());
image.setDescription(SAMPLE_DESCRIPTION);
image.setName(SAMPLE_NAME);
+ image.setSize(file.getLength());
image.setPath(user.getLogin() + "/" + selectionHelper.getSelectedAlbum().getName() + "/" + item.getFileName());
image.setAlbumName(selectionHelper.getSelectedAlbum().getName());
image.setAlbum(selectionHelper.getSelectedAlbum());
- file.setImage(image);
+ try {
+ InputStream in = new ByteArrayInputStream(file.getData());
+ Metadata metadata = JpegMetadataReader.readMetadata(in);
+ Directory exifDirectory = metadata.getDirectory(ExifDirectory.class);
+ Directory jpgDirectory = metadata.getDirectory(JpegDirectory.class);
+
+ if(exifDirectory.containsTag(ExifDirectory.TAG_MODEL)){
+ String cameraModel = exifDirectory.getString(ExifDirectory.TAG_MODEL);
+ image.setCameraModel(cameraModel);
+ }
+ if(exifDirectory.containsTag(ExifDirectory.TAG_EXIF_IMAGE_WIDTH) && exifDirectory.containsTag(ExifDirectory.TAG_EXIF_IMAGE_HEIGHT)){
+ int width = exifDirectory.getInt(ExifDirectory.TAG_EXIF_IMAGE_WIDTH);
+ image.setWidth(width);
+ int height = exifDirectory.getInt(ExifDirectory.TAG_EXIF_IMAGE_HEIGHT);
+ image.setHeight(height);
+ }else{
+ if(jpgDirectory.containsTag(JpegDirectory.TAG_JPEG_IMAGE_HEIGHT)){
+ int width = jpgDirectory.getInt(JpegDirectory.TAG_JPEG_IMAGE_WIDTH);
+ image.setWidth(width);
+ int height = jpgDirectory.getInt(JpegDirectory.TAG_JPEG_IMAGE_HEIGHT);
+ image.setHeight(height);
+ }
+ }
+ if(exifDirectory.containsTag(ExifDirectory.TAG_DATETIME_ORIGINAL)){
+ Date time = exifDirectory.getDate(ExifDirectory.TAG_DATETIME_ORIGINAL);
+ image.setCreated(time);
+ }
+ }
+ catch (JpegProcessingException e1) {
+ // TODO Auto-generated catch block
+ e1.printStackTrace();
+ } catch (MetadataException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ file.setImage(image);
fileWrapper.getFiles().add(file);
}
Modified: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/ImageLoader.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/ImageLoader.java 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/fileupload/ImageLoader.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -53,9 +53,7 @@
FileManager fileManager;
public synchronized void paintSearchImage(OutputStream stream, Object object) throws IOException {
- Image painted = (Image)object;
-
- File image = fileManager.getImage(fileManager.transformToServerPath(painted.getPath()));
+ File image = fileManager.getImage(fileManager.transformToServerPath(object.toString()));
InputStream paintData = null;
byte[] data = new byte[(int)image.length() - 1];
FileInputStream fileInputStream = null;
@@ -101,8 +99,7 @@
if (null == data) {
return;
}
- Image image = (Image)data;
- File imageResource = fileManager.getImage(fileManager.transformToServerPath(image.getPath()));;
+ File imageResource = fileManager.getImage(fileManager.transformToServerPath(data.toString()));;
if (imageResource != null) {
FileInputStream fileInputStream = new FileInputStream(imageResource);
BufferedInputStream bufferedInputStream = new BufferedInputStream(fileInputStream);
@@ -124,6 +121,33 @@
}
}
+ public synchronized void paintGalleryImage(OutputStream out, Object data) throws IOException{
+ if (null == data) {
+ return;
+ }
+ String fileName = fileManager.getFileSeparator() + "galleries" + fileManager.getFileSeparator() + fileManager.transformToServerPath(data.toString());
+ File imageResource = fileManager.getImage(fileName);
+ if (imageResource != null) {
+ FileInputStream fileInputStream = new FileInputStream(imageResource);
+ BufferedInputStream bufferedInputStream = new BufferedInputStream(fileInputStream);
+ InputStream paintData = bufferedInputStream;
+ if (null == paintData) {
+ // throw new Exception("");
+ // TODO
+ }
+ try{
+ BufferedImage images = ImageIO.read(paintData);
+ ImageIO.write(images, JPEG, out);
+ }catch(Exception e){
+
+ }finally{
+ fileInputStream.close();
+ bufferedInputStream.close();
+ paintData.close();
+ }
+ }
+ }
+
public synchronized void paintAvatar(OutputStream out, Object data) throws IOException{
if (null == data) {
return;
Added: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/gallery/GalleryBean.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/gallery/GalleryBean.java (rev 0)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/gallery/GalleryBean.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,214 @@
+package org.richfaces.realworld.gallery;
+
+import java.awt.image.BufferedImage;
+import java.io.ByteArrayInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.Date;
+import java.util.Iterator;
+
+import javax.imageio.ImageIO;
+
+import org.jboss.seam.ScopeType;
+import org.jboss.seam.annotations.In;
+import org.jboss.seam.annotations.Name;
+import org.jboss.seam.annotations.Scope;
+import org.richfaces.event.UploadEvent;
+import org.richfaces.model.UploadItem;
+import org.richfaces.realworld.domain.Gallery;
+import org.richfaces.realworld.domain.GalleryImage;
+import org.richfaces.realworld.fileupload.FileItem;
+import org.richfaces.realworld.fileupload.FileManager;
+import org.richfaces.realworld.service.IGalleryAction;
+
+import com.drew.imaging.jpeg.JpegMetadataReader;
+import com.drew.imaging.jpeg.JpegProcessingException;
+import com.drew.metadata.Directory;
+import com.drew.metadata.Metadata;
+import com.drew.metadata.MetadataException;
+import com.drew.metadata.Tag;
+import com.drew.metadata.exif.ExifDirectory;
+import com.drew.metadata.jpeg.JpegDirectory;
+@Name("galleryBean")
+(a)Scope(ScopeType.CONVERSATION)
+public class GalleryBean {
+
+ public GalleryBean(){
+ selectedGallery = null;
+ }
+ @In(create=true) IGalleryAction galleryAction;
+ @In(create=true) FileManager fileManager;
+ private Gallery selectedGallery;
+
+ private boolean uploadPanelRendered;
+ private boolean galleryPanelRendered;
+ private String author;
+ private String desc;
+ private String name;
+ private String path;
+ private String galleryName;
+
+ private FileItem file;
+
+ public void showUploadPanel(){
+ setUploadPanelRendered(true);
+ author = "";
+ name = "";
+ desc = "";
+ path ="";
+ file = null;
+ }
+
+ public void hideUploadPanel(){
+ setUploadPanelRendered(false);
+ GalleryImage image = new GalleryImage();
+ image.setAuthor(author);
+ image.setDescription(desc);
+ image.setName(name);
+ image.setUploaded(new Date());
+ image.setPath(path);
+ image.setSize(file.getLength());
+ try {
+ InputStream in = new ByteArrayInputStream(file.getData());
+ Metadata metadata = JpegMetadataReader.readMetadata(in);
+ Directory exifDirectory = metadata.getDirectory(ExifDirectory.class);
+ Directory jpgDirectory = metadata.getDirectory(JpegDirectory.class);
+
+ if(exifDirectory.containsTag(ExifDirectory.TAG_MODEL)){
+ String cameraModel = exifDirectory.getString(ExifDirectory.TAG_MODEL);
+ image.setCameraModel(cameraModel);
+ }
+ if(exifDirectory.containsTag(ExifDirectory.TAG_EXIF_IMAGE_WIDTH) && exifDirectory.containsTag(ExifDirectory.TAG_EXIF_IMAGE_HEIGHT)){
+ int width = exifDirectory.getInt(ExifDirectory.TAG_EXIF_IMAGE_WIDTH);
+ image.setWidth(width);
+ int height = exifDirectory.getInt(ExifDirectory.TAG_EXIF_IMAGE_HEIGHT);
+ image.setHeight(height);
+ }else{
+ if(jpgDirectory.containsTag(JpegDirectory.TAG_JPEG_IMAGE_HEIGHT)){
+ int width = jpgDirectory.getInt(JpegDirectory.TAG_JPEG_IMAGE_WIDTH);
+ image.setWidth(width);
+ int height = jpgDirectory.getInt(JpegDirectory.TAG_JPEG_IMAGE_HEIGHT);
+ image.setHeight(height);
+ }
+ }
+ if(exifDirectory.containsTag(ExifDirectory.TAG_DATETIME_ORIGINAL)){
+ Date time = exifDirectory.getDate(ExifDirectory.TAG_DATETIME_ORIGINAL);
+ image.setCreated(time);
+ }
+ }
+ catch (JpegProcessingException e1) {
+ // TODO Auto-generated catch block
+ e1.printStackTrace();
+ } catch (MetadataException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ galleryAction.addImage(selectedGallery, image);
+ try {
+ fileManager.addImage("galleries" + fileManager.getFileSeparator() + path, file.getData());
+ file = null;
+ } catch (IOException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ }
+
+ public void showGalleryPanel(){
+ setGalleryPanelRendered(true);
+ galleryName = "";
+ }
+
+ public void selectGallery(Gallery gal){
+ setSelectedGallery(gal);
+ }
+
+ public void goToGalleryHome(){
+ setSelectedGallery(null);
+ }
+
+ public synchronized void listener(UploadEvent event) throws Exception{
+ UploadItem item = event.getUploadItem();
+ file = new FileItem();
+ file.setLength(item.getData().length);
+ file.setData(item.getData());
+ path = getSelectedGallery().getName() + fileManager.getFileSeparator()+item.getFileName();
+ }
+
+ public void hideGalleryPanel(){
+ setGalleryPanelRendered(false);
+ galleryAction.addGallery(galleryName);
+ fileManager.addDirectory(fileManager.getUploadRoot() + fileManager.getFileSeparator() + "galleries" + fileManager.getFileSeparator()+ galleryName);
+ }
+
+ public Gallery getSelectedGallery() {
+ return selectedGallery;
+ }
+
+ public void setSelectedGallery(Gallery selectedGallery) {
+ this.selectedGallery = selectedGallery;
+ }
+
+ public boolean isUploadPanelRendered() {
+ return uploadPanelRendered;
+ }
+
+ public void setUploadPanelRendered(boolean uploadPanelRendered) {
+ this.uploadPanelRendered = uploadPanelRendered;
+ }
+
+ public boolean isGalleryPanelRendered() {
+ return galleryPanelRendered;
+ }
+
+ public void setGalleryPanelRendered(boolean galleryPanelRendered) {
+ this.galleryPanelRendered = galleryPanelRendered;
+ }
+
+ public String getAuthor() {
+ return author;
+ }
+
+ public void setAuthor(String author) {
+ this.author = author;
+ }
+
+ public String getDesc() {
+ return desc;
+ }
+
+ public void setDesc(String desc) {
+ this.desc = desc;
+ }
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public String getGalleryName() {
+ return galleryName;
+ }
+
+ public void setGalleryName(String galleryName) {
+ this.galleryName = galleryName;
+ }
+
+ public String getPath() {
+ return path;
+ }
+
+ public void setPath(String path) {
+ this.path = path;
+ }
+
+ public FileItem getFile() {
+ return file;
+ }
+
+ public void setFile(FileItem file) {
+ this.file = file;
+ }
+}
Property changes on: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/gallery/GalleryBean.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Modified: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationEnum.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationEnum.java 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationEnum.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -23,5 +23,5 @@
public enum NavigationEnum {
IMAGE_PREVIEW,
FILE_UPLOAD,
- USER_PREFS, SEARCH, READ_MESSAGES,
+ USER_PREFS, SEARCH, READ_MESSAGES, GALLERY,
}
Modified: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationHelper.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationHelper.java 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/navigation/NavigationHelper.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -38,6 +38,10 @@
return NavigationEnum.USER_PREFS;
}
+ public NavigationEnum getNavigationEnumGallery(){
+ return NavigationEnum.GALLERY;
+ }
+
public NavigationEnum getNavigationEnumSearch(){
return NavigationEnum.SEARCH;
}
Added: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/FileHelper.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/FileHelper.java (rev 0)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/FileHelper.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,63 @@
+/**
+ * License Agreement.
+ *
+ * JBoss RichFaces - Ajax4jsf Component Library
+ *
+ * Copyright (C) 2007 Exadel, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+package org.richfaces.realworld.servlet;
+
+import java.io.File;
+
+public class FileHelper {
+
+ private static final String FILE_SEPARATOR = "file.separator";
+ private String uploadRoot;
+
+ public String getUploadRoot() {
+ return uploadRoot;
+ }
+
+ public void setUploadRoot(String uploadRoot) {
+ this.uploadRoot = uploadRoot;
+ }
+
+ public FileHelper(String uploadRoot){
+ this.setUploadRoot(uploadRoot);
+ }
+
+ public String getFileSeparator() {
+ return System.getProperty(FILE_SEPARATOR);
+ }
+
+ public boolean isImagePresent(String fileName) {
+ String fullPath = getAbsolutePath(fileName);
+ File file = new File(fullPath);
+ return file.exists() && !file.isDirectory();
+ }
+
+ public File getImage(String fileName){
+ if(isImagePresent(fileName)){
+ return new File(getAbsolutePath(fileName));
+ }
+ return null;
+ }
+
+ private String getAbsolutePath(String fileName) {
+ return getUploadRoot() + fileName;
+ }
+
+}
Property changes on: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/FileHelper.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Added: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/PictureServlet.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/PictureServlet.java (rev 0)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/PictureServlet.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,110 @@
+package org.richfaces.realworld.servlet;
+
+import java.io.BufferedInputStream;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.Date;
+
+import javax.servlet.ServletContext;
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import com.drew.imaging.jpeg.JpegMetadataReader;
+import com.drew.imaging.jpeg.JpegProcessingException;
+import com.drew.metadata.Directory;
+import com.drew.metadata.Metadata;
+import com.drew.metadata.MetadataException;
+import com.drew.metadata.exif.ExifDirectory;
+
+public class PictureServlet extends javax.servlet.http.HttpServlet {
+
+ public static final long serialVersionUID = 596009789004L;
+ private static final String UPLOAD_ROOT = "uploadRoot";
+
+ protected void doGet(HttpServletRequest request,
+ HttpServletResponse response) throws ServletException, IOException {
+ String pathInfo = request.getPathInfo();
+ String fileName = WebUtil.getFileName(pathInfo);
+ if (fileName == null) {
+ String contextPath = request.getContextPath();
+ response.sendRedirect(contextPath + "/error.seam");
+ return;
+ }
+ ServletContext context = getServletContext();
+ FileHelper helper = new FileHelper(context.getInitParameter(UPLOAD_ROOT));
+ File file = helper.getImage(fileName);
+ /*try {
+ Metadata metadata = JpegMetadataReader.readMetadata(file);
+ Directory exifDirectory = metadata.getDirectory(ExifDirectory.class);
+ if(exifDirectory.containsTag(ExifDirectory.TAG_MODEL)){
+ String cameraModel = exifDirectory.getString(ExifDirectory.TAG_MODEL);
+ System.out.println(cameraModel);
+ }
+ if(exifDirectory.containsTag(ExifDirectory.TAG_EXIF_IMAGE_WIDTH)){
+ int width = exifDirectory.getInt(ExifDirectory.TAG_EXIF_IMAGE_WIDTH);
+ System.out.println(width);
+ }
+ if(exifDirectory.containsTag(ExifDirectory.TAG_EXIF_IMAGE_HEIGHT)){
+ int height = exifDirectory.getInt(ExifDirectory.TAG_EXIF_IMAGE_HEIGHT);
+ System.out.println(height);
+ }
+ if(exifDirectory.containsTag(ExifDirectory.TAG_DATETIME_ORIGINAL)){
+ Date time = exifDirectory.getDate(ExifDirectory.TAG_DATETIME_ORIGINAL);
+ System.out.println(time);
+ }
+ }
+ catch (JpegProcessingException e1) {
+ // TODO Auto-generated catch block
+ e1.printStackTrace();
+ } catch (MetadataException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }*/
+ InputStream paintData = null;
+ byte[] data = new byte[(int) file.length() - 1];
+ FileInputStream fileInputStream = null;
+ BufferedInputStream bufferedInputStream = null;
+ if (file != null) {
+ try {
+ fileInputStream = new FileInputStream(file);
+ bufferedInputStream = new BufferedInputStream(fileInputStream);
+ paintData = bufferedInputStream;
+ paintData.read(data);
+ } catch (FileNotFoundException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ } catch (IOException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ } finally {
+ try {
+ fileInputStream.close();
+ } catch (IOException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ try {
+ bufferedInputStream.close();
+ } catch (IOException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ try {
+ paintData.close();
+ } catch (IOException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ }
+ }
+ response.setContentType("image/jpg");
+ response.setContentLength((int) data.length - 1);
+ response.getOutputStream().write(data);
+ response.getOutputStream().flush();
+ response.getOutputStream().close();
+ }
+}
Property changes on: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/PictureServlet.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Added: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/WebUtil.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/WebUtil.java (rev 0)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/WebUtil.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,33 @@
+package org.richfaces.realworld.servlet;
+
+public class WebUtil {
+
+ public static String getFileName(String path) {
+ // Path format is "/file_name.jpg"
+ if (path != null && path.length() > 1) {
+ String fileName = path.substring(1);
+ int dotIndex = fileName.indexOf('.');
+ String extention = fileName.substring(dotIndex + 1);
+ if (extention.equals(Extention.jpg.getExtention())
+ || extention.equals(Extention.jpeg.getExtention()))
+ {
+ return fileName;
+ }
+ }
+ return null;
+ }
+
+ enum Extention {
+ jpg("jpg"), jpeg("jpeg");
+
+ Extention(String extention) {
+ this.extention = extention;
+ }
+
+ private String extention;
+
+ String getExtention() {
+ return this.extention;
+ }
+ }
+}
\ No newline at end of file
Property changes on: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/servlet/WebUtil.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Added: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/LinkBuilder.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/LinkBuilder.java (rev 0)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/LinkBuilder.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,116 @@
+package org.richfaces.realworld.util;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.faces.context.FacesContext;
+import javax.faces.model.SelectItem;
+import javax.servlet.ServletContext;
+import javax.servlet.ServletRequest;
+
+import org.jboss.seam.ScopeType;
+import org.jboss.seam.annotations.In;
+import org.jboss.seam.annotations.Name;
+import org.jboss.seam.annotations.Scope;
+
+@Name("linkBuilder")
+(a)Scope(ScopeType.CONVERSATION)
+public class LinkBuilder implements Serializable{
+
+ private static final long serialVersionUID = 2561824019376412988L;
+ private static final String MINI_FORMAT = "_mini";
+ private static final String MEDIUM_FORMAT = "_medium";
+ @In("#{messages['small']}") private String SMALL;
+ @In("#{messages['medium']}") private String MEDIUM;
+ @In("#{messages['full']}") private String FULL;
+ private Long scaleChoice = 1L;
+ private String generatedLink;
+ private String currentFormat = URL;
+ private String path;
+ private static String URL = "URL";
+ private static String HTML = "HTML";
+ private static String FORUM = "Forum";
+ private static String HTML_PATTERN = "<a href='%s'><img src='%s' border='0'></a>";
+ private static String FORUM_PATTERN = "[URL=%s][IMG]%s[/IMG][/URL]";
+
+ public String getGeneratedLink() {
+
+ ServletRequest servletRequest = ((ServletRequest)(FacesContext.getCurrentInstance().getExternalContext().getRequest()));
+ ServletContext s = (ServletContext)(FacesContext.getCurrentInstance().getExternalContext().getContext());
+ String protocol = servletRequest.getProtocol().equals("HTTP/1.1") || servletRequest.getProtocol().equals("HTTP/1.0") ? "http://" : "https://" ;
+ String servletPath = protocol + servletRequest.getLocalAddr() + ":" + servletRequest.getLocalPort() + s.getContextPath();
+ String link = null;
+ String tempPath = null;
+ if(getScaleChoice() == 3L){
+ tempPath = MINI_FORMAT;
+ }else if(getScaleChoice() == 2L){
+ tempPath = MEDIUM_FORMAT;
+ }else if(getScaleChoice() == 1L){
+ tempPath="";
+ }
+ if(null == path){
+ return "";
+ }
+ if(getCurrentFormat().equals(URL)){
+ link = servletPath + "/pictures/" + transformPath(path, tempPath);
+ }else
+ if(getCurrentFormat().equals(HTML)){
+ link = String.format(HTML_PATTERN, servletPath, servletPath+ "/pictures/" + transformPath(path, tempPath));
+ }else
+ if(getCurrentFormat().equals(FORUM)){
+ link = String.format(FORUM_PATTERN, servletPath, servletPath+ "/pictures/" + transformPath(path, tempPath));
+ }
+ return link;
+ }
+
+ private String transformPath(String target, String substitute){
+ String begin = target.substring(0, target.lastIndexOf("."));
+ String end = target.substring(target.lastIndexOf("."));
+ return begin + substitute + end;
+ }
+
+ public void setGeneratedLink(String generatedLink) {
+ this.generatedLink = generatedLink;
+ }
+
+ public List<SelectItem> getItems() {
+ List<SelectItem> list = new ArrayList<SelectItem>(4);
+ list.add(new SelectItem(Long.valueOf(1L), FULL));
+ list.add(new SelectItem(Long.valueOf(2L), MEDIUM));
+ list.add(new SelectItem(Long.valueOf(3L), SMALL));
+ return list;
+ }
+
+ public Long getScaleChoice() {
+ return scaleChoice;
+ }
+
+ public void setScaleChoice(Long scaleChoice) {
+ this.scaleChoice = scaleChoice;
+ }
+
+ public void selectFormat(String format){
+ setCurrentFormat(format);
+ }
+
+ public String getCurrentFormat() {
+ return currentFormat;
+ }
+
+ public void setCurrentFormat(String currentFormat) {
+ this.currentFormat = currentFormat;
+ }
+
+ public String getPath() {
+ return path;
+ }
+
+ public void setPath(String path) {
+ this.path = path;
+ }
+
+ public void setScale(Long choice){
+ setScaleChoice(choice);
+ }
+}
Property changes on: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/LinkBuilder.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Added: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/test.java
===================================================================
--- trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/test.java (rev 0)
+++ trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/test.java 2009-01-05 16:44:21 UTC (rev 12108)
@@ -0,0 +1,70 @@
+package org.richfaces.realworld.util;
+
+import java.awt.Graphics2D;
+import java.awt.RenderingHints;
+import java.awt.geom.AffineTransform;
+import java.awt.image.BufferedImage;
+import java.io.ByteArrayInputStream;
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.imageio.ImageIO;
+
+public class test {
+
+ /**
+ * @param args
+ */
+ public static void main(String[] args) {
+ String directory ="C:\\Documents and Settings\\Administrator\\Desktop\\Fun";
+ writeFiles(directory, "_mini", 100, 100);
+ }
+
+ private static void writeFiles(String directory, String pattern, int width, int height) {
+ File f = new File(directory);
+ for(String s: f.list()){
+ File temp = new File(directory +"\\"+ s);
+ if(temp.isDirectory() && !(directory +"\\"+ s).endsWith("avatars")){
+ writeFiles(directory +"\\"+ s,pattern, width, height);
+ }
+ if(s.endsWith(".jpg") && !s.endsWith("_mini.jpg")&& !s.endsWith("_medium.jpg")){
+ BufferedImage bsrc =null;
+ try {
+ bsrc = ImageIO.read(temp);
+ } catch (IOException e1) {
+ // TODO Auto-generated catch block
+ e1.printStackTrace();
+ }
+ BufferedImage bdest = new BufferedImage(width, height,
+ BufferedImage.TYPE_INT_RGB);
+ Graphics2D g = bdest.createGraphics();
+ int width2 = bsrc.getWidth();
+ int height2 = bsrc.getHeight();
+ double d = (double) width
+ / width2;
+ double e = (double) height / height2;
+ AffineTransform at = AffineTransform.getScaleInstance(d, e);
+ Map<RenderingHints.Key, Object> hints = new HashMap<RenderingHints.Key, Object>();
+ hints.put(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BILINEAR);
+ g.addRenderingHints(hints);
+ g.drawRenderedImage(bsrc, at);
+ String dest = transformPath(directory +"\\"+ s, pattern);
+ try {
+ ImageIO.write(bdest, "JPG", new File(dest));
+ } catch (IOException ex) {
+ // TODO Auto-generated catch block
+ ex.printStackTrace();
+ }
+ }
+ }
+ }
+
+ private static String transformPath(String target, String substitute){
+ String begin = target.substring(0, target.lastIndexOf("."));
+ String end = target.substring(target.lastIndexOf("."));
+ return begin + substitute + end;
+ }
+}
Property changes on: trunk/test-applications/realworld/web/src/main/java/org/richfaces/realworld/util/test.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Name: svn:keywords
+ Author Id Revision Date
Name: svn:eol-style
+ native
Modified: trunk/test-applications/realworld/web/src/main/resources/messages_en.properties
===================================================================
--- trunk/test-applications/realworld/web/src/main/resources/messages_en.properties 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/web/src/main/resources/messages_en.properties 2009-01-05 16:44:21 UTC (rev 12108)
@@ -120,20 +120,19 @@
message.authorHeader=Author
message.themeHeader=Theme
message.dateHeader=Date
-message.theme=Theme: #{record.theme}
-message.author=Author:
+message.theme=Theme\:
+message.author=Author\:
message.date=Date: #{record.date}
message.delete=Delete
message.read=Read
message.re=Re:
message.message=Message
-message.owner=Owner:
-message.content=Content:
+message.owner=Owner\:
+message.content=Content\:
message.addFriend=Add to friends
message.friendRequest=It is request for friendship message. You may add this user to your friends by clicking on the 'Add to Friends button'
message.send=Send
message.close=Close
-message.theme=Theme:
confirm.confirm=Confirmation:
confirm.ok=OK
@@ -253,4 +252,7 @@
equals=Equals
more=More
less=Less
-nomatter=No Matter
\ No newline at end of file
+nomatter=No Matter
+small=Small
+medium=Medium
+full=Full size
\ No newline at end of file
Modified: trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/components.xml
===================================================================
--- trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/components.xml 2009-01-05 16:21:28 UTC (rev 12107)
+++ trunk/test-applications/realworld/web/src/main/webapp/WEB-INF/components.xml 2009-01-05 16:44:21 UTC (rev 12108)
@@ -8,8 +8,10 @@
xmlns:mail="http://jboss.com/products/seam/mail"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:transaction="http://jboss.com/products/seam/transaction"
+ xmlns:web="http://jboss.com/products/seam/web"
xsi:schemaLocation=
"http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.1.0.xsd
+ http://jboss.com/products/seam/web http://jboss.com/products/seam/web-2.1.0.xsd
http://jboss.com/products/seam/transaction http://jboss.com/products/seam/transaction-2.1.0.xsd
http://jboss.com/products/seam/persistence http://jboss.com/products/seam/persistence-2.1.0.xsd
http://jboss.com/products/seam/drools http://jboss.com/products/seam/drools-2.1.0.xsd
@@ -18,8 +20,8 @@
http://jboss.com/products/seam/mail http://jboss.com/products/seam/mail-2.1.0.xsd
http://jboss.com/products/seam/components http://jboss.com/products/seam/components-2.1.0.xsd">
- <core:init debug="true" jndi-pattern="@jndiPattern@"/>
-
+ <core:init transaction-management-enabled="false" debug="true" jndi-pattern="@jndiPattern@"/>
+ <web:context-filter url-pattern="/picture/*" />
<core:manager concurrent-request-timeout="20000"
conversation-timeout="120000"
conversation-id-parameter="cid"
Modified: trunk/test-applications/realworld/web/src/main/webapp/img/Thumbs.db
===================================================================
(Binary files differ)
Added: trunk/test-applications/realworld/web/src/main/webapp/includes/fileUpload/fileUploadPanel.xhtml
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/realworld/web/src/main/webapp/includes/fileUpload/fileUploadPanel.xhtml
___________________________________________________________________
Name: svn:mime-type
+ application/xhtml+xml
Modified: trunk/test-applications/realworld/web/src/main/webapp/layout/menu.xhtml
===================================================================
(Binary files differ)
Modified: trunk/test-applications/realworld/web/src/main/webapp/main.xhtml
===================================================================
(Binary files differ)
16 years
JBoss Rich Faces SVN: r12107 - Reports/3.3.0 and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: adubovsky
Date: 2009-01-05 11:21:28 -0500 (Mon, 05 Jan 2009)
New Revision: 12107
Modified:
trunk/test-applications/qa/Test Reports/3.3.0/ComponentsAssignment3.3.0.CR1.xls
Log:
Modified: trunk/test-applications/qa/Test Reports/3.3.0/ComponentsAssignment3.3.0.CR1.xls
===================================================================
(Binary files differ)
16 years
JBoss Rich Faces SVN: r12106 - in trunk/test-applications/regressionArea: regressionArea-ear and 16 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2009-01-05 11:19:55 -0500 (Mon, 05 Jan 2009)
New Revision: 12106
Added:
trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/regressionArea-ds.xml
trunk/test-applications/regressionArea/regressionArea-tests/
trunk/test-applications/regressionArea/regressionArea-tests/pom.xml
trunk/test-applications/regressionArea/regressionArea-tests/src/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/RichSeleniumTest.java
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/SeleniumTestBase.java
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/TestAnnotationTransformer.java
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/SimpleTest.java
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4507/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4507/Test.java
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4709/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4709/Test.java
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf5264/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf5264/Test.java
trunk/test-applications/regressionArea/regressionArea-tests/src/test/resources/
trunk/test-applications/regressionArea/regressionArea-tests/src/test/resources/testng.xml
Removed:
trunk/test-applications/regressionArea/regressionArea-ear/resources/
trunk/test-applications/regressionArea/regressionArea-ear/src/main/resources/seam-ds.xml
Modified:
trunk/test-applications/regressionArea/pom.xml
trunk/test-applications/regressionArea/regressionArea-ear/pom.xml
trunk/test-applications/regressionArea/regressionArea-ejb/pom.xml
trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/META-INF/MANIFEST.MF
trunk/test-applications/regressionArea/regressionArea-web/pom.xml
Log:
Refactor of regressionArea application
Modified: trunk/test-applications/regressionArea/pom.xml
===================================================================
--- trunk/test-applications/regressionArea/pom.xml 2009-01-05 16:19:31 UTC (rev 12105)
+++ trunk/test-applications/regressionArea/pom.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -1,124 +1,125 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <!--parent>
- <groupId>org.richfaces</groupId>
- <artifactId>samples</artifactId>
- <version>3.3.0-SNAPSHOT</version>
- </parent-->
- <groupId>org.richfaces.test-applications</groupId>
- <artifactId>regressionArea</artifactId>
- <packaging>pom</packaging>
- <version>3.3.0-SNAPSHOT</version>
- <name>Regresion Area:Seam Application</name>
- <repositories>
- <repository>
- <releases />
- <snapshots>
- <enabled>false</enabled>
- <updatePolicy>never</updatePolicy>
- </snapshots>
- <id>maven-repository.dev.java.net</id>
- <name>Java.net Repository for Maven</name>
- <url>http://download.java.net/maven/1</url>
- <layout>legacy</layout>
- </repository>
-
- <repository>
- <releases />
- <snapshots>
- <enabled>false</enabled>
- <updatePolicy>never</updatePolicy>
- </snapshots>
- <id>repository.jboss.org</id>
- <url>http://repository.jboss.org/maven2</url>
- </repository>
- <repository>
- <id>openqa</id>
- <name>OpenQA Repository</name>
- <url>http://archiva.openqa.org/repository/releases</url>
- <layout>default</layout>
- <snapshots>
- <enabled>false</enabled>
- </snapshots>
- <releases>
- <enabled>true</enabled>
- </releases>
- </repository>
- <repository>
- <id>openqa-snapshots</id>
- <name>OpenQA Snapshots Repository</name>
- <url>http://archiva.openqa.org/repository/snapshots</url>
- <layout>default</layout>
- <snapshots>
- <enabled>true</enabled>
- </snapshots>
- <releases>
- <enabled>false</enabled>
- </releases>
- </repository>
- </repositories>
-
- <properties>
- <contextroot>regressionArea</contextroot>
- <earname>regressionArea-ear</earname>
- <richversion>3.3.0-SNAPSHOT</richversion>
- <seamversion>2.1.0.SP1</seamversion>
- <jsfversion>1.2_10</jsfversion>
- <jbosshome>C:/tmp/jboss-4.2.3.GA</jbosshome>
- <jbosscontext>default</jbosscontext>
- </properties>
-
-
-
- <modules>
- <module>regressionArea-ejb</module>
- <module>regressionArea-web</module>
- <module>regressionArea-ear</module>
- </modules>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-eclipse-plugin</artifactId>
- <version>2.5</version>
- <configuration>
- <wtpmanifest>true</wtpmanifest>
- <wtpapplicationxml>true</wtpapplicationxml>
- <wtpversion>2.0</wtpversion>
- <manifest>
- ${basedir}/src/main/resources/META-INF/MANIFEST.MF
- </manifest>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-plugin</artifactId>
- <version>2.4</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </configuration>
- </plugin>
-
-
- </plugins>
- </build>
-<!--pluginRepositories>
- <pluginRepository>
- <id>people.apache.org</id>
- <url>http://people.apache.org/repo/m2-snapshot-repository/</url>
- </pluginRepository>
- <pluginRepository>
- <id>repository-int.exadel.com</id>
- <url>http://repository-int.exadel.com/</url>
- </pluginRepository>
- </pluginRepositories-->
-
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <!--parent>
+ <groupId>org.richfaces</groupId>
+ <artifactId>samples</artifactId>
+ <version>3.3.0-SNAPSHOT</version>
+ </parent-->
+ <groupId>org.richfaces.test-applications</groupId>
+ <artifactId>regressionArea</artifactId>
+ <packaging>pom</packaging>
+ <version>3.3.0-SNAPSHOT</version>
+ <name>Regresion Area:Seam Application</name>
+ <repositories>
+ <repository>
+ <releases/>
+ <snapshots>
+ <enabled>false</enabled>
+ <updatePolicy>never</updatePolicy>
+ </snapshots>
+ <id>maven-repository.dev.java.net</id>
+ <name>Java.net Repository for Maven</name>
+ <url>http://download.java.net/maven/1</url>
+ <layout>legacy</layout>
+ </repository>
+
+ <repository>
+ <releases/>
+ <snapshots>
+ <enabled>false</enabled>
+ <updatePolicy>never</updatePolicy>
+ </snapshots>
+ <id>repository.jboss.org</id>
+ <url>http://repository.jboss.org/maven2</url>
+ </repository>
+ <repository>
+ <id>openqa</id>
+ <name>OpenQA Repository</name>
+ <url>http://archiva.openqa.org/repository/releases</url>
+ <layout>default</layout>
+ <snapshots>
+ <enabled>false</enabled>
+ </snapshots>
+ <releases>
+ <enabled>true</enabled>
+ </releases>
+ </repository>
+ <repository>
+ <id>openqa-snapshots</id>
+ <name>OpenQA Snapshots Repository</name>
+ <url>http://archiva.openqa.org/repository/snapshots</url>
+ <layout>default</layout>
+ <snapshots>
+ <enabled>true</enabled>
+ </snapshots>
+ <releases>
+ <enabled>false</enabled>
+ </releases>
+ </repository>
+ </repositories>
+
+ <properties>
+ <contextroot>regressionArea</contextroot>
+ <earname>regressionArea-ear</earname>
+ <richversion>3.3.0-SNAPSHOT</richversion>
+ <seamversion>2.1.0.SP1</seamversion>
+ <jsfversion>1.2_10</jsfversion>
+ <jbosshome>C:/tmp/jboss-4.2.3.GA</jbosshome>
+ <jbosscontext>default</jbosscontext>
+ </properties>
+
+
+
+ <modules>
+ <module>regressionArea-ejb</module>
+ <module>regressionArea-web</module>
+ <module>regressionArea-ear</module>
+ <module>regressionArea-tests</module>
+ </modules>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-eclipse-plugin</artifactId>
+ <version>2.5</version>
+ <configuration>
+ <wtpmanifest>true</wtpmanifest>
+ <wtpapplicationxml>true</wtpapplicationxml>
+ <wtpversion>2.0</wtpversion>
+ <manifest>
+ ${basedir}/src/main/resources/META-INF/MANIFEST.MF
+ </manifest>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.4</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </configuration>
+ </plugin>
+
+
+ </plugins>
+ </build>
+<!--pluginRepositories>
+ <pluginRepository>
+ <id>people.apache.org</id>
+ <url>http://people.apache.org/repo/m2-snapshot-repository/</url>
+ </pluginRepository>
+ <pluginRepository>
+ <id>repository-int.exadel.com</id>
+ <url>http://repository-int.exadel.com/</url>
+ </pluginRepository>
+ </pluginRepositories-->
+
</project>
\ No newline at end of file
Modified: trunk/test-applications/regressionArea/regressionArea-ear/pom.xml
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-ear/pom.xml 2009-01-05 16:19:31 UTC (rev 12105)
+++ trunk/test-applications/regressionArea/regressionArea-ear/pom.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -140,6 +140,65 @@
</modules>
</configuration>
</plugin>
- </plugins>
- </build>
+ <plugin>
+ <groupId>org.codehaus.cargo</groupId>
+ <artifactId>cargo-maven2-plugin</artifactId>
+ <version>1.0-beta-2</version>
+ <executions>
+ <execution>
+ <id>start-container</id>
+ <phase>pre-integration-test</phase>
+ <goals>
+ <goal>deploy</goal>
+ <goal>start</goal>
+ </goals>
+ </execution>
+ <execution>
+ <id>stop-container</id>
+ <phase>post-integration-test</phase>
+ <goals>
+ <goal>stop</goal>
+ <goal>undeploy</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <wait>false</wait>
+ <container>
+ <containerId>jboss4x</containerId>
+ <append>false</append>
+
+ <zipUrlInstaller>
+ <url>file:Y:\Distribs\jboss-4.2.3.GA.zip</url>
+ <installDir>
+ ${project.basedir}/target/installs
+ </installDir>
+ </zipUrlInstaller>
+ </container>
+ <configuration>
+ <home>${jbosshome}/server/${jbosscontext}</home>
+ <type>existing</type>
+ <properties>
+ <cargo.hostname>localhost</cargo.hostname>
+ <cargo.jboss.configuration>${jbosscontext}</cargo.jboss.configuration>
+ <cargo.rmi.port>1099</cargo.rmi.port>
+ </properties>
+ </configuration>
+ <deployer>
+ <type>installed</type>
+ <deployables>
+ <deployable>
+ <artifactId>regressionArea-ear</artifactId>
+ <type>ear</type>
+ </deployable>
+ </deployables>
+ </deployer>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <properties>
+ <jbosshome>${project.basedir}/target/installs/jboss-4.2.3.GA/jboss-4.2.3.GA</jbosshome>
+ </properties>
</project>
Deleted: trunk/test-applications/regressionArea/regressionArea-ear/src/main/resources/seam-ds.xml
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-ear/src/main/resources/seam-ds.xml 2009-01-05 16:19:31 UTC (rev 12105)
+++ trunk/test-applications/regressionArea/regressionArea-ear/src/main/resources/seam-ds.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!DOCTYPE datasources
- PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
- "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
-
-<datasources>
-
- <local-tx-datasource>
- <jndi-name>seamDatasource</jndi-name>
- <connection-url>jdbc:hsqldb:.</connection-url>
- <driver-class>org.hsqldb.jdbcDriver</driver-class>
- <user-name>sa</user-name>
- <password></password>
- </local-tx-datasource>
-
-</datasources>
-
Modified: trunk/test-applications/regressionArea/regressionArea-ejb/pom.xml
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-ejb/pom.xml 2009-01-05 16:19:31 UTC (rev 12105)
+++ trunk/test-applications/regressionArea/regressionArea-ejb/pom.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -174,8 +174,6 @@
<target>1.5</target>
</configuration>
</plugin>
-
-
</plugins>
</build>
Modified: trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/META-INF/MANIFEST.MF
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/META-INF/MANIFEST.MF 2009-01-05 16:19:31 UTC (rev 12105)
+++ trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/META-INF/MANIFEST.MF 2009-01-05 16:19:55 UTC (rev 12106)
@@ -1,10 +1,10 @@
Manifest-Version: 1.0
Class-Path: bsh-1.3.0.jar commons-beanutils-1.7.0.jar commons-collecti
ons-3.2.jar commons-digester-1.8.jar commons-lang-2.3.jar commons-log
- ging-1.0.4.jar dom4j-1.6.1-jboss.jar el-api-1.0.jar javassist-3.3.GA.
- jar jboss-el-2.0.1.GA.jar jboss-seam-2.0.2.SP1.jar jboss-seam-debug-2
- .0.2.SP1.jar jboss-seam-remoting-2.0.2.SP1.jar jboss-seam-ui-2.0.2.SP
- 1.jar jsf-api-1.2_09.jar jsf-facelets-1.1.14.jar jsf-impl-1.2_09.jar
- log4j-1.2.14.jar richfaces-api-3.3.0-SNAPSHOT.jar richfaces-impl-3.3.
- 0-SNAPSHOT.jar richfaces-ui-3.3.0-SNAPSHOT.jar
+ ging-1.0.4.jar dom4j-1.6.1-brew.jar el-api-1.0.jar jboss-el-1.0_02.CR
+ 2.jar jboss-seam-2.1.0.SP1.jar jboss-seam-debug-2.1.0.SP1.jar jboss-s
+ eam-jul-2.1.0.SP1.jar jboss-seam-remoting-2.1.0.SP1.jar jboss-seam-ui
+ -2.1.0.SP1.jar jsf-api-1.2_10.jar jsf-facelets-1.1.15.B1.jar jsf-impl
+ -1.2_10.jar log4j-1.2.14.jar richfaces-api-3.3.0-SNAPSHOT.jar richfac
+ es-impl-3.3.0-SNAPSHOT.jar richfaces-ui-3.3.0-SNAPSHOT.jar
Added: trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/regressionArea-ds.xml
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/regressionArea-ds.xml (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-ejb/src/main/resources/regressionArea-ds.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE datasources
+ PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
+
+<datasources>
+
+ <local-tx-datasource>
+ <jndi-name>seamDatasource</jndi-name>
+ <connection-url>jdbc:hsqldb:.</connection-url>
+ <driver-class>org.hsqldb.jdbcDriver</driver-class>
+ <user-name>sa</user-name>
+ <password></password>
+ </local-tx-datasource>
+
+</datasources>
+
Property changes on: trunk/test-applications/regressionArea/regressionArea-tests
___________________________________________________________________
Name: svn:ignore
+ target
Added: trunk/test-applications/regressionArea/regressionArea-tests/pom.xml
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/pom.xml (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/pom.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,110 @@
+<?xml version="1.0"?><project>
+ <parent>
+ <artifactId>regressionArea</artifactId>
+ <groupId>org.richfaces.test-applications</groupId>
+ <version>3.3.0-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.richfaces.test-applications.regressionArea</groupId>
+ <artifactId>regressionArea-tests</artifactId>
+ <packaging>jar</packaging>
+ <name>Regression Area Tests</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.testng</groupId>
+ <artifactId>testng</artifactId>
+ <version>5.8</version>
+ <scope>test</scope>
+ <type>pom</type>
+ </dependency>
+ <dependency>
+ <groupId>org.testng</groupId>
+ <artifactId>testng</artifactId>
+ <version>5.8</version>
+ <scope>test</scope>
+ <classifier>jdk15</classifier>
+ </dependency>
+ <dependency>
+ <groupId>org.richfaces.framework</groupId>
+ <artifactId>richfaces-api</artifactId>
+ <version>${richversion}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.richfaces.framework</groupId>
+ <artifactId>richfaces-impl</artifactId>
+ <version>${richversion}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.richfaces.ui</groupId>
+ <artifactId>richfaces-ui</artifactId>
+ <version>${richversion}</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.faces</groupId>
+ <artifactId>jsf-api</artifactId>
+ <version>1.2_11</version>
+ <scope>provided</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>org.openqa.selenium.client-drivers</groupId>
+ <artifactId>selenium-java-client-driver</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.openqa.selenium.server</groupId>
+ <artifactId>selenium-server-coreless</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>jetty</groupId>
+ <artifactId>org.mortbay.jetty</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.4.3</version>
+ <configuration>
+
+ <!-- Skip the normal tests, we'll run them in the integration-test phase -->
+ <skip>true</skip>
+
+ <suiteXmlFiles>
+ <suiteXmlFile>
+ src/test/resources/testng.xml
+ </suiteXmlFile>
+ </suiteXmlFiles>
+ </configuration>
+ <executions>
+ <execution>
+ <phase>integration-test</phase>
+ <goals>
+ <goal>test</goal>
+ </goals>
+ <configuration>
+ <skip>false</skip>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
\ No newline at end of file
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/RichSeleniumTest.java
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/RichSeleniumTest.java (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/RichSeleniumTest.java 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,11 @@
+package org.richfaces;
+
+public interface RichSeleniumTest {
+
+ public void startSelenium(String browser, String filterPrefix);
+
+ public void stopSelenium();
+
+ public String getTestUrl();
+
+}
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/SeleniumTestBase.java
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/SeleniumTestBase.java (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/SeleniumTestBase.java 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,834 @@
+package org.richfaces;
+
+
+
+import org.ajax4jsf.javascript.JSFunction;
+import org.ajax4jsf.javascript.ScriptUtils;
+import org.openqa.selenium.server.RemoteControlConfiguration;
+import org.openqa.selenium.server.SeleniumServer;
+import org.testng.Assert;
+import org.testng.annotations.AfterClass;
+import org.testng.annotations.AfterSuite;
+import org.testng.annotations.BeforeClass;
+import org.testng.annotations.BeforeSuite;
+import org.testng.annotations.Parameters;
+
+import com.thoughtworks.selenium.DefaultSelenium;
+
+/**
+ * The base java class for selenium tests implementation.
+ *
+ * @author Andrey Markavtsov
+ *
+ */
+public abstract class SeleniumTestBase implements RichSeleniumTest {
+
+ /** Specifies the time to wait for page rendering */
+ private static final Integer pageRenderTime = 5000;
+
+ /** Specifies the time to wait for ajax processing */
+ protected static final int ajaxCompletionTime = 3000;
+
+ protected static final String serverPort = "8080";
+
+ protected static final String WINDOW_JS_RESOLVER = "selenium.browserbot.getCurrentWindow().";
+
+ /** Parent component id */
+ private String parentId;
+
+ /** The default selenium instance */
+ public DefaultSelenium selenium;
+
+ /** Host */
+ public String host;
+
+ /** Port */
+ public String port;
+
+ /** Protocol */
+ public String protocol;
+
+ private String filterPrefix;
+
+ private SeleniumServer seleniumServer;
+
+ private Object[][] data;
+
+ private int seleniumServerPort = 5556;
+
+ /** Defines the name of current j2ee application name */
+ public static final String APPLICATION_NAME = "regressionArea";
+
+ public SeleniumTestBase() {
+ this("http", "localhost", serverPort);
+ }
+
+ public SeleniumTestBase(String protocol, String host, String port) {
+ this.host = host;
+ this.port = port;
+ this.protocol = protocol;
+ }
+
+ @BeforeSuite
+ public void startSeleniumServer() throws Exception {
+ RemoteControlConfiguration config = new RemoteControlConfiguration();
+ config.setMultiWindow(false);
+ config.setPort(seleniumServerPort);
+ seleniumServer = new SeleniumServer(false, config);
+ seleniumServer.start();
+ }
+
+ //@DataProvider(name = "templates")
+// protected Object[][] templates() {
+// return new Object[][] { { Template.SIMPLE }, { Template.DATA_TABLE }, { Template.MODAL_PANEL } };
+// //return this.data;
+// }
+
+ /**
+ * This method are invoked before selenium tests started
+ */
+ @BeforeClass
+ @Parameters({"browser", "filterPrefix"})
+ public void startSelenium(String browser, String filterPrefix) {
+ synchronized (MUTEX) {
+ this.filterPrefix = filterPrefix;
+ selenium = createSeleniumClient(protocol + "://" + host + ":" + port + "/", browser);
+ selenium.start();
+ selenium.allowNativeXpath("false");
+ }
+ }
+
+ /**
+ * This method are invoked after selenium tests completed
+ */
+ @AfterClass(alwaysRun=true)
+ public void stopSelenium() {
+ synchronized (MUTEX) {
+ selenium.stop();
+ selenium = null;
+ }
+ }
+
+// protected void loadTemplates(String templateExpr) {
+// String[] array = new String[]{};
+// if(null != templateExpr) {
+// array = templateExpr.split(",");
+// }
+//
+// List<Object[]> list = new ArrayList<Object[]>();
+// for (String string : array) {
+// Object[] elem = new Object[] {Template.valueOf(string)};
+// list.add(elem);
+// }
+//
+// this.data = (Object[][]) list.toArray(new Object[0][0]);
+// }
+
+ @AfterSuite
+ public void stopSeleniumServer() throws Exception {
+ seleniumServer.stop();
+ }
+
+ /**
+ * @param url
+ * @param browser
+ * @return
+ */
+ private DefaultSelenium createSeleniumClient(String url, String browser) {
+ return new DefaultSelenium(host, seleniumServerPort, browser, url);
+ }
+
+ private static final Object MUTEX = new Object();
+
+ /**
+ * Renders page
+ */
+ protected void renderPage() {
+ selenium.open(protocol + "://" + host + ":" + port + "/" + APPLICATION_NAME + filterPrefix + getTestUrl());
+ selenium.waitForPageToLoad(String.valueOf(pageRenderTime));
+
+ //setParentId(template.getPrefix());
+ //runScript("loadTemplate('" + template + "');", false);
+ //waitForPageToLoad();
+
+ checkPageRendering(); // At the first we check if page has been
+ // rendered
+ checkJSError(); // At the second we check if JS errors occurred
+
+ reRenderForm(); // ReRender component
+
+ checkPageRendering(); // Check all again
+ checkJSError();
+
+ }
+
+ /**
+ * Writes status message on client side
+ *
+ * @param message
+ */
+ public void writeStatus(String message, boolean isError) {
+ message = message.replace("'", "\\'");
+ StringBuffer buffer = new StringBuffer("writeStatus('");
+ buffer.append(message);
+ if (!isError) {
+ buffer.append("')");
+ }else {
+ buffer.append("',true)");
+ }
+ runScript(buffer.toString());
+ }
+
+ /**
+ * Writes status message on client side
+ *
+ * @param message
+ */
+ public void writeStatus(String message) {
+ writeStatus(message, false);
+ }
+
+ /**
+ * ReRenders the component
+ */
+ public void reRenderForm() {
+ selenium.getEval("selenium.browserbot.getCurrentWindow().reRenderAll();");
+ // clickById("_Selenium_Test_ReRender_Form:_reRender");
+ waitForAjaxCompletion(3000);
+ }
+
+ /**
+ * Performs script defined in parameter
+ *
+ * @param script
+ * @return
+ */
+ public String runScript(String script) {
+ String result = selenium.getEval(WINDOW_JS_RESOLVER + script);
+ checkJSError();
+ return result;
+ }
+
+ /**
+ * Performs script defined in parameter
+ *
+ * @param script
+ * @return
+ */
+ public String runScript(String script, boolean checkEerror) {
+ String result = selenium.getEval(WINDOW_JS_RESOLVER + script);
+ if (checkEerror) {
+ checkJSError();
+ }
+ return result;
+ }
+
+ /**
+ * Checks if JS error occurred. Fails test if yes. This method should be
+ * invoked after each event or any thing which can be a cause of JS error.
+ */
+ public void checkJSError() {
+ String error = selenium.getEval(WINDOW_JS_RESOLVER + "checkError();");
+ if (error != null && !("null".equals(error)) && !("".equals(error))) {
+ Assert.fail("Failure by the following Javascript error: " + error);
+ }
+ }
+
+ /**
+ * Checks if page containing component test has been rendered completely
+ */
+ public void checkPageRendering() {
+ try {
+ String t1 = getTextById("_Selenium_Test_ControlPoint1");
+ String t2 = getTextById("_Selenium_Test_ControlPoint2");
+ if (t1 == null || t2 == null || !"Control1".equals(t1) || !"Control2".equals(t2)) {
+ Assert.fail("The page has been not rendered properlly");
+ }
+ } catch (Exception e) {
+ Assert.fail("The page has not been rendered properly due the following error: " + e);
+ }
+ }
+
+ /**
+ * Waits while AJAX request will be completed
+ *
+ * @param miliseconds -
+ * time to wait
+ */
+ public void waitForAjaxCompletion(int miliseconds) {
+ selenium.waitForCondition(WINDOW_JS_RESOLVER + "done==true", String.valueOf(miliseconds));
+ runScript("window.done=false");
+ }
+
+ /**
+ * Waits while AJAX request will be completed
+ *
+ * @param miliseconds -
+ * time to wait
+ */
+ public void waitForAjaxCompletion() {
+ waitForAjaxCompletion(ajaxCompletionTime);
+ }
+
+ /**
+ * Waits while simple request will be completed
+ *
+ * @param miliseconds -
+ * time to wait
+ */
+ public void waitForPageToLoad(int miliseconds) {
+ selenium.waitForPageToLoad(String.valueOf(miliseconds));
+ }
+
+ /**
+ * Waits for condition
+ *
+ * @param condition
+ * @param miliseconds
+ */
+ public void waiteForCondition(String condition, int miliseconds) {
+ selenium.waitForCondition(WINDOW_JS_RESOLVER + condition, String.valueOf(miliseconds));
+ checkJSError();
+ }
+
+ /**
+ * Waits while simple request will be completed
+ *
+ */
+ public void waitForPageToLoad() {
+ selenium.waitForPageToLoad(String.valueOf(pageRenderTime));
+ }
+
+ /**
+ * Asserts DOM node value equals to value defined
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * value defined
+ */
+ public void AssertValueEquals(String id, String value) {
+ String _v = getValueById(id);
+ Assert.assertEquals(_v, value);
+ }
+
+ /**
+ * Asserts DOM node value equals to value defined
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * value defined
+ * @param message = message to be displayed in failure case
+ */
+ public void AssertValueEquals(String id, String value, String message) {
+ String _v = getValueById(id);
+ Assert.assertEquals(_v, value, message);
+ }
+
+ /**
+ * Asserts DOM node value does not equal to value defined
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * value defined
+ */
+ public void AssertValueNotEquals(String id, String value) {
+ String _v = getValueById(id);
+ Assert.assertNotSame(_v, value);
+ }
+
+
+ /**
+ * Asserts DOM node value does not equal to value defined
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * value defined
+ * @param message = message to be displayed in failure case
+ */
+ public void AssertValueNotEquals(String id, String value, String message) {
+ String _v = getValueById(id);
+ Assert.assertNotSame(_v, value, message);
+ }
+
+
+ /**
+ * Asserts DOM node text equals to text defined
+ *
+ * @param locator -
+ * locator an element locator
+ * @param value -
+ * text defined
+ */
+ public void AssertTextEquals(String locator, String value) {
+ String _v = selenium.getText(locator);
+ Assert.assertEquals(_v, value);
+ }
+
+ /**
+ * Asserts DOM node text equals to text defined
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * text defined
+ * @param message = message to be displayed in failure case
+ */
+ public void AssertTextEquals(String id, String value, String message) {
+ String _v = getTextById(id);
+ Assert.assertEquals(_v, value, message);
+ }
+
+
+ /**
+ * Asserts DOM node text does not equal to text defined
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * text defined
+ */
+ public void AssertTextNotEquals(String id, String value) {
+ String _v = getTextById(id);
+ Assert.assertNotSame(_v, value);
+ }
+
+ /**
+ * Asserts DOM node text does not equal to text defined
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * text defined
+ * @param message = message to be displayed in failure case
+ */
+ public void AssertTextNotEquals(String id, String value, String message) {
+ String _v = getTextById(id);
+ Assert.assertNotSame(_v, value, message);
+ }
+
+ /**
+ * Asserts DOM node is visible
+ *
+ * @param id -
+ * DOM element id
+ */
+ public void AssertVisible(String id) {
+ Assert.assertTrue(isVisibleById(id));
+ }
+
+ /**
+ * Asserts DOM node is not present
+ *
+ * @param id -
+ * DOM element id
+ */
+ public void AssertNotPresent(String id) {
+ Assert.assertFalse(isPresentById(id));
+ }
+
+ /**
+ * Asserts DOM node is not visible
+ *
+ * @param id -
+ * DOM element id
+ */
+ public void AssertNotVisible(String id) {
+ Assert.assertFalse(isVisibleById(id));
+ }
+
+ /**
+ * Asserts DOM node is present
+ *
+ * @param id -
+ * DOM element id
+ */
+ public void AssertPresent(String id) {
+ Assert.assertTrue(isPresentById(id));
+ }
+
+ /**
+ * Asserts DOM node is present
+ * @param id - DOM element id
+ */
+ public void AssertRendered(String id) {
+ if (!isPresentById(id)) {
+ Assert.fail("Component " + id + " should be rendered on page");
+ }
+ }
+
+ /**
+ * Asserts DOM node is not present
+ * @param id - DOM element id
+ */
+ public void AssertNotRendered(String id) {
+ if (isPresentById(id)) {
+ Assert.fail("Component " + id + " should not be rendered on page");
+ }
+ }
+
+ /**
+ * Returns element's text
+ *
+ * @param id -
+ * DOM element id
+ * @return
+ */
+ public String getTextById(String id) {
+ return selenium.getText("id=" + id);
+ }
+
+ /**
+ * Returns element's value
+ *
+ * @param id -
+ * DOM element id
+ * @return
+ */
+ public String getValueById(String id) {
+ return selenium.getValue("id=" + id);
+ }
+
+ /**
+ * Sets a new value for DOM node with specified id.
+ *
+ * @param id -
+ * DOM element id
+ * @param value -
+ * a new DOM element's value
+ */
+ public void setValueById(String id, String value) {
+ runScript(String.format("document.getElementById('%1$s').value='%2$s';", id, value));
+ }
+
+ /**
+ * Returns element's width
+ *
+ * @param id -
+ * DOM element id
+ * @return
+ */
+ public Number getWidthById(String id) {
+ return selenium.getElementWidth("id=" + id);
+ }
+
+ /**
+ * Returns element's height
+ *
+ * @param id -
+ * DOM element id
+ * @return
+ */
+ public Number getHeightById(String id) {
+ return selenium.getElementHeight("id=" + id);
+ }
+
+ /**
+ * Clicks on element
+ *
+ * @param id -
+ * DOM element id
+ * @return
+ */
+ public void clickById(String id) {
+ selenium.click("id=" + id);
+ checkJSError();
+ }
+
+ /**
+ * Clicks an ajax command and wait for ajax request completion.
+ * @param locator an element locator
+ */
+ public void clickAjaxCommandAndWait(String locator) {
+ selenium.click(locator);
+ waitForAjaxCompletion();
+ }
+
+ /**
+ * This method should be used for click on command controls instead of
+ * 'clickById' method.
+ *
+ * @param commandId
+ */
+ public void clickCommandAndWait(String commandId) {
+ selenium.click("id=" + commandId);
+ waitForPageToLoad();
+ }
+
+ /**
+ * Return true if element is visible
+ *
+ * @param id -
+ * DOM element id
+ * @return
+ */
+ public boolean isVisibleById(String id) {
+ return selenium.isVisible("id=" + id);
+ }
+
+ /**
+ * Returns true if element with given id is present.
+ *
+ * @param id -
+ * DOM element id
+ * @return true if element with given id is present, otherwise - false
+ */
+ public boolean isPresentById(String id) {
+ return selenium.isElementPresent("id=" + id);
+ }
+
+ /**
+ * Invokes JS method on client.
+ *
+ * @param id -
+ * DOM id of component
+ * @param method -
+ * string method name
+ * @param parameters -
+ * parameters
+ * @return
+ */
+ public String invokeFromComponent(String id, String method, Object parameters) {
+ String _return = null;
+ StringBuffer buffer = new StringBuffer();
+ buffer.append("$('");
+ buffer.append(id);
+ buffer.append("').component.");
+ buffer.append(method);
+ buffer.append("(");
+ buffer.append(ScriptUtils.toScript(parameters));
+ buffer.append(");");
+ _return = runScript(buffer.toString());
+ return _return;
+ }
+
+ /**
+ * Creates delay
+ *
+ * @param miliSeconds
+ * @throws InterruptedException
+ */
+ public void delay(int miliSeconds) {
+ try {
+ Thread.sleep(miliSeconds);
+ } catch (Exception e) {
+
+ }
+ }
+
+ /**
+ * Creates pause for defined time in miliSeconds
+ *
+ * @param miliSeconds
+ */
+ public void pause(int miliSeconds, String id) {
+ StringBuffer script = new StringBuffer("pause(");
+ script.append(miliSeconds);
+ script.append(",'");
+ script.append(id);
+ script.append("');");
+ runScript(script.toString());
+ selenium.waitForCondition(WINDOW_JS_RESOLVER + "pauseHolder['" + id + "'] == true;", String
+ .valueOf(miliSeconds + 1000));
+ }
+
+ /**
+ * @return the parentId
+ */
+ public String getParentId() {
+ return parentId;
+ }
+
+ /**
+ * @param parentId
+ * the parentId to set
+ */
+ public void setParentId(String parentId) {
+ this.parentId = parentId;
+ }
+
+ /**
+ * Workaround for selenium.type/selenium.typeKeys
+ * @param locator
+ * @param string
+ */
+ public void type(String locator, String string) {
+ selenium.type(locator, "");
+ StringBuffer value = new StringBuffer(selenium.getValue(locator));
+ char[] chars = string.toCharArray();
+ for (int i = 0; i < chars.length; i++) {
+ String key = Character.toString(chars[i]);
+ value.append(key);
+
+ selenium.keyDown(locator, key);
+
+ if(!isFF()) {
+ selenium.type(locator, value.toString());
+ }
+
+ selenium.keyPress(locator, key);
+ selenium.keyUp(locator, key);
+
+ }
+ }
+
+ public void testOnclickEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onclick event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.click(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnDblclickEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing ondblclick event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.doubleClick(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnfocusEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onfocus event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.focus(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnkeydownEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onkeydown event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.keyDown(testElementId, "1");
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnkeypressEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onkeypress event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.keyPress(testElementId, "1");
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnkeyupEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onkeyup event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.keyUp(testElementId, "1");
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnmousedownEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onmousedown event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.mouseDown(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnmousemoveEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onmousemove event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.mouseMove(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnmouseoutEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onmouseout event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.mouseOut(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnmouseoverEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onmouseover event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.mouseOver(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ public void testOnmouseupEvent(String testElementId, String testElementResultId, String beforeResult, String afterResult) {
+ writeStatus("Testing onmouseup event");
+ AssertTextEquals(testElementResultId, beforeResult);
+ selenium.mouseUp(testElementId);
+ AssertTextEquals(testElementResultId, afterResult);
+ }
+
+ /**
+ * Method to assert element style attribute with expected
+ * @param elementId - tested element id
+ * @param expectedExpression - expected style attribute
+ */
+ public void assertStyleAttribute(String elementId, String expectedExpression) {
+ String styleAttribute = selenium.getAttribute("//*[@id='" + elementId + "']/@style");
+ if (!styleAttribute.toLowerCase().contains(expectedExpression.toLowerCase())) {
+ Assert.fail("Element '" + elementId + "' with style '" + styleAttribute + "' doesn't contain '" + expectedExpression + "'");
+ }
+ }
+
+ /**
+ * Asserts that expected columns count equals actual one.
+ * @param i the expected columns count
+ * @param tableId id of table to be checked
+ */
+ public void assertColumnsCount(int i, String tableId) {
+ StringBuffer script = new StringBuffer("$('");
+ script.append(tableId);
+ script.append("').rows[0].cells.length");
+
+ String count = runScript(script.toString());
+ Assert.assertEquals(count, String.valueOf(i));
+ }
+
+ /**
+ * Asserts that expected rows count equals actual one.
+ * @param i the expected rows count
+ * @param tableId id of table to be checked
+ */
+ public void assertRowsCount(int i, String tableId) {
+ int count = selenium.getXpathCount("//table[@id='" + tableId + "']/tbody/tr").intValue();
+ Assert.assertEquals(count, i);
+ }
+
+ /**
+ * Checks whether client is FireFox
+ *
+ * @return true if client is FireFox
+ */
+ public boolean isFF() {
+ return new Boolean(selenium.getEval("navigator.userAgent.indexOf('Firefox') > -1"));
+ }
+
+ /**
+ * Returns the url to test page to be opened by selenium
+ *
+ * @return
+ */
+ public abstract String getTestUrl();
+
+ /**
+ * Simulates mouse event for element
+ * @param id - Element ID
+ * @param eventName - Mouse event Name
+ * @param x - X mouse position
+ * @param y - Y mouse position
+ * @return - Event
+ */
+ public String fireMouseEvent(String id, String eventName, int x, int y, boolean ctrl) {
+ return runScript("fireMouseEvent('" + id + "','" + eventName + "', "
+ + x + "," + y + ","+ctrl+");");
+ }
+
+ /**
+ * Calls component JS API
+ *
+ * @param id - Client id of the component to call operation on
+ * @param function - JS function representing operation that should be called
+ * @return - Result of execution
+ */
+ public String callComponentOperation(String id, JSFunction function) {
+ StringBuffer command = new StringBuffer();
+ new JSFunction("document.getElementById", id).appendScript(command);
+ command.append(".component.");
+ function.appendScript(command);
+ return runScript(command.toString());
+ }
+}
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/TestAnnotationTransformer.java
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/TestAnnotationTransformer.java (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/TestAnnotationTransformer.java 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,28 @@
+package org.richfaces;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.Method;
+
+import org.testng.internal.annotations.IAnnotationTransformer;
+import org.testng.internal.annotations.ITest;
+import org.testng.internal.annotations.TestAnnotation;
+
+/**
+ * This transformer sets necessary data provider for each test method.
+ *
+ * @author carcasser
+ */
+public class TestAnnotationTransformer implements IAnnotationTransformer {
+
+ /**
+ * @see IAnnotationTransformer#transform(ITest, Class, Constructor, Method)
+ */
+ public void transform(ITest annotation, Class testClass, Constructor testConstructor, Method testMethod) {
+
+ if ((testClass == null || RichSeleniumTest.class.isAssignableFrom(testClass))
+ && (annotation instanceof TestAnnotation)) {
+ ((TestAnnotation) annotation).setDataProvider("templates");
+ }
+ }
+
+}
\ No newline at end of file
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/SimpleTest.java
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/SimpleTest.java (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/SimpleTest.java 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,26 @@
+package org.richfaces.testng;
+
+import org.richfaces.SeleniumTestBase;
+import org.testng.annotations.Test;
+
+public class SimpleTest extends SeleniumTestBase {
+
+ @Test
+ public void testXHTML() {
+ renderPage();
+
+ }
+
+ @Test
+ public void testJSP() {
+ selenium.open("http://localhost:" + serverPort + "/" + APPLICATION_NAME + "/faces/NEKO/pages/examples/home.jsp");
+ waitForPageToLoad();
+
+ }
+
+ @Override
+ public String getTestUrl() {
+ return "pages/examples/home.xhtml";
+ }
+
+}
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4507/Test.java
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4507/Test.java (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4507/Test.java 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,58 @@
+package org.richfaces.testng.rf4507;
+
+import org.richfaces.SeleniumTestBase;
+import org.testng.Assert;
+
+public class Test extends SeleniumTestBase {
+
+ private String getIdSelector(String id) {
+ return "//*[@id='" + id + "']";
+ }
+
+ private void testCalendarSwitch(int buttonPosition, String cellText) {
+ renderPage();
+
+ AssertTextEquals(getIdSelector("form:calendarDayCell6") + "/div", "5-10");
+
+ selenium.assignId(getIdSelector("form:calendarHeader") + "//td[*[@class='rich-calendar-tool-btn']][" + buttonPosition + "]/div", "testButton");
+ fireMouseEvent("testButton", "click", 0, 0, false);
+ waitForAjaxCompletion();
+
+ AssertTextEquals(getIdSelector( "form:calendarDayCell6") + "/div", cellText);
+ }
+
+ private void testLink(String linkId, String data) throws Exception {
+ renderPage();
+
+ Assert.assertEquals("null", selenium.getEval("window.receivedData"));
+
+ clickAjaxCommandAndWait(getIdSelector(linkId));
+
+ Assert.assertEquals(data, selenium.getEval("window.receivedData"));
+ }
+
+ @org.testng.annotations.Test
+ public void testNextMonth() throws Exception {
+ testCalendarSwitch(4, "2-11");
+ }
+
+ @org.testng.annotations.Test
+ public void testPreviousMonth() throws Exception {
+ testCalendarSwitch(2, "7-9");
+ }
+
+ @org.testng.annotations.Test
+ public void testFirstLink() throws Exception {
+ testLink("form:link1", "firstLink");
+ }
+
+ @org.testng.annotations.Test
+ public void testSecondLink() throws Exception {
+ testLink("form:link2", "secondLink");
+ }
+
+ public String getTestUrl() {
+ return "pages/rf4507.xhtml";
+ }
+
+}
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4709/Test.java
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4709/Test.java (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf4709/Test.java 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,53 @@
+package org.richfaces.testng.rf4709;
+
+import org.richfaces.SeleniumTestBase;
+
+public class Test extends SeleniumTestBase {
+
+ private String getMessagesLocator() {
+ return "//*[@id='" + "messages']";
+ }
+
+ @org.testng.annotations.Test
+ public void testTabPanel() throws Exception {
+ renderPage();
+
+ AssertTextEquals(getMessagesLocator(), "");
+
+ selenium.assignId("//*[@id='form:secondTab_lbl']", "testElement");
+ fireMouseEvent("testElement", "click", 0, 0, false);
+ waitForAjaxCompletion();
+
+ AssertTextEquals(getMessagesLocator(), "tabPanel");
+ }
+
+ @org.testng.annotations.Test
+ public void testTogglePanel() throws Exception {
+ renderPage();
+
+ AssertTextEquals(getMessagesLocator(), "");
+
+ selenium.click("//*[@id='form:firstControl']");
+ waitForAjaxCompletion();
+
+ AssertTextEquals(getMessagesLocator(), "togglePanel");
+ }
+
+ @org.testng.annotations.Test
+ public void testPanelBar() throws Exception {
+ renderPage();
+
+ AssertTextEquals(getMessagesLocator(), "");
+ selenium.assignId("//*[@id='form:secondPanelBarItem']/div[1]", "testElement");
+ fireMouseEvent("testElement", "click", 0, 0, false);
+ waitForAjaxCompletion();
+
+ AssertTextEquals(getMessagesLocator(), "panelBar");
+ }
+
+ @Override
+ public String getTestUrl() {
+ return "pages/rf4709.xhtml";
+ }
+
+}
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf5264/Test.java
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf5264/Test.java (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/java/org/richfaces/testng/rf5264/Test.java 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,74 @@
+/**
+ * License Agreement.
+ *
+ * Rich Faces - Natural Ajax for Java Server Faces (JSF)
+ *
+ * Copyright (C) 2007 Exadel, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+
+package org.richfaces.testng.rf5264;
+
+import org.ajax4jsf.javascript.JSFunction;
+import org.richfaces.SeleniumTestBase;
+
+/**
+ * @author Nick Belaevski
+ * @since 3.3.0
+ */
+public class Test extends SeleniumTestBase {
+
+ private static final String PROGRESS_BAR_ID = "form:progressBar";
+ private static final String PROGRESS_BAR_TEST_ELEMENT_ID = PROGRESS_BAR_ID + ":upload";
+
+ private static final String PROGRESS_BAR_INITIAL_ELEMENT_ID = PROGRESS_BAR_ID + ":initialState";
+ private static final String PROGRESS_BAR_COMPLETE_ELEMENT_ID = PROGRESS_BAR_ID + ":completeState";
+
+ @org.testng.annotations.Test
+ public void testBeyondMinimum() throws Exception {
+ renderPage();
+
+ assertStyleAttribute(PROGRESS_BAR_TEST_ELEMENT_ID, "width: 50%;");
+ AssertNotVisible(PROGRESS_BAR_INITIAL_ELEMENT_ID);
+ AssertNotVisible(PROGRESS_BAR_COMPLETE_ELEMENT_ID);
+
+ callComponentOperation(PROGRESS_BAR_ID, new JSFunction("setValue", 0));
+ AssertVisible(PROGRESS_BAR_INITIAL_ELEMENT_ID);
+ AssertNotVisible(PROGRESS_BAR_COMPLETE_ELEMENT_ID);
+ AssertNotVisible(PROGRESS_BAR_TEST_ELEMENT_ID);
+ }
+
+ @org.testng.annotations.Test
+ public void testAboveMaximum() throws Exception {
+ renderPage();
+
+ assertStyleAttribute(PROGRESS_BAR_TEST_ELEMENT_ID, "width: 50%;");
+ AssertNotVisible(PROGRESS_BAR_INITIAL_ELEMENT_ID);
+ AssertNotVisible(PROGRESS_BAR_COMPLETE_ELEMENT_ID);
+
+ callComponentOperation(PROGRESS_BAR_ID, new JSFunction("setValue", 1000));
+ AssertVisible(PROGRESS_BAR_COMPLETE_ELEMENT_ID);
+ AssertNotVisible(PROGRESS_BAR_INITIAL_ELEMENT_ID);
+ AssertNotVisible(PROGRESS_BAR_TEST_ELEMENT_ID);
+ }
+
+ @Override
+ public String getTestUrl() {
+ return "pages/rf5264.xhtml";
+ }
+
+
+}
Added: trunk/test-applications/regressionArea/regressionArea-tests/src/test/resources/testng.xml
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-tests/src/test/resources/testng.xml (rev 0)
+++ trunk/test-applications/regressionArea/regressionArea-tests/src/test/resources/testng.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -0,0 +1,27 @@
+<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
+<suite name="seleniumTestDANe">
+ <!--test name="IEFunctionalTests">
+ <parameter name="browser" value="*iexplore"/>
+ <parameter name="loadStyleStrategy" value="DEFAULT"/>
+ <parameter name="loadScriptStrategy" value="ALL"/>
+ <parameter name="filterPrefix" value="/faces/NEKO/"/>
+ <packages>
+ <package name="org.richfaces.testng" />
+ <package name="org.richfaces.testng.rf4507" />
+ <package name="org.richfaces.testng.rf4709" />
+ <package name="org.richfaces.testng.rf5264" />
+ </packages>
+ </test-->
+ <test name="FireFoxFunctionalTestsDANe">
+ <parameter name="loadStyleStrategy" value="DEFAULT"/>
+ <parameter name="loadScriptStrategy" value="ALL"/>
+ <parameter name="filterPrefix" value="/faces/NEKO/"/>
+ <parameter name="browser" value="*firefox"/>
+ <packages>
+ <package name="org.richfaces.testng" />
+ <package name="org.richfaces.testng.rf4507" />
+ <package name="org.richfaces.testng.rf4709" />
+ <package name="org.richfaces.testng.rf5264" />
+ </packages>
+ </test>
+</suite>
Modified: trunk/test-applications/regressionArea/regressionArea-web/pom.xml
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-web/pom.xml 2009-01-05 16:19:31 UTC (rev 12105)
+++ trunk/test-applications/regressionArea/regressionArea-web/pom.xml 2009-01-05 16:19:55 UTC (rev 12106)
@@ -38,10 +38,10 @@
<artifactId>richfaces-ui</artifactId>
<version>${richversion}</version>
</dependency>
- <dependency>
- <groupId>org.richfaces.test-applications.regressionArea</groupId>
- <artifactId>regressionArea-ejb</artifactId>
- <version>${project.version}</version>
+ <dependency>
+ <groupId>javax.faces</groupId>
+ <artifactId>jsf-api</artifactId>
+ <version>1.2_11</version>
<scope>provided</scope>
</dependency>
<dependency>
@@ -131,7 +131,7 @@
<build>
<plugins>
- <plugin>
+ <!-- plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
@@ -148,7 +148,7 @@
</execution>
</executions>
</plugin>
- <plugin>
+ <plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<version>0.3.1</version>
@@ -195,7 +195,7 @@
</deployables>
</deployer>
</configuration>
- </plugin>
+ </plugin -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
16 years
JBoss Rich Faces SVN: r12105 - in trunk/test-applications/regressionArea/regressionArea-web/src: main/resources/META-INF and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2009-01-05 11:19:31 -0500 (Mon, 05 Jan 2009)
New Revision: 12105
Removed:
trunk/test-applications/regressionArea/regressionArea-web/src/test/
Modified:
trunk/test-applications/regressionArea/regressionArea-web/src/main/resources/META-INF/MANIFEST.MF
Log:
Refactor of regressionArea application
Modified: trunk/test-applications/regressionArea/regressionArea-web/src/main/resources/META-INF/MANIFEST.MF
===================================================================
--- trunk/test-applications/regressionArea/regressionArea-web/src/main/resources/META-INF/MANIFEST.MF 2009-01-05 16:19:22 UTC (rev 12104)
+++ trunk/test-applications/regressionArea/regressionArea-web/src/main/resources/META-INF/MANIFEST.MF 2009-01-05 16:19:31 UTC (rev 12105)
@@ -1,6 +1,6 @@
Manifest-Version: 1.0
-Class-Path: commons-beanutils-1.7.0.jar commons-collections-3.2.jar co
- mmons-digester-1.8.jar jsf-facelets-1.1.14.jar richfaces-api-3.3.0-SN
- APSHOT.jar richfaces-impl-3.3.0-SNAPSHOT.jar richfaces-ui-3.3.0-SNAPS
- HOT.jar
+Class-Path: avalon-framework-4.1.3.jar commons-beanutils-1.7.0.jar com
+ mons-digester-1.8.jar commons-logging-1.1.jar jsf-facelets-1.1.14.jar
+ log4j-1.2.14.jar logkit-1.0.1.jar richfaces-impl-3.3.0-SNAPSHOT.jar
+ richfaces-ui-3.3.0-SNAPSHOT.jar servlet-api-2.4.jar
16 years
JBoss Rich Faces SVN: r12104 - Reports/3.3.0 and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: tkuprevich
Date: 2009-01-05 11:19:22 -0500 (Mon, 05 Jan 2009)
New Revision: 12104
Modified:
trunk/test-applications/qa/Test Reports/3.3.0/ComponentsAssignment3.3.0.CR2.xls
Log:
Modified: trunk/test-applications/qa/Test Reports/3.3.0/ComponentsAssignment3.3.0.CR2.xls
===================================================================
(Binary files differ)
16 years
JBoss Rich Faces SVN: r12103 - trunk/test-applications/seleniumTest/richfaces/src/test/testng/hudson.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2009-01-05 11:03:40 -0500 (Mon, 05 Jan 2009)
New Revision: 12103
Modified:
trunk/test-applications/seleniumTest/richfaces/src/test/testng/hudson/testng.xml
Log:
Hudson test configuration
Modified: trunk/test-applications/seleniumTest/richfaces/src/test/testng/hudson/testng.xml
===================================================================
--- trunk/test-applications/seleniumTest/richfaces/src/test/testng/hudson/testng.xml 2009-01-05 15:58:44 UTC (rev 12102)
+++ trunk/test-applications/seleniumTest/richfaces/src/test/testng/hudson/testng.xml 2009-01-05 16:03:40 UTC (rev 12103)
@@ -5,107 +5,107 @@
<parameter name="loadStyleStrategy" value="ALL"/>
<parameter name="loadScriptStrategy" value="ALL"/>
<parameter name="filterPrefix" value="/faces/NEKO/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test-->
<test name="all_all_none">
<parameter name="browser" value="*firefox"/>
<parameter name="loadStyleStrategy" value="ALL"/>
<parameter name="loadScriptStrategy" value="ALL"/>
<parameter name="filterPrefix" value="/faces/NONE/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<!--test name="all_all_tidy">
<parameter name="loadStyleStrategy" value="ALL"/>
<parameter name="loadScriptStrategy" value="ALL"/>
<parameter name="filterPrefix" value="/faces/TIDY/"/>
<parameter name="browser" value="*firefox"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="all_default_neko">
<parameter name="browser" value="*firefox"/>
<parameter name="loadStyleStrategy" value="ALL"/>
<parameter name="loadScriptStrategy" value="DEFAULT"/>
<parameter name="filterPrefix" value="/faces/NEKO/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="all_default_none">
<parameter name="browser" value="*firefox"/>
<parameter name="loadStyleStrategy" value="ALL"/>
<parameter name="loadScriptStrategy" value="DEFAULT"/>
<parameter name="filterPrefix" value="/faces/NONE/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="all_default_tidy">
<parameter name="loadStyleStrategy" value="ALL"/>
<parameter name="loadScriptStrategy" value="DEFAULT"/>
<parameter name="filterPrefix" value="/faces/TIDY/"/>
<parameter name="browser" value="*firefox"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="default_all_neko">
<parameter name="browser" value="*firefox"/>
<parameter name="loadStyleStrategy" value="DEFAULT"/>
<parameter name="loadScriptStrategy" value="ALL"/>
<parameter name="filterPrefix" value="/faces/NEKO/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="default_all_none">
<parameter name="browser" value="*firefox"/>
<parameter name="loadStyleStrategy" value="DEFAULT"/>
<parameter name="loadScriptStrategy" value="ALL"/>
<parameter name="filterPrefix" value="/faces/NONE/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="default_all_tidy">
<parameter name="loadStyleStrategy" value="DEFAULT"/>
<parameter name="loadScriptStrategy" value="ALL"/>
<parameter name="filterPrefix" value="/faces/TIDY/"/>
<parameter name="browser" value="*firefox"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test-->
<test name="default_default_neko">
<parameter name="browser" value="*firefox"/>
<parameter name="loadStyleStrategy" value="DEFAULT"/>
<parameter name="loadScriptStrategy" value="DEFAULT"/>
<parameter name="filterPrefix" value="/faces/NEKO/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="default_default_none">
<parameter name="browser" value="*firefox"/>
<parameter name="loadStyleStrategy" value="DEFAULT"/>
<parameter name="loadScriptStrategy" value="DEFAULT"/>
<parameter name="filterPrefix" value="/faces/NONE/"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
<test name="default_default_tidy">
<parameter name="loadStyleStrategy" value="DEFAULT"/>
<parameter name="loadScriptStrategy" value="DEFAULT"/>
<parameter name="filterPrefix" value="/faces/TIDY/"/>
<parameter name="browser" value="*firefox"/>
- <packages>
- <package name="org.richfaces.testng" />
- </packages>
+ <classes>
+ <class name="org.richfaces.testng.DataScrollerTest" />
+ </classes>
</test>
</suite>
16 years
JBoss Rich Faces SVN: r12102 - Reports/3.3.0 and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: tkuprevich
Date: 2009-01-05 10:58:44 -0500 (Mon, 05 Jan 2009)
New Revision: 12102
Added:
trunk/test-applications/qa/Test Reports/3.3.0/ComponentsAssignment3.3.0.CR2.xls
Log:
Added: trunk/test-applications/qa/Test Reports/3.3.0/ComponentsAssignment3.3.0.CR2.xls
===================================================================
(Binary files differ)
Property changes on: trunk/test-applications/qa/Test Reports/3.3.0/ComponentsAssignment3.3.0.CR2.xls
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
16 years
JBoss Rich Faces SVN: r12101 - trunk/ui/tree/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2009-01-05 10:33:09 -0500 (Mon, 05 Jan 2009)
New Revision: 12101
Modified:
trunk/ui/tree/src/main/resources/org/richfaces/renderkit/html/scripts/tree-item.js
Log:
https://jira.jboss.org/jira/browse/RF-5503
https://jira.jboss.org/jira/browse/RF-5499
Modified: trunk/ui/tree/src/main/resources/org/richfaces/renderkit/html/scripts/tree-item.js
===================================================================
--- trunk/ui/tree/src/main/resources/org/richfaces/renderkit/html/scripts/tree-item.js 2009-01-05 15:32:50 UTC (rev 12100)
+++ trunk/ui/tree/src/main/resources/org/richfaces/renderkit/html/scripts/tree-item.js 2009-01-05 15:33:09 UTC (rev 12101)
@@ -182,13 +182,18 @@
},
destroy: function() {
- this.elements = undefined;
-
- //TODO remove check
if (this.parent) {
this.parent.removeChild(this);
}
+ if (this.elements) {
+ //free circular reference.
+ //
+ //TODO: contents of this.elements collection can still be used after item destruction,
+ //free them in future
+ this.elements.itemElement = undefined;
+ }
+
this.clearChildren();
if (this == this.tree.selectionManager.activeItem) {
@@ -252,7 +257,13 @@
props[Richfaces.TreeExpandEvent] = true;
props["expandedNode"] = this.id;
props["treeItem"] = this;
- Richfaces.createEvent("click", this.tree.element, null, props).fire();
+
+ var event = Richfaces.createEvent("click", this.tree.element, null, props);
+ try {
+ event.fire();
+ } finally {
+ event.destroy();
+ }
},
fireCollapsionEvent: function() {
@@ -260,7 +271,13 @@
props[Richfaces.TreeCollapseEvent] = true;
props["collapsedNode"] = this.id;
props["treeItem"] = this;
- Richfaces.createEvent("click", this.tree.element, null, props).fire();
+
+ var event = Richfaces.createEvent("click", this.tree.element, null, props);
+ try {
+ event.fire();
+ } finally {
+ event.destroy();
+ }
},
toggleCollapsion: function() {
@@ -425,8 +442,13 @@
props["originatingEventType"] = e.type;
props["treeItem"] = this;
props["selectedNode"] = this.id;
+
var evt = Richfaces.createEvent("click", this.tree.element, null, props);
- evt.fire();
+ try {
+ evt.fire();
+ } finally {
+ evt.destroy();
+ }
return !evt.event["cancelSelection"];
} else {
16 years