You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(4) |
Nov
(39) |
Dec
(10) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(19) |
Feb
(150) |
Mar
(10) |
Apr
|
May
(8) |
Jun
(11) |
Jul
(27) |
Aug
(52) |
Sep
(35) |
Oct
(30) |
Nov
(18) |
Dec
(4) |
2008 |
Jan
(76) |
Feb
(121) |
Mar
(39) |
Apr
(55) |
May
(18) |
Jun
(49) |
Jul
(32) |
Aug
(4) |
Sep
(10) |
Oct
|
Nov
(3) |
Dec
(33) |
2009 |
Jan
(19) |
Feb
(87) |
Mar
(69) |
Apr
(38) |
May
(47) |
Jun
(20) |
Jul
(5) |
Aug
(76) |
Sep
(145) |
Oct
(34) |
Nov
(8) |
Dec
(68) |
2010 |
Jan
(150) |
Feb
(379) |
Mar
(191) |
Apr
(100) |
May
(525) |
Jun
(269) |
Jul
(127) |
Aug
(190) |
Sep
(190) |
Oct
(29) |
Nov
(147) |
Dec
(83) |
2011 |
Jan
(188) |
Feb
(81) |
Mar
(43) |
Apr
(97) |
May
(63) |
Jun
(129) |
Jul
(17) |
Aug
(124) |
Sep
(6) |
Oct
(20) |
Nov
(67) |
Dec
(23) |
2012 |
Jan
(6) |
Feb
(14) |
Mar
(181) |
Apr
(64) |
May
(102) |
Jun
(47) |
Jul
(26) |
Aug
(3) |
Sep
(1) |
Oct
(14) |
Nov
(13) |
Dec
(23) |
2013 |
Jan
(4) |
Feb
(14) |
Mar
(18) |
Apr
(14) |
May
(27) |
Jun
(27) |
Jul
(5) |
Aug
(2) |
Sep
(74) |
Oct
(79) |
Nov
(21) |
Dec
(97) |
2014 |
Jan
(6) |
Feb
(3) |
Mar
(8) |
Apr
|
May
(5) |
Jun
|
Jul
(9) |
Aug
(6) |
Sep
(3) |
Oct
(10) |
Nov
(6) |
Dec
|
2015 |
Jan
|
Feb
|
Mar
(1) |
Apr
(25) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2016 |
Jan
|
Feb
|
Mar
|
Apr
(5) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <fg...@us...> - 2011-12-01 17:51:18
|
Revision: 3720 http://openutils.svn.sourceforge.net/openutils/?rev=3720&view=rev Author: fgiust Date: 2011-12-01 17:51:12 +0000 (Thu, 01 Dec 2011) Log Message: ----------- fix check on repository name Modified Paths: -------------- trunk/openutils-mgnlutils/src/main/java/it/openutils/mgnlutils/templating/ExtendedTemplate.java Modified: trunk/openutils-mgnlutils/src/main/java/it/openutils/mgnlutils/templating/ExtendedTemplate.java =================================================================== --- trunk/openutils-mgnlutils/src/main/java/it/openutils/mgnlutils/templating/ExtendedTemplate.java 2011-12-01 10:06:26 UTC (rev 3719) +++ trunk/openutils-mgnlutils/src/main/java/it/openutils/mgnlutils/templating/ExtendedTemplate.java 2011-12-01 17:51:12 UTC (rev 3720) @@ -168,7 +168,7 @@ { try { - if (repositories.contains(node.getWorkspace())) + if (repositories.contains(node.getWorkspace().getName())) { return true; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <hu...@op...> - 2011-12-01 10:58:08
|
See <https://hudson.openmindonline.it/job/openutils-bshd5/49/changes> |
From: <hu...@op...> - 2011-12-01 10:58:07
|
See <https://hudson.openmindonline.it/job/openutils-bshd5/net.sourceforge.openutils$openutils-bshd5/49/changes> |
From: <gca...@us...> - 2011-12-01 10:06:38
|
Revision: 3719 http://openutils.svn.sourceforge.net/openutils/?rev=3719&view=rev Author: gcatania Date: 2011-12-01 10:06:26 +0000 (Thu, 01 Dec 2011) Log Message: ----------- BSHD-2 reinstated id generation annotations Modified Paths: -------------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java 2011-12-01 09:11:33 UTC (rev 3718) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java 2011-12-01 10:06:26 UTC (rev 3719) @@ -27,6 +27,8 @@ import javax.persistence.Column; import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; import javax.persistence.Id; @@ -38,6 +40,7 @@ { @Id + @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @Column(nullable = false, length = 50) Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java 2011-12-01 09:11:33 UTC (rev 3718) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java 2011-12-01 10:06:26 UTC (rev 3719) @@ -29,6 +29,8 @@ import javax.persistence.Column; import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.ManyToOne; @@ -41,6 +43,7 @@ { @Id + @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @ManyToOne Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java 2011-12-01 09:11:33 UTC (rev 3718) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java 2011-12-01 10:06:26 UTC (rev 3719) @@ -29,6 +29,8 @@ import javax.persistence.Column; import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.OneToMany; @@ -41,6 +43,7 @@ { @Id + @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @Column Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java 2011-12-01 09:11:33 UTC (rev 3718) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java 2011-12-01 10:06:26 UTC (rev 3719) @@ -27,6 +27,8 @@ import javax.persistence.Column; import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.ManyToOne; @@ -39,6 +41,7 @@ { @Id + @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @ManyToOne Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-12-01 09:11:33 UTC (rev 3718) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-12-01 10:06:26 UTC (rev 3719) @@ -33,6 +33,8 @@ import javax.persistence.Embedded; import javax.persistence.Entity; import javax.persistence.FetchType; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.Inheritance; import javax.persistence.InheritanceType; @@ -49,6 +51,7 @@ { @Id + @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @Embedded This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <hu...@op...> - 2011-12-01 09:57:15
|
See <https://hudson.openmindonline.it/job/openutils-bshd5/net.sourceforge.openutils$openutils-bshd5/48/changes> |
From: <hu...@op...> - 2011-12-01 09:57:15
|
See <https://hudson.openmindonline.it/job/openutils-bshd5/48/changes> |
From: <gca...@us...> - 2011-12-01 09:11:43
|
Revision: 3718 http://openutils.svn.sourceforge.net/openutils/?rev=3718&view=rev Author: gcatania Date: 2011-12-01 09:11:33 +0000 (Thu, 01 Dec 2011) Log Message: ----------- adding testng output to svn:ignores Property Changed: ---------------- trunk/openutils-bshd5/ Property changes on: trunk/openutils-bshd5 ___________________________________________________________________ Modified: svn:ignore - .wtpmodules target .classpath .project .settings .checkstyle + .wtpmodules target .classpath .project .settings .checkstyle test-output This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <gca...@us...> - 2011-12-01 09:11:02
|
Revision: 3717 http://openutils.svn.sourceforge.net/openutils/?rev=3717&view=rev Author: gcatania Date: 2011-12-01 09:10:56 +0000 (Thu, 01 Dec 2011) Log Message: ----------- BSHD-2 adding unit test, fixing meaningfulness of existing ones Modified Paths: -------------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java 2011-12-01 09:10:37 UTC (rev 3716) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java 2011-12-01 09:10:56 UTC (rev 3717) @@ -32,10 +32,12 @@ import it.openutils.hibernate.test.model.CarMaker; import it.openutils.hibernate.test.model.CarModel; import it.openutils.hibernate.test.model.CurrencyAmount; +import it.openutils.hibernate.test.model.Designer; import it.openutils.hibernate.test.model.FullName; import it.openutils.hibernate.test.model.Owner; import it.openutils.hibernate.test.model.Person; +import java.util.ArrayList; import java.util.Calendar; import java.util.Collections; import java.util.GregorianCalendar; @@ -67,7 +69,7 @@ @Autowired private CarDAO carDAO; - private Person alice() + private static Person alice() { FullName fullName = new FullName("Alice", "McBeal"); Calendar birthDate = new GregorianCalendar(1970, Calendar.MARCH, 7); @@ -80,7 +82,7 @@ return p; } - private Owner bob() + private static Owner bob() { FullName fullName = new FullName("Bob", "Kelso"); Calendar birthDate = new GregorianCalendar(1950, Calendar.MARCH, 7); @@ -93,7 +95,7 @@ return o; } - private Owner chuck() + private static Owner chuck() { FullName fullName = new FullName("Chuck", "Palahniuk"); Calendar birthDate = new GregorianCalendar(1962, Calendar.FEBRUARY, 21); @@ -106,11 +108,53 @@ return p; } + private static CarMaker toyota() + { + CarMaker toyota = new CarMaker(); + toyota.setName("Toyota"); + toyota.setCapitalization(new CurrencyAmount(12000, "YEN")); + return toyota; + } + + private static CarModel prius(CarMaker toyota) + { + CarModel prius = new CarModel(); + prius.setName("Prius"); + prius.setYear(Integer.valueOf(2008)); + + List<CarModel> toyotaModels = toyota.getModels(); + if (toyotaModels == null) + { + toyotaModels = new ArrayList<CarModel>(); + } + toyotaModels.add(prius); + toyota.setModels(toyotaModels); + return prius; + } + + private static Designer priusDesigner(CarModel prius) + { + FullName fullName = new FullName("Ken", "Shiro"); + Calendar birthDate = new GregorianCalendar(1981, Calendar.OCTOBER, 16); + Address address = new Address("Khan avenue", 6, "Nagato", "TK", 99867); + Designer p = new Designer(); + p.setName(fullName); + p.setBirthDate(birthDate); + p.setFiscalAddress(address); + p.setCurrentAddress(address); + p.setDepartment("design"); + p.setEmployer(prius.getMake()); + p.setDesignedModels(Collections.singleton(prius)); + p.setGrossAnnualSalary(new CurrencyAmount(60000, "YEN")); + p.setHipsterFactor(97); + return p; + } + /** * basic save/evict/get test. */ @Test - public void testSaveAndRetrievePerson() + public void testSaveAndRetrieveBasic() { Person person = alice(); Long savedId = personDAO.save(person); @@ -122,11 +166,32 @@ Assert.assertEquals(person, savedPerson); } + /* + * java.lang.ClassCastException: it.openutils.hibernate.test.model.Person_$$_javassist_7 cannot be cast to + * it.openutils.hibernate.test.model.Designer + */ + @Test(enabled = false) + public void testSaveAndRetrieveWithCascade() + { + CarMaker toyota = toyota(); + CarModel prius = prius(toyota); + Designer designer = priusDesigner(prius); + + Long designerId = personDAO.save(designer); + + personDAO.evict(designer); + Person reloadedDesigner = personDAO.load(designerId); + Designer rd = (Designer) reloadedDesigner; + Assert.assertEquals(rd.getHipsterFactor(), 97); + Assert.assertEquals(rd.getDesignedModels().iterator().next().getYear(), Integer.valueOf(2008)); + } + @Test - public void testFindFilteredFirst() + public void testBasicFind() { Person alice = alice(); personDAO.save(alice); + Person filter = new Person(); filter.setName(new FullName(null, "McBeal")); List<Person> found = personDAO.findFiltered(filter); @@ -136,12 +201,46 @@ } @Test + public void testFindFiltered() + { + personDAO.save(alice()); + personDAO.save(bob()); + personDAO.save(chuck()); + Person filter = new Person(); + filter.setName(new FullName(null, "Kelso")); + List<Person> found = personDAO.findFiltered(filter); + + Assert.assertEquals(found.size(), 1, "Invalid number of persons found."); + Person actualBob = bob(); + Person expectedBob = found.get(0); + Assert.assertEquals(expectedBob.getName(), actualBob.getName()); + Assert.assertEquals(expectedBob.getCurrentAddress().getStreet(), actualBob.getCurrentAddress().getStreet()); + Assert.assertEquals(expectedBob.getBirthDate(), actualBob.getBirthDate()); + } + + @Test + public void testFindFilteredInheritance() + { + personDAO.save(alice()); + personDAO.save(bob()); + personDAO.save(chuck()); + Person filter = new Person(); + filter.setName(new FullName(null, "Kelso")); + List<Person> found = personDAO.findFiltered(filter); + + Assert.assertEquals(found.size(), 1, "Invalid number of persons found."); + Person expectedBob = found.get(0); + Assert.assertEquals(expectedBob.getClass(), Owner.class, "Inheritanche check failed"); + } + + @Test(enabled = false) public void testFindFilteredById() { Person alice = alice(); - Long savedId = personDAO.save(alice); + Long alicesId = personDAO.save(alice); + personDAO.save(bob()); Person filter = new Person(); - filter.setId(savedId); + filter.setId(alicesId); List<Person> found = personDAO.findFiltered(filter); Assert.assertEquals(found.size(), 1, "No persons found."); @@ -157,13 +256,8 @@ public void testFindFilteredByChildId() { Owner bob = bob(); - CarMaker toyota = new CarMaker(); - toyota.setName("Toyota"); - toyota.setCapitalization(new CurrencyAmount(12000, "YEN")); - CarModel prius = new CarModel(); - prius.setName("Prius"); - prius.setYear(Integer.valueOf(2008)); - toyota.setModels(Collections.singletonList(prius)); + CarMaker toyota = toyota(); + CarModel prius = prius(toyota); Car bobsPrius = new Car(new GregorianCalendar(2010, Calendar.OCTOBER, 12), prius, toyota); bob.setCars(Collections.singleton(bobsPrius)); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <gca...@us...> - 2011-12-01 09:10:46
|
Revision: 3716 http://openutils.svn.sourceforge.net/openutils/?rev=3716&view=rev Author: gcatania Date: 2011-12-01 09:10:37 +0000 (Thu, 01 Dec 2011) Log Message: ----------- BSHD-2 cleanup test model objects Modified Paths: -------------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java 2011-12-01 08:34:48 UTC (rev 3715) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java 2011-12-01 09:10:37 UTC (rev 3716) @@ -27,8 +27,6 @@ import javax.persistence.Column; import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; import javax.persistence.Id; @@ -40,7 +38,6 @@ { @Id - @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @Column(nullable = false, length = 50) Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java 2011-12-01 08:34:48 UTC (rev 3715) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java 2011-12-01 09:10:37 UTC (rev 3716) @@ -29,8 +29,6 @@ import javax.persistence.Column; import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.ManyToOne; @@ -43,7 +41,6 @@ { @Id - @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @ManyToOne Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java 2011-12-01 08:34:48 UTC (rev 3715) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java 2011-12-01 09:10:37 UTC (rev 3716) @@ -126,7 +126,6 @@ int result = 1; result = prime * result + ((capitalization == null) ? 0 : capitalization.hashCode()); result = prime * result + ((id == null) ? 0 : id.hashCode()); - result = prime * result + ((models == null) ? 0 : models.hashCode()); result = prime * result + ((name == null) ? 0 : name.hashCode()); return result; } @@ -172,17 +171,6 @@ { return false; } - if (models == null) - { - if (other.models != null) - { - return false; - } - } - else if (!models.equals(other.models)) - { - return false; - } if (name == null) { if (other.name != null) Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java 2011-12-01 08:34:48 UTC (rev 3715) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java 2011-12-01 09:10:37 UTC (rev 3716) @@ -28,6 +28,7 @@ import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.Id; +import javax.persistence.ManyToOne; /** @@ -40,6 +41,9 @@ @Id private Long id; + @ManyToOne + private CarMaker make; + @Column private String name; @@ -63,6 +67,22 @@ } /** + * @return the make + */ + public CarMaker getMake() + { + return make; + } + + /** + * @param make the make to set + */ + public void setMake(CarMaker make) + { + this.make = make; + } + + /** * @return the name */ public String getName() @@ -103,6 +123,7 @@ final int prime = 31; int result = 1; result = prime * result + ((id == null) ? 0 : id.hashCode()); + result = prime * result + ((make == null) ? 0 : make.hashCode()); result = prime * result + ((name == null) ? 0 : name.hashCode()); result = prime * result + ((year == null) ? 0 : year.hashCode()); return result; @@ -138,6 +159,17 @@ { return false; } + if (make == null) + { + if (other.make != null) + { + return false; + } + } + else if (!make.equals(other.make)) + { + return false; + } if (name == null) { if (other.name != null) Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java 2011-12-01 08:34:48 UTC (rev 3715) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java 2011-12-01 09:10:37 UTC (rev 3716) @@ -35,10 +35,14 @@ public class CurrencyAmount { - private final double amount; + private double amount; - private final String currency; + private String currency; + public CurrencyAmount() + { + } + public CurrencyAmount(double amount, String currency) { super(); @@ -114,4 +118,20 @@ return true; } + /** + * @param amount the amount to set + */ + public void setAmount(double amount) + { + this.amount = amount; + } + + /** + * @param currency the currency to set + */ + public void setCurrency(String currency) + { + this.currency = currency; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java 2011-12-01 08:34:48 UTC (rev 3715) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java 2011-12-01 09:10:37 UTC (rev 3716) @@ -87,7 +87,6 @@ { final int prime = 31; int result = super.hashCode(); - result = prime * result + ((cars == null) ? 0 : cars.hashCode()); result = prime * result + ((totalValueOfCars == null) ? 0 : totalValueOfCars.hashCode()); return result; } @@ -111,17 +110,6 @@ return false; } Owner other = (Owner) obj; - if (cars == null) - { - if (other.cars != null) - { - return false; - } - } - else if (!cars.equals(other.cars)) - { - return false; - } if (totalValueOfCars == null) { if (other.totalValueOfCars != null) Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-12-01 08:34:48 UTC (rev 3715) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-12-01 09:10:37 UTC (rev 3716) @@ -33,8 +33,6 @@ import javax.persistence.Embedded; import javax.persistence.Entity; import javax.persistence.FetchType; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.Inheritance; import javax.persistence.InheritanceType; @@ -51,7 +49,6 @@ { @Id - @GeneratedValue(strategy = GenerationType.AUTO) private Long id; @Embedded This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <gca...@us...> - 2011-12-01 08:34:55
|
Revision: 3715 http://openutils.svn.sourceforge.net/openutils/?rev=3715&view=rev Author: gcatania Date: 2011-12-01 08:34:48 +0000 (Thu, 01 Dec 2011) Log Message: ----------- BSHD-2 hashcode, equals on test model objects Modified Paths: -------------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FullName.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Address.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -198,7 +198,7 @@ { return false; } - if (getClass() != obj.getClass()) + if (!(obj instanceof Address)) { return false; } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -147,4 +147,109 @@ return maker; } + /** + * {@inheritDoc} + */ + @Override + public int hashCode() + { + final int prime = 31; + int result = 1; + result = prime * result + ((id == null) ? 0 : id.hashCode()); + result = prime * result + ((maker == null) ? 0 : maker.hashCode()); + result = prime * result + ((marketValue == null) ? 0 : marketValue.hashCode()); + result = prime * result + ((model == null) ? 0 : model.hashCode()); + result = prime * result + ((owner == null) ? 0 : owner.hashCode()); + result = prime * result + ((registrationDate == null) ? 0 : registrationDate.hashCode()); + return result; + } + + /** + * {@inheritDoc} + */ + @Override + public boolean equals(Object obj) + { + if (this == obj) + { + return true; + } + if (obj == null) + { + return false; + } + if (!(obj instanceof Car)) + { + return false; + } + Car other = (Car) obj; + if (id == null) + { + if (other.id != null) + { + return false; + } + } + else if (!id.equals(other.id)) + { + return false; + } + if (maker == null) + { + if (other.maker != null) + { + return false; + } + } + else if (!maker.equals(other.maker)) + { + return false; + } + if (marketValue == null) + { + if (other.marketValue != null) + { + return false; + } + } + else if (!marketValue.equals(other.marketValue)) + { + return false; + } + if (model == null) + { + if (other.model != null) + { + return false; + } + } + else if (!model.equals(other.model)) + { + return false; + } + if (owner == null) + { + if (other.owner != null) + { + return false; + } + } + else if (!owner.equals(other.owner)) + { + return false; + } + if (registrationDate == null) + { + if (other.registrationDate != null) + { + return false; + } + } + else if (!registrationDate.equals(other.registrationDate)) + { + return false; + } + return true; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -116,4 +116,85 @@ this.models = models; } + /** + * {@inheritDoc} + */ + @Override + public int hashCode() + { + final int prime = 31; + int result = 1; + result = prime * result + ((capitalization == null) ? 0 : capitalization.hashCode()); + result = prime * result + ((id == null) ? 0 : id.hashCode()); + result = prime * result + ((models == null) ? 0 : models.hashCode()); + result = prime * result + ((name == null) ? 0 : name.hashCode()); + return result; + } + + /** + * {@inheritDoc} + */ + @Override + public boolean equals(Object obj) + { + if (this == obj) + { + return true; + } + if (obj == null) + { + return false; + } + if (!(obj instanceof CarMaker)) + { + return false; + } + CarMaker other = (CarMaker) obj; + if (capitalization == null) + { + if (other.capitalization != null) + { + return false; + } + } + else if (!capitalization.equals(other.capitalization)) + { + return false; + } + if (id == null) + { + if (other.id != null) + { + return false; + } + } + else if (!id.equals(other.id)) + { + return false; + } + if (models == null) + { + if (other.models != null) + { + return false; + } + } + else if (!models.equals(other.models)) + { + return false; + } + if (name == null) + { + if (other.name != null) + { + return false; + } + } + else if (!name.equals(other.name)) + { + return false; + } + return true; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -94,4 +94,73 @@ this.year = year; } + /** + * {@inheritDoc} + */ + @Override + public int hashCode() + { + final int prime = 31; + int result = 1; + result = prime * result + ((id == null) ? 0 : id.hashCode()); + result = prime * result + ((name == null) ? 0 : name.hashCode()); + result = prime * result + ((year == null) ? 0 : year.hashCode()); + return result; + } + + /** + * {@inheritDoc} + */ + @Override + public boolean equals(Object obj) + { + if (this == obj) + { + return true; + } + if (obj == null) + { + return false; + } + if (!(obj instanceof CarModel)) + { + return false; + } + CarModel other = (CarModel) obj; + if (id == null) + { + if (other.id != null) + { + return false; + } + } + else if (!id.equals(other.id)) + { + return false; + } + if (name == null) + { + if (other.name != null) + { + return false; + } + } + else if (!name.equals(other.name)) + { + return false; + } + if (year == null) + { + if (other.year != null) + { + return false; + } + } + else if (!year.equals(other.year)) + { + return false; + } + return true; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -62,4 +62,56 @@ return currency; } + /** + * {@inheritDoc} + */ + @Override + public int hashCode() + { + final int prime = 31; + int result = 1; + long temp; + temp = Double.doubleToLongBits(amount); + result = prime * result + (int) (temp ^ (temp >>> 32)); + result = prime * result + ((currency == null) ? 0 : currency.hashCode()); + return result; + } + + /** + * {@inheritDoc} + */ + @Override + public boolean equals(Object obj) + { + if (this == obj) + { + return true; + } + if (obj == null) + { + return false; + } + if (!(obj instanceof CurrencyAmount)) + { + return false; + } + CurrencyAmount other = (CurrencyAmount) obj; + if (Double.doubleToLongBits(amount) != Double.doubleToLongBits(other.amount)) + { + return false; + } + if (currency == null) + { + if (other.currency != null) + { + return false; + } + } + else if (!currency.equals(other.currency)) + { + return false; + } + return true; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -79,4 +79,54 @@ this.designedModels = designedModels; } + /** + * {@inheritDoc} + */ + @Override + public int hashCode() + { + final int prime = 31; + int result = super.hashCode(); + result = prime * result + ((designedModels == null) ? 0 : designedModels.hashCode()); + result = prime * result + hipsterFactor; + return result; + } + + /** + * {@inheritDoc} + */ + @Override + public boolean equals(Object obj) + { + if (this == obj) + { + return true; + } + if (!super.equals(obj)) + { + return false; + } + if (!(obj instanceof Designer)) + { + return false; + } + Designer other = (Designer) obj; + if (designedModels == null) + { + if (other.designedModels != null) + { + return false; + } + } + else if (!designedModels.equals(other.designedModels)) + { + return false; + } + if (hipsterFactor != other.hipsterFactor) + { + return false; + } + return true; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -136,4 +136,97 @@ this.employedSince = employedSince; } + /** + * {@inheritDoc} + */ + @Override + public int hashCode() + { + final int prime = 31; + int result = super.hashCode(); + result = prime * result + ((department == null) ? 0 : department.hashCode()); + result = prime * result + ((employedSince == null) ? 0 : employedSince.hashCode()); + result = prime * result + ((employer == null) ? 0 : employer.hashCode()); + result = prime * result + ((grossAnnualSalary == null) ? 0 : grossAnnualSalary.hashCode()); + result = prime * result + ((qualification == null) ? 0 : qualification.hashCode()); + return result; + } + + /** + * {@inheritDoc} + */ + @Override + public boolean equals(Object obj) + { + if (this == obj) + { + return true; + } + if (!super.equals(obj)) + { + return false; + } + if (!(obj instanceof Employee)) + { + return false; + } + Employee other = (Employee) obj; + if (department == null) + { + if (other.department != null) + { + return false; + } + } + else if (!department.equals(other.department)) + { + return false; + } + if (employedSince == null) + { + if (other.employedSince != null) + { + return false; + } + } + else if (!employedSince.equals(other.employedSince)) + { + return false; + } + if (employer == null) + { + if (other.employer != null) + { + return false; + } + } + else if (!employer.equals(other.employer)) + { + return false; + } + if (grossAnnualSalary == null) + { + if (other.grossAnnualSalary != null) + { + return false; + } + } + else if (!grossAnnualSalary.equals(other.grossAnnualSalary)) + { + return false; + } + if (qualification == null) + { + if (other.qualification != null) + { + return false; + } + } + else if (!qualification.equals(other.qualification)) + { + return false; + } + return true; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FullName.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FullName.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FullName.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -130,7 +130,7 @@ { return false; } - if (getClass() != obj.getClass()) + if (!(obj instanceof FullName)) { return false; } @@ -157,15 +157,8 @@ { return false; } - if (title == null) + if (title != other.title) { - if (other.title != null) - { - return false; - } - } - else if (!title.equals(other.title)) - { return false; } return true; Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -79,4 +79,61 @@ return totalValueOfCars; } + /** + * {@inheritDoc} + */ + @Override + public int hashCode() + { + final int prime = 31; + int result = super.hashCode(); + result = prime * result + ((cars == null) ? 0 : cars.hashCode()); + result = prime * result + ((totalValueOfCars == null) ? 0 : totalValueOfCars.hashCode()); + return result; + } + + /** + * {@inheritDoc} + */ + @Override + public boolean equals(Object obj) + { + if (this == obj) + { + return true; + } + if (!super.equals(obj)) + { + return false; + } + if (!(obj instanceof Owner)) + { + return false; + } + Owner other = (Owner) obj; + if (cars == null) + { + if (other.cars != null) + { + return false; + } + } + else if (!cars.equals(other.cars)) + { + return false; + } + if (totalValueOfCars == null) + { + if (other.totalValueOfCars != null) + { + return false; + } + } + else if (!totalValueOfCars.equals(other.totalValueOfCars)) + { + return false; + } + return true; + } + } Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-12-01 08:26:28 UTC (rev 3714) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-12-01 08:34:48 UTC (rev 3715) @@ -176,7 +176,7 @@ { return false; } - if (getClass() != obj.getClass()) + if (!(obj instanceof Person)) { return false; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <gca...@us...> - 2011-12-01 08:26:35
|
Revision: 3714 http://openutils.svn.sourceforge.net/openutils/?rev=3714&view=rev Author: gcatania Date: 2011-12-01 08:26:28 +0000 (Thu, 01 Dec 2011) Log Message: ----------- BSHD-2 adding model objects for unit tests Modified Paths: -------------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml Added Paths: ----------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java 2011-12-01 08:26:28 UTC (rev 3714) @@ -0,0 +1,82 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.model; + +import java.util.Set; + +import javax.persistence.Column; +import javax.persistence.DiscriminatorValue; +import javax.persistence.Entity; +import javax.persistence.ManyToMany; + + +/** + * @author gcatania + */ +@Entity +@DiscriminatorValue("designer") +public class Designer extends Employee +{ + + @Column + private int hipsterFactor; + + @ManyToMany + Set<CarModel> designedModels; + + /** + * @return the hipsterFactor + */ + public int getHipsterFactor() + { + return hipsterFactor; + } + + /** + * @param hipsterFactor the hipsterFactor to set + */ + public void setHipsterFactor(int hipsterFactor) + { + this.hipsterFactor = hipsterFactor; + } + + /** + * @return the designedModels + */ + public Set<CarModel> getDesignedModels() + { + return designedModels; + } + + /** + * @param designedModels the designedModels to set + */ + public void setDesignedModels(Set<CarModel> designedModels) + { + this.designedModels = designedModels; + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Designer.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java 2011-12-01 08:26:28 UTC (rev 3714) @@ -0,0 +1,139 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.model; + +import java.util.Calendar; + +import javax.persistence.Column; +import javax.persistence.DiscriminatorValue; +import javax.persistence.Entity; +import javax.persistence.ManyToOne; + + +/** + * @author gcatania + */ +@Entity +@DiscriminatorValue("employee") +public class Employee extends Person +{ + + @ManyToOne + private CarMaker employer; + + @Column + private CurrencyAmount grossAnnualSalary; + + @Column + private String qualification; + + @Column + private String department; + + @Column + private Calendar employedSince; + + /** + * @return the employer + */ + public CarMaker getEmployer() + { + return employer; + } + + /** + * @param employer the employer to set + */ + public void setEmployer(CarMaker employer) + { + this.employer = employer; + } + + /** + * @return the grossAnnualSalary + */ + public CurrencyAmount getGrossAnnualSalary() + { + return grossAnnualSalary; + } + + /** + * @param grossAnnualSalary the grossAnnualSalary to set + */ + public void setGrossAnnualSalary(CurrencyAmount grossAnnualSalary) + { + this.grossAnnualSalary = grossAnnualSalary; + } + + /** + * @return the qualification + */ + public String getQualification() + { + return qualification; + } + + /** + * @param qualification the qualification to set + */ + public void setQualification(String qualification) + { + this.qualification = qualification; + } + + /** + * @return the department + */ + public String getDepartment() + { + return department; + } + + /** + * @param department the department to set + */ + public void setDepartment(String department) + { + this.department = department; + } + + /** + * @return the employedSince + */ + public Calendar getEmployedSince() + { + return employedSince; + } + + /** + * @param employedSince the employedSince to set + */ + public void setEmployedSince(Calendar employedSince) + { + this.employedSince = employedSince; + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Employee.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java 2011-11-30 17:24:37 UTC (rev 3713) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java 2011-12-01 08:26:28 UTC (rev 3714) @@ -27,11 +27,8 @@ import java.util.Set; -import javax.persistence.DiscriminatorColumn; import javax.persistence.DiscriminatorValue; import javax.persistence.Entity; -import javax.persistence.Inheritance; -import javax.persistence.InheritanceType; import javax.persistence.OneToMany; import javax.persistence.Transient; @@ -40,8 +37,6 @@ * @author gcatania */ @Entity -@Inheritance(strategy = InheritanceType.JOINED) -@DiscriminatorColumn(name = "personType") @DiscriminatorValue("owner") public class Owner extends Person { Modified: trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml =================================================================== --- trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml 2011-11-30 17:24:37 UTC (rev 3713) +++ trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml 2011-12-01 08:26:28 UTC (rev 3714) @@ -7,6 +7,8 @@ <mapping class="it.openutils.hibernate.test.model.Car" /> <mapping class="it.openutils.hibernate.test.model.CarMaker" /> <mapping class="it.openutils.hibernate.test.model.CarModel" /> + <mapping class="it.openutils.hibernate.test.model.Designer" /> + <mapping class="it.openutils.hibernate.test.model.Employee" /> <mapping class="it.openutils.hibernate.test.model.FullName" /> <mapping class="it.openutils.hibernate.test.model.Owner" /> <mapping class="it.openutils.hibernate.test.model.Person" /> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <gca...@us...> - 2011-11-30 17:24:45
|
Revision: 3713 http://openutils.svn.sourceforge.net/openutils/?rev=3713&view=rev Author: gcatania Date: 2011-11-30 17:24:37 +0000 (Wed, 30 Nov 2011) Log Message: ----------- BSHD-2 unit tests: reworked hibernate entities, added failing unit test for lookup by id Modified Paths: -------------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/PersonDAO.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml Added Paths: ----------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/CarDAO.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java Removed Paths: ------------- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Chance.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FantasticThing.java trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Wish.java Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java 2011-11-30 15:11:36 UTC (rev 3712) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/HibernateDAOTest.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -25,16 +25,22 @@ package it.openutils.hibernate.test; +import it.openutils.hibernate.test.dao.CarDAO; import it.openutils.hibernate.test.dao.PersonDAO; import it.openutils.hibernate.test.model.Address; +import it.openutils.hibernate.test.model.Car; +import it.openutils.hibernate.test.model.CarMaker; +import it.openutils.hibernate.test.model.CarModel; +import it.openutils.hibernate.test.model.CurrencyAmount; import it.openutils.hibernate.test.model.FullName; +import it.openutils.hibernate.test.model.Owner; import it.openutils.hibernate.test.model.Person; -import it.openutils.hibernate.test.model.Wish; +import java.util.Calendar; import java.util.Collections; +import java.util.GregorianCalendar; import java.util.List; -import org.hibernate.Hibernate; import org.hibernate.criterion.Example; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.context.ContextConfiguration; @@ -52,28 +58,61 @@ /* * TODO tests to perform: 1) find filtered with collection with zero, one or more elements 2) find filtered with - * additional criteria 3) filter metadata support + * additional criteria 3) filter metadata support 4) find filtered with id 5) find filtered with backref */ @Autowired private PersonDAO personDAO; - private Person fifteenYearsOld() + @Autowired + private CarDAO carDAO; + + private Person alice() { - return new Person( - new FullName("Troy", "Jones"), - 15, - new Address("Long road", 15, "Smalltown", "MI", 14352), - null); + FullName fullName = new FullName("Alice", "McBeal"); + Calendar birthDate = new GregorianCalendar(1970, Calendar.MARCH, 7); + Address address = new Address("Long road", 15, "Smalltown", "MI", 14352); + Person p = new Person(); + p.setName(fullName); + p.setBirthDate(birthDate); + p.setFiscalAddress(address); + p.setCurrentAddress(address); + return p; } + private Owner bob() + { + FullName fullName = new FullName("Bob", "Kelso"); + Calendar birthDate = new GregorianCalendar(1950, Calendar.MARCH, 7); + Address address = new Address("Sacred Heart Lane", 3, "Smalltown", "CA", 11243); + Owner o = new Owner(); + o.setName(fullName); + o.setBirthDate(birthDate); + o.setFiscalAddress(address); + o.setCurrentAddress(address); + return o; + } + + private Owner chuck() + { + FullName fullName = new FullName("Chuck", "Palahniuk"); + Calendar birthDate = new GregorianCalendar(1962, Calendar.FEBRUARY, 21); + Address address = new Address("Awesome Street", 2, "Pasco", "WA", 13121); + Owner p = new Owner(); + p.setName(fullName); + p.setBirthDate(birthDate); + p.setFiscalAddress(address); + p.setCurrentAddress(address); + return p; + } + /** * basic save/evict/get test. */ @Test public void testSaveAndRetrievePerson() { - Person person = fifteenYearsOld(); + Person person = alice(); Long savedId = personDAO.save(person); Assert.assertNotNull(savedId); Long personId = person.getId(); @@ -86,52 +125,100 @@ @Test public void testFindFilteredFirst() { - personDAO.save(fifteenYearsOld()); - List<Person> found = personDAO.findFiltered(new Person(new FullName(null, "Jones"), null, null, null)); - Assert.assertTrue(found.size() > 0, "No persons found."); + Person alice = alice(); + personDAO.save(alice); + Person filter = new Person(); + filter.setName(new FullName(null, "McBeal")); + List<Person> found = personDAO.findFiltered(filter); + + Assert.assertEquals(found.size(), 1, "No persons found."); + Assert.assertEquals(found.get(0), alice); } @Test - public void testExampleBasic() + public void testFindFilteredById() { - personDAO.save(fifteenYearsOld()); - Person outsideFilter = fifteenYearsOld(); - outsideFilter.getName().setFamilyName("Mahoney"); - personDAO.save(outsideFilter); - Person filter = new Person(new FullName(null, "Jones"), null, null, null); - List<Person> foundByExample = personDAO.find(Collections.singletonList(Example.create(filter))); - Assert.assertNotNull(foundByExample); - Assert.assertEquals(foundByExample.size(), 1); - Assert.assertEquals(foundByExample.get(0).getName().getFamilyName(), "Jones"); + Person alice = alice(); + Long savedId = personDAO.save(alice); + Person filter = new Person(); + filter.setId(savedId); + List<Person> found = personDAO.findFiltered(filter); - List<Person> found = personDAO.findFiltered(filter); - Assert.assertNotNull(found); - Assert.assertEquals(found.size(), 1); - Assert.assertEquals(found.get(0).getName().getFamilyName(), "Jones"); + Assert.assertEquals(found.size(), 1, "No persons found."); + Assert.assertEquals(found.get(0), alice); } + /* + * disabled: filter by id on child objects isn't working yet (see + * http://docs.jboss.org/hibernate/core/3.6/reference/en-US/html/querycriteria.html#querycriteria-examples and + * https://forum.hibernate.org/viewtopic.php?f=9&t=1004833&view=next ) + */ + @Test(enabled = false) + public void testFindFilteredByChildId() + { + Owner bob = bob(); + CarMaker toyota = new CarMaker(); + toyota.setName("Toyota"); + toyota.setCapitalization(new CurrencyAmount(12000, "YEN")); + CarModel prius = new CarModel(); + prius.setName("Prius"); + prius.setYear(Integer.valueOf(2008)); + toyota.setModels(Collections.singletonList(prius)); + + Car bobsPrius = new Car(new GregorianCalendar(2010, Calendar.OCTOBER, 12), prius, toyota); + bob.setCars(Collections.singleton(bobsPrius)); + personDAO.save(bob); + + Owner filter = new Owner(); + Car carFilter = new Car(null, null, null); + carFilter.setId(bobsPrius.getId()); + filter.setCars(Collections.singleton(carFilter)); + Person found = personDAO.findFilteredFirst(filter); + Assert.assertEquals(found.getName(), bob.getName()); + } + @Test - public void testExampleAssociations() + public void testExampleBasic() { - Person fifteenYearsOld = fifteenYearsOld(); - fifteenYearsOld.setWish(new Wish(fifteenYearsOld, "because he's young")); - personDAO.save(fifteenYearsOld); - Person another = fifteenYearsOld(); - another.setWish(new Wish(another, "because he's a nerd")); - personDAO.save(another); - + personDAO.save(alice()); + Person outsideFilter = alice(); + outsideFilter.getName().setFamilyName("Mahoney"); + personDAO.save(outsideFilter); Person filter = new Person(); - filter.setWish(new Wish(null, "because he's young")); + filter.setName(new FullName(null, "McBeal")); List<Person> foundByExample = personDAO.find(Collections.singletonList(Example.create(filter))); - Hibernate.initialize(foundByExample); Assert.assertNotNull(foundByExample); - Assert.assertEquals(foundByExample.size(), 2); + Assert.assertEquals(foundByExample.size(), 1); + Assert.assertEquals(foundByExample.get(0).getName().getFamilyName(), "McBeal"); List<Person> found = personDAO.findFiltered(filter); - Hibernate.initialize(found); Assert.assertNotNull(found); Assert.assertEquals(found.size(), 1); - Assert.assertEquals(found.get(0).getWish().getReason(), "because he's young"); + Assert.assertEquals(found.get(0).getName().getFamilyName(), "McBeal"); } + // @Test + // public void testExampleAssociations() + // { + // Person fifteenYearsOld = fifteenYearsOld(); + // fifteenYearsOld.setWish(new Wish(fifteenYearsOld, "because he's young")); + // personDAO.save(fifteenYearsOld); + // Person another = fifteenYearsOld(); + // another.setWish(new Wish(another, "because he's a nerd")); + // personDAO.save(another); + // + // Person filter = new Person(); + // filter.setWish(new Wish(null, "because he's young")); + // List<Person> foundByExample = personDAO.find(Collections.singletonList(Example.create(filter))); + // Hibernate.initialize(foundByExample); + // Assert.assertNotNull(foundByExample); + // Assert.assertEquals(foundByExample.size(), 2); + // + // List<Person> found = personDAO.findFiltered(filter); + // Hibernate.initialize(found); + // Assert.assertNotNull(found); + // Assert.assertEquals(found.size(), 1); + // Assert.assertEquals(found.get(0).getWish().getReason(), "because he's young"); + // } + } Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/CarDAO.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/CarDAO.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/CarDAO.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -0,0 +1,55 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.dao; + +import it.openutils.dao.hibernate.HibernateDAO; +import it.openutils.dao.hibernate.HibernateDAOImpl; +import it.openutils.hibernate.test.model.Person; + +import org.hibernate.SessionFactory; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Repository; + + +/** + * @author gcatania + */ +public interface CarDAO extends HibernateDAO<Person, Long> +{ + + @Repository("carDAO") + class PersonDAOImpl extends HibernateDAOImpl<Person, Long> implements CarDAO + { + + @Autowired + public PersonDAOImpl(SessionFactory factory) + { + super(Person.class); + setSessionFactory(factory); + } + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/CarDAO.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/PersonDAO.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/PersonDAO.java 2011-11-30 15:11:36 UTC (rev 3712) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/dao/PersonDAO.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -40,9 +40,6 @@ public interface PersonDAO extends HibernateDAO<Person, Long> { - /** - * @author gcatania - */ @Repository("personDAO") class PersonDAOImpl extends HibernateDAOImpl<Person, Long> implements PersonDAO { Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -0,0 +1,150 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.model; + +import java.util.Calendar; + +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.ManyToOne; + + +/** + * @author gcatania + */ +@Entity +public class Car +{ + + @Id + @GeneratedValue(strategy = GenerationType.AUTO) + private Long id; + + @ManyToOne + private final CarModel model; + + @ManyToOne + private final CarMaker maker; + + @ManyToOne + private Owner owner; + + @Column + private Calendar registrationDate; + + @Column + private CurrencyAmount marketValue; + + public Car(Calendar registrationDate, CarModel model, CarMaker maker) + { + this.model = model; + this.maker = maker; + } + + /** + * @return the id + */ + public Long getId() + { + return id; + } + + /** + * @param id the id to set + */ + public void setId(Long id) + { + this.id = id; + } + + /** + * @return the owner + */ + public Owner getOwner() + { + return owner; + } + + /** + * @param owner the owner to set + */ + public void setOwner(Owner owner) + { + this.owner = owner; + } + + /** + * @return the registrationDate + */ + public Calendar getRegistrationDate() + { + return registrationDate; + } + + /** + * @param registrationDate the registrationDate to set + */ + public void setRegistrationDate(Calendar registrationDate) + { + this.registrationDate = registrationDate; + } + + /** + * @return the marketValue + */ + public CurrencyAmount getMarketValue() + { + return marketValue; + } + + /** + * @param marketValue the marketValue to set + */ + public void setMarketValue(CurrencyAmount marketValue) + { + this.marketValue = marketValue; + } + + /** + * @return the model + */ + public CarModel getModel() + { + return model; + } + + /** + * @return the maker + */ + public CarMaker getMaker() + { + return maker; + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Car.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -0,0 +1,119 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.model; + +import java.util.List; + +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.Id; +import javax.persistence.OneToMany; + + +/** + * @author gcatania + */ +@Entity +public class CarMaker +{ + + @Id + private Long id; + + @Column + private String name; + + @Column + private CurrencyAmount capitalization; + + @OneToMany + private List<CarModel> models; + + /** + * @return the id + */ + public Long getId() + { + return id; + } + + /** + * @param id the id to set + */ + public void setId(Long id) + { + this.id = id; + } + + /** + * @return the name + */ + public String getName() + { + return name; + } + + /** + * @param name the name to set + */ + public void setName(String name) + { + this.name = name; + } + + /** + * @return the capitalization + */ + public CurrencyAmount getCapitalization() + { + return capitalization; + } + + /** + * @param capitalization the capitalization to set + */ + public void setCapitalization(CurrencyAmount capitalization) + { + this.capitalization = capitalization; + } + + /** + * @return the models + */ + public List<CarModel> getModels() + { + return models; + } + + /** + * @param models the models to set + */ + public void setModels(List<CarModel> models) + { + this.models = models; + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarMaker.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -0,0 +1,97 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.model; + +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.Id; + + +/** + * @author gcatania + */ +@Entity +public class CarModel +{ + + @Id + private Long id; + + @Column + private String name; + + @Column + private Integer year; + + /** + * @return the id + */ + public Long getId() + { + return id; + } + + /** + * @param id the id to set + */ + public void setId(Long id) + { + this.id = id; + } + + /** + * @return the name + */ + public String getName() + { + return name; + } + + /** + * @param name the name to set + */ + public void setName(String name) + { + this.name = name; + } + + /** + * @return the year + */ + public Integer getYear() + { + return year; + } + + /** + * @param year the year to set + */ + public void setYear(Integer year) + { + this.year = year; + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CarModel.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Deleted: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Chance.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Chance.java 2011-11-30 15:11:36 UTC (rev 3712) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Chance.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -1,35 +0,0 @@ -/** - * - * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) - * - * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it - * - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * You may obtain a copy of the License at - * - * http://www.gnu.org/licenses/lgpl-2.1.html - * - * 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 it.openutils.hibernate.test.model; - -/** - * @author gcatania - */ -public enum Chance { - - /** chance. */ - TOTALLY_REMOTE, VAGUELY_POSSIBLE, QUITE_POSSIBLE, CAKEWALK_EASY -} Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -0,0 +1,65 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.model; + +import javax.persistence.Embeddable; + + +/** + * @author gcatania + */ +@Embeddable +public class CurrencyAmount +{ + + private final double amount; + + private final String currency; + + public CurrencyAmount(double amount, String currency) + { + super(); + this.amount = amount; + this.currency = currency; + } + + /** + * @return the amount + */ + public double getAmount() + { + return amount; + } + + /** + * @return the currency + */ + public String getCurrency() + { + return currency; + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/CurrencyAmount.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Deleted: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FantasticThing.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FantasticThing.java 2011-11-30 15:11:36 UTC (rev 3712) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/FantasticThing.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -1,214 +0,0 @@ -/** - * - * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) - * - * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it - * - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * You may obtain a copy of the License at - * - * http://www.gnu.org/licenses/lgpl-2.1.html - * - * 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 it.openutils.hibernate.test.model; - -import java.util.Set; - -import javax.persistence.CascadeType; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.ManyToMany; - - -/** - * @author gcatania - */ -@Entity -public class FantasticThing -{ - - @Id - @GeneratedValue(strategy = GenerationType.AUTO) - private Long id; - - private String thingName; - - private Chance chanceOfAchievement; - - @ManyToMany(mappedBy = "objectsOfWish", cascade = CascadeType.ALL) - private Set<Wish> wishes; - - public FantasticThing() - { - } - - public FantasticThing(String thingName, Chance chanceOfAchievement) - { - this.thingName = thingName; - this.chanceOfAchievement = chanceOfAchievement; - } - - /** - * @return the id - */ - public Long getId() - { - return id; - } - - /** - * @param id the id to set - */ - public void setId(Long id) - { - this.id = id; - } - - /** - * @return the thingName - */ - public String getThingName() - { - return thingName; - } - - /** - * @param thingName the thingName to set - */ - public void setThingName(String thingName) - { - this.thingName = thingName; - } - - /** - * @return the chanceOfAchievement - */ - public Chance getChanceOfAchievement() - { - return chanceOfAchievement; - } - - /** - * @param chanceOfAchievement the chanceOfAchievement to set - */ - public void setChanceOfAchievement(Chance chanceOfAchievement) - { - this.chanceOfAchievement = chanceOfAchievement; - } - - /** - * @return the wishes - */ - public Set<Wish> getWishes() - { - return wishes; - } - - /** - * @param wishes the wishes to set - */ - public void setWishes(Set<Wish> wishes) - { - this.wishes = wishes; - } - - /** - * {@inheritDoc} - */ - @Override - public int hashCode() - { - final int prime = 31; - int result = 1; - result = prime * result + ((chanceOfAchievement == null) ? 0 : chanceOfAchievement.hashCode()); - result = prime * result + ((id == null) ? 0 : id.hashCode()); - result = prime * result + ((thingName == null) ? 0 : thingName.hashCode()); - return result; - } - - /** - * {@inheritDoc} - */ - @Override - public boolean equals(Object obj) - { - if (this == obj) - { - return true; - } - if (obj == null) - { - return false; - } - if (getClass() != obj.getClass()) - { - return false; - } - FantasticThing other = (FantasticThing) obj; - if (chanceOfAchievement == null) - { - if (other.chanceOfAchievement != null) - { - return false; - } - } - else if (!chanceOfAchievement.equals(other.chanceOfAchievement)) - { - return false; - } - if (id == null) - { - if (other.id != null) - { - return false; - } - } - else if (!id.equals(other.id)) - { - return false; - } - if (thingName == null) - { - if (other.thingName != null) - { - return false; - } - } - else if (!thingName.equals(other.thingName)) - { - return false; - } - return true; - } - - /** - * {@inheritDoc} - */ - @Override - public String toString() - { - return "FantasticThing [chanceOfAchievement=" - + chanceOfAchievement - + ", id=" - + id - + ", thingName=" - + thingName - + "]"; - } - -} Added: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java (rev 0) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -0,0 +1,87 @@ +/** + * + * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) + * + * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it + * + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * You may obtain a copy of the License at + * + * http://www.gnu.org/licenses/lgpl-2.1.html + * + * 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 it.openutils.hibernate.test.model; + +import java.util.Set; + +import javax.persistence.DiscriminatorColumn; +import javax.persistence.DiscriminatorValue; +import javax.persistence.Entity; +import javax.persistence.Inheritance; +import javax.persistence.InheritanceType; +import javax.persistence.OneToMany; +import javax.persistence.Transient; + + +/** + * @author gcatania + */ +@Entity +@Inheritance(strategy = InheritanceType.JOINED) +@DiscriminatorColumn(name = "personType") +@DiscriminatorValue("owner") +public class Owner extends Person +{ + + @OneToMany + private Set<Car> cars; + + @Transient + private CurrencyAmount totalValueOfCars; + + /** + * @return the cars + */ + public Set<Car> getCars() + { + return cars; + } + + /** + * @param cars the cars to set + */ + public void setCars(Set<Car> cars) + { + this.cars = cars; + } + + /** + * @param totalValueOfCars the totalValueOfCars to set + */ + public void setTotalValueOfCars(CurrencyAmount totalValueOfCars) + { + this.totalValueOfCars = totalValueOfCars; + } + + /** + * @return the totalValueOfCars + */ + public CurrencyAmount getTotalValueOfCars() + { + return totalValueOfCars; + } + +} Property changes on: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Owner.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Modified: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-11-30 15:11:36 UTC (rev 3712) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Person.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -25,22 +25,28 @@ package it.openutils.hibernate.test.model; +import java.util.Calendar; + import javax.persistence.CascadeType; import javax.persistence.Column; +import javax.persistence.DiscriminatorColumn; import javax.persistence.Embedded; import javax.persistence.Entity; import javax.persistence.FetchType; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; +import javax.persistence.Inheritance; +import javax.persistence.InheritanceType; import javax.persistence.ManyToOne; -import javax.persistence.OneToOne; /** * @author gcatania */ @Entity +@Inheritance(strategy = InheritanceType.JOINED) +@DiscriminatorColumn(name = "personType") public class Person { @@ -51,8 +57,8 @@ @Embedded private FullName name; - @Column(nullable = false, scale = 3) - private Integer age; + @Column(nullable = false) + private Calendar birthDate; @ManyToOne(fetch = FetchType.EAGER, optional = false, cascade = CascadeType.ALL) private Address currentAddress; @@ -60,21 +66,6 @@ @ManyToOne(cascade = CascadeType.ALL) private Address fiscalAddress; - @OneToOne(cascade = CascadeType.ALL) - private Wish wish; - - public Person() - { - } - - public Person(FullName name, Integer age, Address currentAddress, Address fiscalAddress) - { - this.name = name; - this.age = age; - this.currentAddress = currentAddress; - this.fiscalAddress = fiscalAddress; - } - /** * @return the id */ @@ -108,6 +99,22 @@ } /** + * @return the birthDate + */ + public Calendar getBirthDate() + { + return birthDate; + } + + /** + * @param birthDate the birthDate to set + */ + public void setBirthDate(Calendar birthDate) + { + this.birthDate = birthDate; + } + + /** * @return the currentAddress */ public Address getCurrentAddress() @@ -140,22 +147,6 @@ } /** - * @return the wish - */ - public Wish getWish() - { - return wish; - } - - /** - * @param wish the wish to set - */ - public void setWish(Wish wish) - { - this.wish = wish; - } - - /** * {@inheritDoc} */ @Override @@ -163,12 +154,11 @@ { final int prime = 31; int result = 1; - result = prime * result + ((age == null) ? 0 : age); + result = prime * result + ((birthDate == null) ? 0 : birthDate.hashCode()); result = prime * result + ((currentAddress == null) ? 0 : currentAddress.hashCode()); result = prime * result + ((fiscalAddress == null) ? 0 : fiscalAddress.hashCode()); result = prime * result + ((id == null) ? 0 : id.hashCode()); result = prime * result + ((name == null) ? 0 : name.hashCode()); - result = prime * result + ((wish == null) ? 0 : wish.hashCode()); return result; } @@ -191,14 +181,14 @@ return false; } Person other = (Person) obj; - if (age == null) + if (birthDate == null) { - if (other.age != null) + if (other.birthDate != null) { return false; } } - else if (!age.equals(other.age)) + else if (!birthDate.equals(other.birthDate)) { return false; } @@ -246,17 +236,6 @@ { return false; } - if (wish == null) - { - if (other.wish != null) - { - return false; - } - } - else if (!wish.equals(other.wish)) - { - return false; - } return true; } @@ -266,9 +245,7 @@ @Override public String toString() { - return "Person [age=" - + age - + ", currentAddress=" + return "Person [currentAddress=" + currentAddress + ", fiscalAddress=" + fiscalAddress @@ -276,8 +253,6 @@ + id + ", name=" + name - + ", wish=" - + wish + "]"; } Deleted: trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Wish.java =================================================================== --- trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Wish.java 2011-11-30 15:11:36 UTC (rev 3712) +++ trunk/openutils-bshd5/src/test/java/it/openutils/hibernate/test/model/Wish.java 2011-11-30 17:24:37 UTC (rev 3713) @@ -1,260 +0,0 @@ -/** - * - * openutils base Spring-Hibernate DAO (http://www.openmindlab.com/lab/products/bshd5.html) - * - * Copyright(C) 2005-2011, Openmind S.r.l. http://www.openmindonline.it - * - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * You may obtain a copy of the License at - * - * http://www.gnu.org/licenses/lgpl-2.1.html - * - * 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 it.openutils.hibernate.test.model; - -import java.util.Set; - -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.ManyToMany; -import javax.persistence.OneToOne; -import javax.persistence.Transient; - - -/** - * @author gcatania - */ -@Entity -public class Wish -{ - - @Id - @GeneratedValue(strategy = GenerationType.AUTO) - private Long id; - - @OneToOne(mappedBy = "wish", optional = false, cascade = CascadeType.ALL) - private Person person; - - @Column(nullable = false) - private String reason; - - @ManyToMany(cascade = CascadeType.ALL) - private Set<FantasticThing> objectsOfWish; - - @Transient - private Integer objectCount; - - public Wish() - { - } - - public Wish(Person person, String reason) - { - this.person = person; - this.reason = reason; - } - - /** - * @return the id - */ - public Long getId() - { - return id; - } - - /** - * @param id the id to set - */ - public void setId(Long id) - { - this.id = id; - } - - /** - * @return the person - */ - public Person getPerson() - { - return person; - } - - /** - * @param person the person to set - */ - public void setPerson(Person person) - { - this.person = person; - } - - /** - * @return the reason - */ - public String getReason() - { - return reason; - } - - /** - * @param reason the reason to set - */ - public void setReason(String reason) - { - this.reason = reason; - } - - /** - * @return the objectsOfWish - */ - public Set<FantasticThing> getObjectsOfWish() - { - return objectsOfWish; - } - - /** - * @param objectsOfWish the objectsOfWish to set - */ - public void setObjectsOfWish(Set<FantasticThing> objectsOfWish) - { - this.objectsOfWish = objectsOfWish; - } - - /** - * @return the objectCount - */ - public Integer getObjectCount() - { - if (objectCount == null) - { - objectCount = objectsOfWish.size(); - } - return objectCount; - } - - /** - * @param objectCount the objectCount to set - */ - public void setObjectCount(Integer objectCount) - { - if (objectCount != null && objectCount != objectsOfWish.size()) - { - throw new IllegalArgumentException(); - } - this.objectCount = objectCount; - } - - /** - * {@inheritDoc} - */ - @Override - public int hashCode() - { - final int prime = 31; - int result = 1; - result = prime * result + ((id == null) ? 0 : id.hashCode()); - result = prime * result + ((objectCount == null) ? 0 : objectCount.hashCode()); - result = prime * result + ((objectsOfWish == null) ? 0 : objectsOfWish.hashCode()); - result = prime * result + ((reason == null) ? 0 : reason.hashCode()); - return result; - } - - /** - * {@inheritDoc} - */ - @Override - public boolean equals(Object obj) - { - if (this == obj) - { - return true; - } - if (obj == null) - { - return false; - } - if (getClass() != obj.getClass()) - { - return false; - } - Wish other = (Wish) obj; - if (id == null) - { - if (other.id != null) - { - return false; - } - } - else if (!id.equals(other.id)) - { - return false; - } - if (objectCount == null) - { - if (other.objectCount != null) - { - return false; - } - } - else if (!objectCount.equals(other.objectCount)) - { - return false; - } - if (objectsOfWish == null) - { - if (other.objectsOfWish != null) - { - return false; - } - } - else if (!objectsOfWish.equals(other.objectsOfWish)) - { - return false; - } - if (reason == null) - { - if (other.reason != null) - { - return false; - } - } - else if (!reason.equals(other.reason)) - { - return false; - } - return true; - } - - /** - * {@inheritDoc} - */ - @Override - public String toString() - { - return "Wish [id=" - + id - + ", objectCount=" - + objectCount - + ", objectsOfWish=" - + objectsOfWish - + ", reason=" - + reason - + "]"; - } - -} Modified: trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml =================================================================== --- trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml 2011-11-30 15:11:36 UTC (rev 3712) +++ trunk/openutils-bshd5/src/test/resources/hibernate.cfg.xml 2011-11-30 17:24:37 UTC (rev 3713) @@ -4,9 +4,11 @@ <hibernate-configuration> <session-factory> <mapping class="it.openutils.hibernate.test.model.Address" /> - <mapping class="it.openutils.hibernate.test.model.FantasticThing" /> + <mapping class="it.openutils.hibernate.test.model.Car" /> + <mapping class="it.openutils.hibernate.test.model.CarMaker" /> + <mapping class="it.openutils.hibernate.test.model.CarModel" /> <mapping class="it.openutils.hibernate.test.model.FullName" /> + <mapping class="it.openutils.hibernate.test.model.Owner" /> <mapping class="it.openutils.hibernate.test.model.Person" /> - <mapping class="it.openutils.hibernate.test.model.Wish" /> </session-factory> </hibernate-configuration> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <gca...@us...> - 2011-11-30 15:11:43
|
Revision: 3712 http://openutils.svn.sourceforge.net/openutils/?rev=3712&view=rev Author: gcatania Date: 2011-11-30 15:11:36 +0000 (Wed, 30 Nov 2011) Log Message: ----------- BSHD-2 exposed ExampleTree methods, deprecated use of FilterMetadata Modified Paths: -------------- trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAO.java trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAOImpl.java trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/EnhancedExample.java trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/ExampleTree.java trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/FilterMetadataSupport.java Modified: trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAO.java =================================================================== --- trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAO.java 2011-11-30 12:05:20 UTC (rev 3711) +++ trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAO.java 2011-11-30 15:11:36 UTC (rev 3712) @@ -25,6 +25,7 @@ package it.openutils.dao.hibernate; +import it.openutils.hibernate.example.ExampleTree; import it.openutils.hibernate.example.FilterMetadata; import java.io.Serializable; @@ -125,13 +126,53 @@ List<T> findFiltered(T filter, int maxResults, int page); /** + * Retrieve the entities handled by this DAO that match the input example tree + * @param exampleTree the example tree criterion to match + * @return a list of distinct entity instances (never null) + */ + List<T> findFiltered(ExampleTree exampleTree); + + /** + * Retrieve the entities handled by this DAO that match the input example tree + * @param exampleTree the example tree criterion to match + * @param orders the orders to apply with respect to entity class properties + * @return a list of distinct entity instances (never null) + */ + List<T> findFiltered(ExampleTree exampleTree, Order... orders); + + /** + * Retrieve the entities handled by this DAO that match the input example tree + * @param exampleTree the example tree criterion to match + * @param maxResults the maximum number of results to be fetched + * @param page the zero-based page number to use when displaying paginated results (the first entity returned is the + * one at position <code>maxResults * page</code> in the complete list of results), or <code>0</code> for no + * pagination + * @return a list of distinct entity instances (never null) + */ + List<T> findFiltered(ExampleTree exampleTree, int maxResults, int page); + + /** + * Retrieve the entities handled by this DAO that match the input example tree + * @param exampleTree the example tree criterion to match + * @param maxResults the maximum number of results to be fetched + * @param page the zero-based page number to use when displaying paginated results (the first entity returned is the + * one at position <code>maxResults * page</code> in the complete list of results), or <code>0</code> for no + * pagination + * @param orders the orders to apply with respect to entity class properties + * @return a list of distinct entity instances (never null) + */ + List<T> findFiltered(ExampleTree exampleTree, int maxResults, int page, Order... orders); + + /** * Retrieve the entities handled by this DAO whose property values match, via <code>equals()</code> or via a * specified <code>FilterMetadata</code> object, <code>filter</code>'s non-null property values. * @param filter an instance of this DAO's entity class to be used as filter * @param metadata a map that matches names of entity class properties to <code>FilterMetadata</code> modifiers, * that will be used for comparing values of the corresponding property * @return a list of distinct entity instances (never null) + * @deprecated use of {@link FilterMetadata} has been deprecated */ + @Deprecated List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata); /** @@ -145,7 +186,9 @@ * one at position <code>maxResults * page</code> in the complete list of results), or <code>0</code> for no * pagination * @return a list of distinct entity instances (never null) + * @deprecated use of {@link FilterMetadata} has been deprecated */ + @Deprecated List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page); /** @@ -161,7 +204,9 @@ * pagination * @param orders the orders to apply with respect to entity class properties * @return a list of distinct entity instances (never null) + * @deprecated use of {@link FilterMetadata} has been deprecated */ + @Deprecated List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page, Order... orders); @@ -179,7 +224,9 @@ * @param criteria a list of additional Hibernate criteria * @param orders the orders to apply with respect to entity class properties * @return a list of distinct entity instances (never null) + * @deprecated use of {@link FilterMetadata} has been deprecated */ + @Deprecated List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page, List< ? extends Criterion> criteria, Order... orders); @@ -197,7 +244,9 @@ * @param properties the names of the properties to return * @param orders the orders to apply with respect to entity class properties * @return a list of distinct entity instances (never null) + * @deprecated use of {@link FilterMetadata} has been deprecated */ + @Deprecated List< ? > findFilteredProperties(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page, List< ? extends Criterion> criteria, List<String> properties, Order... orders); @@ -210,6 +259,14 @@ T findFilteredFirst(T filter); /** + * Retrieve the first entity instance that matches the input example tree + * @param exampleTree the example tree criterion to match + * @return the first matching instance of the entity class managed by this DAO, or <code>null</code> if none found + * @see #findFiltered(ExampleTree) + */ + T findFilteredFirst(ExampleTree exampleTree); + + /** * Retrieve the first entity instance that matches the input <code>filter</code>, if existing. * @param filter an instance of this DAO's entity class to be used as filter * @param orders the orders to apply with respect to entity class properties @@ -219,6 +276,15 @@ T findFilteredFirst(T filter, Order... orders); /** + * Retrieve the first entity instance that matches the input example tree + * @param exampleTree the example tree criterion to match + * @param orders the orders to apply with respect to entity class properties + * @return the first matching instance of the entity class managed by this DAO, or <code>null</code> if none found + * @see #findFiltered(ExampleTree, Order...) + */ + T findFilteredFirst(ExampleTree exampleTree, final Order... orders); + + /** * Retrieve the first entity instance that matches the input <code>filter</code> and the additional input * <code>criteria</code>, if existing. * @param filter an instance of this DAO's entity class to be used as filter @@ -337,7 +403,7 @@ * one at position <code>maxResults * page</code> in the complete list of results), or <code>0</code> for no * pagination * @return a list of distinct entity instances (never null) - * @deprecated superseded by {@link #findFiltered(Object, Map, int, int, Order...)} + * @deprecated use of {@link FilterMetadata} has been deprecated */ @Deprecated List<T> findFiltered(T filter, Order[] orders, Map<String, ? extends FilterMetadata> metadata, int maxResults, @@ -357,7 +423,7 @@ * pagination * @param criteria a list of additional Hibernate criteria * @return a list of distinct entity instances (never null) - * @deprecated superseded by {@link #findFiltered(Object, Map, int, int, List, Order...)} + * @deprecated use of {@link FilterMetadata} has been deprecated */ @Deprecated List<T> findFiltered(T filter, Order[] orders, Map<String, ? extends FilterMetadata> metadata, int maxResults, @@ -377,7 +443,7 @@ * @param criteria a list of additional Hibernate criteria * @param properties the names of the properties to return * @return a list of distinct entity instances (never null) - * @deprecated superseded by {@link #findFilteredProperties(Object, Map, int, int, List, List, Order...)} + * @deprecated use of {@link FilterMetadata} has been deprecated */ @Deprecated List< ? > findFilteredProperties(T filter, Order[] orders, Map<String, ? extends FilterMetadata> metadata, Modified: trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAOImpl.java =================================================================== --- trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAOImpl.java 2011-11-30 12:05:20 UTC (rev 3711) +++ trunk/openutils-bshd5/src/main/java/it/openutils/dao/hibernate/HibernateDAOImpl.java 2011-11-30 15:11:36 UTC (rev 3712) @@ -38,6 +38,8 @@ import java.util.Map; import org.aopalliance.aop.AspectException; +import org.apache.commons.collections.MapUtils; +import org.apache.commons.lang.StringUtils; import org.hibernate.Criteria; import org.hibernate.Hibernate; import org.hibernate.HibernateException; @@ -188,46 +190,53 @@ */ public List<T> findFiltered(T filter) { - return getThis().findFiltered( - filter, - getDefaultFilterMetadata(), - Integer.MAX_VALUE, - 0, - Collections.<Criterion> emptyList(), - getDefaultOrder()); + return getThis().findFiltered(new ExampleTree(filter), Integer.MAX_VALUE, 0, getDefaultOrder()); } /** * {@inheritDoc} */ + public List<T> findFiltered(ExampleTree exampleTree) + { + return getThis().findFiltered(exampleTree, Integer.MAX_VALUE, 0, getDefaultOrder()); + } + + /** + * {@inheritDoc} + */ public List<T> findFiltered(T filter, Order... orders) { - return getThis().findFiltered( - filter, - getDefaultFilterMetadata(), - Integer.MAX_VALUE, - 0, - Collections.<Criterion> emptyList(), - orders); + return getThis().findFiltered(new ExampleTree(filter), Integer.MAX_VALUE, 0, orders); } /** * {@inheritDoc} */ + public List<T> findFiltered(ExampleTree exampleTree, Order... orders) + { + return getThis().findFiltered(exampleTree, Integer.MAX_VALUE, 0, orders); + } + + /** + * {@inheritDoc} + */ public List<T> findFiltered(T filter, int maxResults, int page) { - return getThis().findFiltered( - filter, - getDefaultFilterMetadata(), - maxResults, - page, - Collections.<Criterion> emptyList(), - getDefaultOrder()); + return getThis().findFiltered(new ExampleTree(filter), maxResults, page, getDefaultOrder()); } /** * {@inheritDoc} */ + public List<T> findFiltered(ExampleTree exampleTree, int maxResults, int page) + { + return getThis().findFiltered(exampleTree, maxResults, page, getDefaultOrder()); + } + + /** + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} + */ + @Deprecated public List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata) { return getThis().findFiltered( @@ -240,8 +249,9 @@ } /** - * {@inheritDoc} + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} */ + @Deprecated public List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page) { return getThis().findFiltered( @@ -258,41 +268,41 @@ */ public T findFilteredFirst(T filter) { - return getFirstInCollection(getThis().findFiltered( - filter, - getDefaultFilterMetadata(), - 1, - 0, - Collections.<Criterion> emptyList(), - getDefaultOrder())); + return getFirstInCollection(findFiltered(filter)); } /** * {@inheritDoc} */ + public T findFilteredFirst(ExampleTree exampleTree) + { + return getFirstInCollection(findFiltered(exampleTree)); + } + + /** + * {@inheritDoc} + */ public T findFilteredFirst(T filter, final Order... orders) { - return getFirstInCollection(getThis().findFiltered( - filter, - getDefaultFilterMetadata(), - 1, - 0, - Collections.<Criterion> emptyList(), - orders)); + return getFirstInCollection(findFiltered(filter, orders)); } /** * {@inheritDoc} */ + public T findFilteredFirst(ExampleTree exampleTree, final Order... orders) + { + return getFirstInCollection(findFiltered(exampleTree, orders)); + } + + /** + * {@inheritDoc} + */ public T findFilteredFirst(T filter, List< ? extends Criterion> criteria) { - return getFirstInCollection(getThis().findFiltered( - filter, - getDefaultFilterMetadata(), - 1, - 0, - criteria, - getDefaultOrder())); + ExampleTree exampleTree = new ExampleTree(filter); + appendToRoot(exampleTree, criteria); + return getFirstInCollection(getThis().findFiltered(exampleTree, Integer.MAX_VALUE, 0, getDefaultOrder())); } /** @@ -364,7 +374,6 @@ */ public boolean delete(final K key) { - return getHibernateTemplate().execute(new HibernateCallback<Boolean>() { @@ -374,7 +383,6 @@ return true; } }); - } /** @@ -396,15 +404,15 @@ /** * {@inheritDoc} */ - @SuppressWarnings("unchecked") public T merge(final T obj) { - return (T) getHibernateTemplate().execute(new HibernateCallback() + return getHibernateTemplate().execute(new HibernateCallback<T>() { - public Object doInHibernate(final Session ses) throws HibernateException + @SuppressWarnings("unchecked") + public T doInHibernate(final Session ses) throws HibernateException { - return ses.merge(obj); + return (T) ses.merge(obj); } }); @@ -422,6 +430,15 @@ /** * {@inheritDoc} */ + public List<T> findFiltered(ExampleTree exampleTree, int maxResults, int page, Order... orders) + { + return getHibernateTemplate().execute(new ExampleTreeCallback(exampleTree, orders, maxResults, page)); + } + + /** + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} + */ + @Deprecated public List<T> findFiltered(T filter, Order[] customOrder, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page) { @@ -435,8 +452,9 @@ } /** - * {@inheritDoc} + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} */ + @Deprecated public List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page, Order... orders) { @@ -444,23 +462,38 @@ } /** - * {@inheritDoc} + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} */ + @Deprecated public List<T> findFiltered(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page, List< ? extends Criterion> criteria, Order... orders) { - if (metadata == null || metadata.isEmpty()) + HibernateCallback<List<T>> callback; + if (MapUtils.isNotEmpty(metadata)) { - return getHibernateTemplate().execute(new ExampleTreeCallback(orders, criteria, maxResults, page, filter)); + // backwards compatibility + callback = new HibernateCallbackForExecution( + filter, + page, + maxResults, + metadata, + orders, + criteria, + Collections.<String> emptyList()); } - return getHibernateTemplate().execute( - new HibernateCallbackForExecution(filter, page, maxResults, metadata, orders, criteria, Collections - .<String> emptyList())); + else + { + ExampleTree exampleTree = new ExampleTree(filter); + appendToRoot(exampleTree, criteria); + callback = new ExampleTreeCallback(exampleTree, orders, maxResults, page); + } + return getHibernateTemplate().execute(callback); } /** - * {@inheritDoc} + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} */ + @Deprecated public List< ? > findFilteredProperties(T filter, Map<String, ? extends FilterMetadata> metadata, int maxResults, int page, List< ? extends Criterion> criteria, List<String> properties, Order... orders) { @@ -469,7 +502,7 @@ } /** - * {@inheritDoc} + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} */ @Deprecated public List<T> findFiltered(T filter, Order[] orders, Map<String, ? extends FilterMetadata> metadata, @@ -479,7 +512,7 @@ } /** - * {@inheritDoc} + * @deprecated use of {@link FilterMetadata} has been deprecated {@inheritDoc} */ @Deprecated public List< ? > findFilteredProperties(T filter, Order[] orders, Map<String, ? extends FilterMetadata> metadata, @@ -619,7 +652,7 @@ * @param key the key name * @param value the object to set as the parameter */ - protected void setParameterValue(Query query, String key, Object value) + protected static void setParameterValue(Query query, String key, Object value) { if (null == key || null == value) { @@ -655,6 +688,22 @@ } /** + * appends the input criterions to the input example tree as root entity criterions + * @param exampleTree the example tree + * @param criterions the criterions to append + */ + protected static void appendToRoot(ExampleTree exampleTree, List< ? extends Criterion> criterions) + { + if (criterions != null) + { + for (Criterion crit : criterions) + { + exampleTree.add(StringUtils.EMPTY, crit); + } + } + } + + /** * @return This is needed as for http://opensource.atlassian.com/projects/spring/browse/SPR-2226 */ @SuppressWarnings("unchecked") @@ -687,41 +736,34 @@ private final Order[] orders; - private final List< ? extends Criterion> criteria; - private final int page; private final int maxResults; - private final T filter; + private final ExampleTree exampleTree; - private ExampleTreeCallback( - Order[] orders, - List< ? extends Criterion> criteria, - int maxResults, - int page, - T filter) + private ExampleTreeCallback(ExampleTree exampleTree, Order[] orders, int maxResults, int page) { + this.exampleTree = exampleTree; this.orders = orders; - this.criteria = criteria; this.page = page; this.maxResults = maxResults; - this.filter = filter; } @SuppressWarnings("unchecked") public List<T> doInHibernate(Session session) throws HibernateException, SQLException { - Criteria crit = new ExampleTree(filter).create(session); + Criteria crit = exampleTree.create(session); + + // backwards compatibility + Map<String, ? extends FilterMetadata> filterMetadata = getDefaultFilterMetadata(); + if (MapUtils.isNotEmpty(filterMetadata)) + { + new FilterMetadataSupport(exampleTree.getRootEntity(), filterMetadata).appendTo(crit, session); + } + crit.setMaxResults(maxResults); crit.setFirstResult(maxResults * page); - if (criteria != null) - { - for (Criterion c : criteria) - { - crit.add(c); - } - } if (orders != null) { for (Order o : orders) @@ -734,9 +776,11 @@ } /** + * @deprecated callback implementation that uses EnhancedExample, deprecated in favor of ExampleTreeCallback * @author carone * @version $Id$ */ + @Deprecated private final class HibernateCallbackForExecution implements HibernateCallback<List<T>> { Modified: trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/EnhancedExample.java =================================================================== --- trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/EnhancedExample.java 2011-11-30 12:05:20 UTC (rev 3711) +++ trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/EnhancedExample.java 2011-11-30 15:11:36 UTC (rev 3712) @@ -48,9 +48,12 @@ /** + * @deprecated this example implementation does not take into account hibernate metadata, see BSHD-5. Use ExampleTree + * instead * @author Fabrizio Giustina * @version $Id: $ */ +@Deprecated public final class EnhancedExample { Modified: trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/ExampleTree.java =================================================================== --- trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/ExampleTree.java 2011-11-30 12:05:20 UTC (rev 3711) +++ trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/ExampleTree.java 2011-11-30 15:11:36 UTC (rev 3712) @@ -45,8 +45,8 @@ import org.hibernate.SessionFactory; import org.hibernate.criterion.Criterion; import org.hibernate.criterion.Example; +import org.hibernate.criterion.Example.PropertySelector; import org.hibernate.criterion.MatchMode; -import org.hibernate.criterion.Example.PropertySelector; import org.hibernate.metadata.ClassMetadata; import org.hibernate.type.Type; @@ -244,6 +244,14 @@ return this; } + /** + * @return the rootEntity + */ + public Object getRootEntity() + { + return rootEntity; + } + private class ExampleTreeWalker implements Serializable { Modified: trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/FilterMetadataSupport.java =================================================================== --- trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/FilterMetadataSupport.java 2011-11-30 12:05:20 UTC (rev 3711) +++ trunk/openutils-bshd5/src/main/java/it/openutils/hibernate/example/FilterMetadataSupport.java 2011-11-30 15:11:36 UTC (rev 3712) @@ -32,6 +32,7 @@ import java.util.Map; import java.util.Set; +import org.apache.commons.collections.MapUtils; import org.apache.commons.lang.StringUtils; import org.hibernate.Criteria; import org.hibernate.EntityMode; @@ -106,7 +107,10 @@ public Criteria walk(Criteria rootCriteria, Object rootEntity) { - createSubExamples(rootCriteria, rootEntity, new String[0]); + if (MapUtils.isNotEmpty(filterMetadata)) + { + createSubExamples(rootCriteria, rootEntity, new String[0]); + } return rootCriteria; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <hu...@op...> - 2011-11-30 12:57:14
|
See <https://hudson.openmindonline.it/job/openutils-bshd5/44/changes> |
From: <gca...@us...> - 2011-11-30 12:05:30
|
Revision: 3711 http://openutils.svn.sourceforge.net/openutils/?rev=3711&view=rev Author: gcatania Date: 2011-11-30 12:05:20 +0000 (Wed, 30 Nov 2011) Log Message: ----------- BSHD-2 moving commons-collections dependency from test to compile Modified Paths: -------------- trunk/openutils-bshd5/pom.xml Modified: trunk/openutils-bshd5/pom.xml =================================================================== --- trunk/openutils-bshd5/pom.xml 2011-11-22 21:51:20 UTC (rev 3710) +++ trunk/openutils-bshd5/pom.xml 2011-11-30 12:05:20 UTC (rev 3711) @@ -154,6 +154,11 @@ </exclusions> </dependency> <dependency> + <groupId>commons-collections</groupId> + <artifactId>commons-collections</artifactId> + <version>3.2.1</version> + </dependency> + <dependency> <groupId>commons-lang</groupId> <artifactId>commons-lang</artifactId> <version>2.4</version> @@ -165,12 +170,6 @@ </dependency> <!-- test dependencies --> <dependency> - <groupId>commons-collections</groupId> - <artifactId>commons-collections</artifactId> - <version>3.2.1</version> - <scope>test</scope> - </dependency> - <dependency> <groupId>commons-dbcp</groupId> <artifactId>commons-dbcp</artifactId> <version>1.2.1</version> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-22 21:51:26
|
Revision: 3710 http://openutils.svn.sourceforge.net/openutils/?rev=3710&view=rev Author: fgiust Date: 2011-11-22 21:51:20 +0000 (Tue, 22 Nov 2011) Log Message: ----------- fixed "flash version" label Modified Paths: -------------- trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties Modified: trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties 2011-11-20 20:47:30 UTC (rev 3709) +++ trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties 2011-11-22 21:51:20 UTC (rev 3710) @@ -58,12 +58,12 @@ media.types.swf=SWF -media.types.image.load=Upload a new image -media.types.audio.load=Upload a new mp3 -media.types.youtube.load=Link an external video -media.types.video.load=Upload a flv/mp4 video -media.types.document.load=Upload a new document -media.types.swf.load=Upload a new SWF +media.types.image.load=New image +media.types.audio.load=New mp3 +media.types.youtube.load=New external video +media.types.video.load=New flv/mp4 video +media.types.document.load=New document +media.types.swf.load=New SWF media.download=Download media.edit=Edit @@ -107,6 +107,7 @@ media.info.media_framerate=Frame rate: {0} fps media.info.media_pages= Number of pages: {0} media.info.media_name= File name: {0} +media.info.media_flashversion=Flash version: {0} media.bgselector.white=White media.bgselector.transparent=Transparent @@ -173,6 +174,5 @@ media.dialogs.tabSwf.video.label=SWF file media.dialogs.tabSwf.image.label=Alternative image media.dialogs.mediaSwfDlg.tabSwf.image.description=The image will be shown if the browser doesn''t support flash -media.info.media_flashversion=Flash version media.types.all=All Modified: trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties 2011-11-20 20:47:30 UTC (rev 3709) +++ trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties 2011-11-22 21:51:20 UTC (rev 3710) @@ -109,6 +109,7 @@ media.info.media_framerate=Frame rate: {0} fps media.info.media_pages= Numero di pagine: {0} media.info.media_name= Nome file: {0} +media.info.media_flashversion=Versione Flash: {0} media.bgselector.white=Bianco @@ -176,7 +177,6 @@ media.dialogs.tabSwf.video.label=File SWF media.dialogs.tabSwf.image.label=Immagine alternativa media.dialogs.mediaSwfDlg.tabSwf.image.description=L''immagine sar\xE0 visualizzata se il browser non supporta flash -media.info.media_flashversion=Versione Flash media.types.all=Tutti This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 20:47:37
|
Revision: 3709 http://openutils.svn.sourceforge.net/openutils/?rev=3709&view=rev Author: fgiust Date: 2011-11-20 20:47:30 +0000 (Sun, 20 Nov 2011) Log Message: ----------- [maven-release-plugin] prepare for next development iteration Modified Paths: -------------- trunk/openutils-mgnlmedia/pom.xml Modified: trunk/openutils-mgnlmedia/pom.xml =================================================================== --- trunk/openutils-mgnlmedia/pom.xml 2011-11-20 20:47:14 UTC (rev 3708) +++ trunk/openutils-mgnlmedia/pom.xml 2011-11-20 20:47:30 UTC (rev 3709) @@ -10,7 +10,7 @@ <artifactId>openutils-mgnlmedia</artifactId> <name>SimpleMedia Module for Magnolia CMS</name> <description>SimpleMedia Module for Magnolia CMS: a module for Magnolia CMS for easier management of multimedia assets.</description> - <version>4.5.0</version> + <version>4.5.1-SNAPSHOT</version> <inceptionYear>2008</inceptionYear> <licenses> <license> @@ -24,9 +24,9 @@ <url>http://jira.openmindlab.com/browse/MEDIA</url> </issueManagement> <scm> - <connection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/tags/openutils-mgnlmedia-4.5.0</connection> - <developerConnection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/tags/openutils-mgnlmedia-4.5.0</developerConnection> - <url>http://openutils.svn.sourceforge.net/viewcvs.cgi/openutils/tags/openutils-mgnlmedia-4.5.0</url> + <connection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/trunk/openutils-mgnlmedia</connection> + <developerConnection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/trunk/openutils-mgnlmedia</developerConnection> + <url>http://openutils.svn.sourceforge.net/viewcvs.cgi/openutils/trunk/openutils-mgnlmedia</url> </scm> <build> <resources> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 20:47:20
|
Revision: 3708 http://openutils.svn.sourceforge.net/openutils/?rev=3708&view=rev Author: fgiust Date: 2011-11-20 20:47:14 +0000 (Sun, 20 Nov 2011) Log Message: ----------- [maven-release-plugin] copy for tag openutils-mgnlmedia-4.5.0 Added Paths: ----------- tags/openutils-mgnlmedia-4.5.0/ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 20:46:51
|
Revision: 3707 http://openutils.svn.sourceforge.net/openutils/?rev=3707&view=rev Author: fgiust Date: 2011-11-20 20:46:44 +0000 (Sun, 20 Nov 2011) Log Message: ----------- [maven-release-plugin] prepare release openutils-mgnlmedia-4.5.0 Modified Paths: -------------- trunk/openutils-mgnlmedia/pom.xml Modified: trunk/openutils-mgnlmedia/pom.xml =================================================================== --- trunk/openutils-mgnlmedia/pom.xml 2011-11-20 20:46:03 UTC (rev 3706) +++ trunk/openutils-mgnlmedia/pom.xml 2011-11-20 20:46:44 UTC (rev 3707) @@ -1,5 +1,4 @@ -<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"> +<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"> <parent> <groupId>net.sourceforge.openutils</groupId> <artifactId>openutils-parent</artifactId> @@ -11,7 +10,7 @@ <artifactId>openutils-mgnlmedia</artifactId> <name>SimpleMedia Module for Magnolia CMS</name> <description>SimpleMedia Module for Magnolia CMS: a module for Magnolia CMS for easier management of multimedia assets.</description> - <version>4.4.3-SNAPSHOT</version> + <version>4.5.0</version> <inceptionYear>2008</inceptionYear> <licenses> <license> @@ -25,9 +24,9 @@ <url>http://jira.openmindlab.com/browse/MEDIA</url> </issueManagement> <scm> - <connection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/trunk/openutils-mgnlmedia</connection> - <developerConnection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/trunk/openutils-mgnlmedia</developerConnection> - <url>http://openutils.svn.sourceforge.net/viewcvs.cgi/openutils/trunk/openutils-mgnlmedia</url> + <connection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/tags/openutils-mgnlmedia-4.5.0</connection> + <developerConnection>scm:svn:https://openutils.svn.sourceforge.net/svnroot/openutils/tags/openutils-mgnlmedia-4.5.0</developerConnection> + <url>http://openutils.svn.sourceforge.net/viewcvs.cgi/openutils/tags/openutils-mgnlmedia-4.5.0</url> </scm> <build> <resources> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 20:46:09
|
Revision: 3706 http://openutils.svn.sourceforge.net/openutils/?rev=3706&view=rev Author: fgiust Date: 2011-11-20 20:46:03 +0000 (Sun, 20 Nov 2011) Log Message: ----------- update assembly descriptor Modified Paths: -------------- trunk/openutils-mgnlmedia/src/main/assembly/assembly-bundle.xml Modified: trunk/openutils-mgnlmedia/src/main/assembly/assembly-bundle.xml =================================================================== --- trunk/openutils-mgnlmedia/src/main/assembly/assembly-bundle.xml 2011-11-20 20:39:15 UTC (rev 3705) +++ trunk/openutils-mgnlmedia/src/main/assembly/assembly-bundle.xml 2011-11-20 20:46:03 UTC (rev 3706) @@ -35,6 +35,7 @@ <include>commons-cli:commons-cli:*</include> <include>org.jboss.netty:netty:*</include> <include>nl.ikarus.nxt.priv.imageio.icoreader:*</include> + <include>org.freehep:*</include> </includes> </dependencySet> </dependencySets> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 20:39:21
|
Revision: 3705 http://openutils.svn.sourceforge.net/openutils/?rev=3705&view=rev Author: fgiust Date: 2011-11-20 20:39:15 +0000 (Sun, 20 Nov 2011) Log Message: ----------- MEDIA-274 handling of size and preview image Modified Paths: -------------- trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag Modified: trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag 2011-11-20 20:21:47 UTC (rev 3704) +++ trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag 2011-11-20 20:39:15 UTC (rev 3705) @@ -185,8 +185,28 @@ <c:if test="${!(height gt 0)}"> <c:set var="height" value="${media:height(mediaNode)}" /> </c:if> - - <media:swfobject player="${pageContext.request.contextPath}${media:url(mediaNode)}" width="${width gt 0 ? width : ''}" height="${height gt 0? height : ''}" image="${thumbnail}"/> + + <c:choose> + <c:when test="${width gt 0 and height gt 0}"> + <c:set var="previewres" value="${width}x${height}" /> + <c:set var="preview" value="${media:urlres(mediaNode, previewres)}" /> + </c:when> + <c:otherwise> + <c:set var="preview" value="${media:thumbnail(mediaNode)}" /> + </c:otherwise> + </c:choose> + + <c:if test="${!empty preview}"> + <c:set var="preview" value="${pageContext.request.contextPath}${preview}" /> + </c:if> + + <media:swfobject + player="${pageContext.request.contextPath}${media:url(mediaNode)}" + width="${width gt 0 ? width : ''}" + height="${height gt 0? height : ''}" + image="${preview}" + title="${mediaNode.title}" + /> </c:when> </c:choose> Modified: trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag 2011-11-20 20:21:47 UTC (rev 3704) +++ trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag 2011-11-20 20:39:15 UTC (rev 3705) @@ -7,6 +7,7 @@ <jsp:directive.attribute name="width" required="false" rtexprvalue="true" type="java.lang.Integer" description="flash content width" /> <jsp:directive.attribute name="height" required="false" rtexprvalue="true" type="java.lang.Integer" description="flash content height" /> <jsp:directive.attribute name="image" required="false" rtexprvalue="true" description="replacement image" /> + <jsp:directive.attribute name="title" required="false" rtexprvalue="true" description="title/alt" /> <jsp:directive.tag dynamic-attributes="attrs" /> <!-- end attributes --> @@ -14,6 +15,9 @@ <c:set var="debug" value="${false}"/><!-- set to true to print out the generated javascript on page --> <c:set var="previewId" value="preview-${su:randomAlphanumeric(6)}" /> <div id="${previewId}" class="preview"><!-- --> + <c:if test="${!empty image}"> + <img src="${image}" width="${width}" height="${height}" alt="${title}" /> + </c:if> </div> <c:if test="${empty requestScope['mgnlmedia_swfobject_link_drawn']}"> <script type="text/javascript" src="${pageContext.request.contextPath}/.resources/media/js/swfobject.js"><!-- --> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 20:21:54
|
Revision: 3704 http://openutils.svn.sourceforge.net/openutils/?rev=3704&view=rev Author: fgiust Date: 2011-11-20 20:21:47 +0000 (Sun, 20 Nov 2011) Log Message: ----------- MEDIA-274 sample swf Modified Paths: -------------- trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/website.sample-simplemedia.xml Modified: trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/website.sample-simplemedia.xml =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/website.sample-simplemedia.xml 2011-11-20 20:20:50 UTC (rev 3703) +++ trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/website.sample-simplemedia.xml 2011-11-20 20:21:47 UTC (rev 3704) @@ -3,7 +3,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:content</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -45,7 +45,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -70,7 +70,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -100,7 +100,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -137,7 +137,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -180,7 +180,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -217,7 +217,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -260,7 +260,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -303,7 +303,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -340,7 +340,7 @@ <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>mgnl:contentNode</sv:value> </sv:property> - <sv:property sv:name="jcr:mixinTypes" sv:type="Name"> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> <sv:value>mix:lockable</sv:value> </sv:property> <sv:property sv:name="jcr:uuid" sv:type="String"> @@ -384,4 +384,254 @@ </sv:node> </sv:node> </sv:node> + <sv:node sv:name="videoplayer"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>b3bb22ac-caa7-4f3d-851c-0c59030f8a9b</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Simplemedia videoplayer test</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-07-01T17:59:08.549+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-07-01T18:00:05.104+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>sampleSimpleMedia</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="main"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>0fb927f1-6e81-4032-9c64-41691d14bfc2</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-07-01T17:59:47.625+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-07-01T18:00:01.156+02:00</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="00"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>91104922-6d1d-4ac4-b4b7-223190700b0d</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="media" sv:type="String"> + <sv:value>d39f582f-3d53-46ae-95d9-42f778198503</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-07-01T18:00:01.154+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-07-01T18:00:01.156+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>samples-mediatag</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="0"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>17cf262c-cefa-4558-8ec5-7bbe3f9ef2c2</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="media" sv:type="String"> + <sv:value>53c45fb5-3cda-414e-8be5-2647fb8b9697</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-07-01T17:59:47.626+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-07-01T17:59:47.630+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>samples-mediatag</sv:value> + </sv:property> + </sv:node> + </sv:node> + </sv:node> + </sv:node> + <sv:node sv:name="swf"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:content</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>3612e425-1cde-43d5-86d6-f5627c7705f7</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="title" sv:type="String"> + <sv:value>Simplemedia swf test</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-07-01T17:59:08.549+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-20T21:20:30.928+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>sampleSimpleMedia</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="main"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>85faedd0-fa60-497e-b46d-6ac7789a0820</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-07-01T17:59:47.625+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-20T21:20:30.927+01:00</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="00"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>8adc574c-b6ac-47ec-97a1-545e88f478c7</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="media" sv:type="String"> + <sv:value>41f81027-183f-4860-9d88-fcc3a6c5ce05</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-07-01T18:00:01.154+02:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-20T21:20:30.927+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:template" sv:type="String"> + <sv:value>samples-mediatag</sv:value> + </sv:property> + </sv:node> + </sv:node> + </sv:node> + </sv:node> </sv:node> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 20:20:59
|
Revision: 3703 http://openutils.svn.sourceforge.net/openutils/?rev=3703&view=rev Author: fgiust Date: 2011-11-20 20:20:50 +0000 (Sun, 20 Nov 2011) Log Message: ----------- MEDIA-274 parsing of swf metadata Modified Paths: -------------- trunk/openutils-mgnlmedia/pom.xml trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/media.samples.xml trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties Modified: trunk/openutils-mgnlmedia/pom.xml =================================================================== --- trunk/openutils-mgnlmedia/pom.xml 2011-11-20 17:59:29 UTC (rev 3702) +++ trunk/openutils-mgnlmedia/pom.xml 2011-11-20 20:20:50 UTC (rev 3703) @@ -1,4 +1,5 @@ -<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"> +<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"> <parent> <groupId>net.sourceforge.openutils</groupId> <artifactId>openutils-parent</artifactId> @@ -227,6 +228,26 @@ <artifactId>isoparser</artifactId> <version>1.0-beta-3</version> </dependency> + <dependency> + <groupId>org.devlib.schmidt</groupId> + <artifactId>imageinfo</artifactId> + <version>1.9</version> + </dependency> + <dependency> + <groupId>org.freehep</groupId> + <artifactId>freehep-graphicsio-swf</artifactId> + <version>2.1.3</version> + <exclusions> + <exclusion> + <groupId>org.freehep</groupId> + <artifactId>freehep-graphics2d</artifactId> + </exclusion> + <exclusion> + <groupId>org.freehep</groupId> + <artifactId>freehep-graphicsio-tests</artifactId> + </exclusion> + </exclusions> + </dependency> </dependencies> <properties> <magnolia.version>4.4.4</magnolia.version> Modified: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java 2011-11-20 17:59:29 UTC (rev 3702) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java 2011-11-20 20:20:50 UTC (rev 3703) @@ -45,19 +45,9 @@ */ public String getThumbnailUrl(Content media) { - boolean hasPreview = false; - try + if (hasPreview(media)) { - hasPreview = media.hasNodeData(PREVIEW_NODEDATA_NAME); - } - catch (RepositoryException e) - { - // ignore - } - - if (hasPreview) - { if (!ImageUtils.checkOrCreateResolution(media, "thumbnail", PREVIEW_NODEDATA_NAME)) { return ""; @@ -76,6 +66,24 @@ public abstract String getReplacementThumbnail(); + protected boolean hasPreview(Content media) + { + + if (media != null) + { + try + { + return media.hasNodeData(PREVIEW_NODEDATA_NAME); + } + catch (RepositoryException e) + { + // ignore + } + } + + return false; + } + @Override public String getPreviewImageNodeDataName() { Modified: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java 2011-11-20 17:59:29 UTC (rev 3702) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java 2011-11-20 20:20:50 UTC (rev 3703) @@ -22,10 +22,13 @@ import info.magnolia.cms.core.Content; import info.magnolia.cms.util.NodeDataUtil; +import java.awt.Dimension; import java.io.InputStream; import org.apache.commons.io.IOUtils; import org.devlib.schmidt.imageinfo.ImageInfo; +import org.freehep.graphicsio.swf.SWFHeader; +import org.freehep.graphicsio.swf.SWFInputStream; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -50,15 +53,43 @@ try { stream = getOriginalFileNodeData(media).getStream(); - ImageInfo ii = new ImageInfo(); - ii.setInput(stream); - if (ii.check()) + + Dimension dimension = null; + Integer flashversion = null; + try { - NodeDataUtil.getOrCreateAndSet(media, METADATA_WIDTH, ii.getWidth()); - NodeDataUtil.getOrCreateAndSet(media, METADATA_HEIGHT, ii.getHeight()); + SWFInputStream swfinput = new SWFInputStream(stream); + SWFHeader header = new SWFHeader(swfinput); + dimension = header.getSize(); + flashversion = header.getVersion(); + } + catch (Throwable e) + { + log.warn("Unable to parse swf header: " + e.getClass().getName() + " " + e.getMessage()); + } + + if (dimension != null) + { + NodeDataUtil.getOrCreateAndSet(media, METADATA_WIDTH, dimension.getWidth()); + NodeDataUtil.getOrCreateAndSet(media, METADATA_HEIGHT, dimension.getHeight()); + NodeDataUtil.getOrCreateAndSet(media, "media_flashversion", flashversion); media.save(); } + else if (hasPreview(media)) + { + IOUtils.closeQuietly(stream); + stream = media.getNodeData(getPreviewImageNodeDataName()).getStream(); + ImageInfo ii = new ImageInfo(); + ii.setInput(stream); + if (ii.check()) + { + NodeDataUtil.getOrCreateAndSet(media, METADATA_WIDTH, ii.getWidth()); + NodeDataUtil.getOrCreateAndSet(media, METADATA_HEIGHT, ii.getHeight()); + media.save(); + } + } + } catch (Throwable e) { Modified: trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag 2011-11-20 17:59:29 UTC (rev 3702) +++ trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/media.tag 2011-11-20 20:20:50 UTC (rev 3703) @@ -177,6 +177,18 @@ </c:when> + <c:when test="${media.type eq 'swf' }"> + + <c:if test="${!(width gt 0)}"> + <c:set var="width" value="${media:width(mediaNode)}" /> + </c:if> + <c:if test="${!(height gt 0)}"> + <c:set var="height" value="${media:height(mediaNode)}" /> + </c:if> + + <media:swfobject player="${pageContext.request.contextPath}${media:url(mediaNode)}" width="${width gt 0 ? width : ''}" height="${height gt 0? height : ''}" image="${thumbnail}"/> + </c:when> + </c:choose> </c:when> <c:when test="${!empty property and fn:startsWith(item, '/')}"> Modified: trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag 2011-11-20 17:59:29 UTC (rev 3702) +++ trunk/openutils-mgnlmedia/src/main/resources/META-INF/tags/media/swfobject.tag 2011-11-20 20:20:50 UTC (rev 3703) @@ -6,6 +6,7 @@ <jsp:directive.attribute name="player" required="true" rtexprvalue="true" type="java.lang.String" description="the swf file of the player (examples: player.swf (default), jwplayer4, jwplayer5, jwplayer5/player.swf, /.resources/media/players/jwplayer5/player.swf)" /> <jsp:directive.attribute name="width" required="false" rtexprvalue="true" type="java.lang.Integer" description="flash content width" /> <jsp:directive.attribute name="height" required="false" rtexprvalue="true" type="java.lang.Integer" description="flash content height" /> + <jsp:directive.attribute name="image" required="false" rtexprvalue="true" description="replacement image" /> <jsp:directive.tag dynamic-attributes="attrs" /> <!-- end attributes --> Modified: trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/media.samples.xml =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/media.samples.xml 2011-11-20 17:59:29 UTC (rev 3702) +++ trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap-samples/media/media.samples.xml 2011-11-20 20:20:50 UTC (rev 3703) @@ -151,6 +151,72 @@ <sv:value>320</sv:value> </sv:property> </sv:node> + <sv:node sv:name="resolutions"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:resolutions</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>ec963fa4-00f5-4efd-8aa2-bdbf8e609bc9</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-11-20T21:13:52.626+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-20T21:13:52.627+01:00</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="thumbnail"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:resource</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>90544e4e-942d-475b-a636-b361a138d6a5</sv:value> + </sv:property> + <sv:property sv:name="extension" sv:type="String"> + <sv:value>jpg</sv:value> + </sv:property> + <sv:property sv:name="fileName" sv:type="String"> + <sv:value>bliptv</sv:value> + </sv:property> + <sv:property sv:name="height" sv:type="String"> + <sv:value>75</sv:value> + </sv:property> + <sv:property sv:name="jcr:data" sv:type="Binary"> + <sv:value>/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCABLAGQDASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJm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f8f9+I//AImj/hN/EOP+Qh/5Aj/+Jp8oz1PzLz+7Bn/rmP8A4ul8y9/uwf8Afsf/ABdeV/8ACb+If+gh/wCQI/8A4mj/AITfxDj/AJCH/kCP/wCJp2A9TMl6BkpBj18sf/F1AyXEjscoGc9FJHp6SewrzI+NvEH/AD/j/vxH/wDE0h8b+If+ggP+/Ef/AMTSswPUo2ukQIvkn6qCfzL1q6c00FusDW0g6kuSMZJz0z714yPG3iDP/H+P+/Ef/wATUg8a+IMf8f4/78R//E0WYDfjLH5PiSyj/u2Kf+jJKK8/+IniHVL7WoJbq53uLdVB8tBxub0HvRRZgf/Z</sv:value> + </sv:property> + <sv:property sv:name="jcr:lastModified" sv:type="Date"> + <sv:value>2011-11-20T21:13:52.668+01:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:lastModifiedBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="jcr:mimeType" sv:type="String"> + <sv:value>image/jpeg</sv:value> + </sv:property> + <sv:property sv:name="resolution" sv:type="String"> + <sv:value>thumbnail</sv:value> + </sv:property> + <sv:property sv:name="size" sv:type="String"> + <sv:value>2394</sv:value> + </sv:property> + <sv:property sv:name="width" sv:type="String"> + <sv:value>100</sv:value> + </sv:property> + </sv:node> + </sv:node> </sv:node> <sv:node sv:name="swiss-cow"> <sv:property sv:name="jcr:primaryType" sv:type="Name"> @@ -253,6 +319,110 @@ <sv:value>800</sv:value> </sv:property> </sv:node> + <sv:node sv:name="resolutions"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:resolutions</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>7d4e22de-0831-465d-b11e-028494a6f3b4</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-11-20T21:13:53.269+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-20T21:13:53.270+01:00</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="thumbnail"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:resource</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>c978ccb7-d81c-4ba5-af70-f12b53cc4902</sv:value> + </sv:property> + <sv:property sv:name="extension" sv:type="String"> + <sv:value>jpg</sv:value> + </sv:property> + <sv:property sv:name="fileName" sv:type="String"> + <sv:value>swiss-cow</sv:value> + </sv:property> + <sv:property sv:name="height" sv:type="String"> + <sv:value>75</sv:value> + </sv:property> + <sv:property sv:name="jcr:data" sv:type="Binary"> + <sv:value>/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCABLAGQDASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW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APTnmtv4dzyTadqMspDSRn5WwMjg18zUxEsRR1PpYUVRq6bnoaxxpC8g27erN6VmXkNjbaJcEBGVY2YsDy3GfzzVHxTPJF4buGjcqcjp7sK89tLmYS3EHmN5LhWZOxO4dq5fZ3jznXGXvcpueF9Jluimo3Uhc28xkEWCdwBBwP5Yp9lpt/bu9zfafI8G0k71Ixk9QR0Nb2mzyWOk6PLaMI5JJkDEAHIOc9a7zVkCwRSplHLDJUlc8HrjrXoYOK5XJnHiZNysjzy0k1zS8vE832aZGU+WxI2ngjjpwf5+tdT4W1Wxe4NzeTvJdhuC5OAT3J6n0qjqUjBLTaQnmsN+wbc/lWheWsDTOrQxkDn7vP8AFXRKMXJSkti6WJq06M6NOVlLfv56+fU7NNQ85D5ZAz3CZ/KnmSV0YLJJwOpXBP6V5jFNLp1/mxllg3A52ORmvWfC08l7okE90wklbOWIAzz7V1yqWVzy1QTdjHW7fmCHJcMcgtjJ9KSS01iWZnDOm7oqyYA/Cutt4o3mUMinn0qxcxojkKoApe210RX1ddWcvDBrAjAZYmI7nrRXTKBiip9q+xXsV3P/2Q==</sv:value> + </sv:property> + <sv:property sv:name="jcr:lastModified" sv:type="Date"> + <sv:value>2011-11-20T21:13:53.276+01:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:lastModifiedBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="jcr:mimeType" sv:type="String"> + <sv:value>image/jpeg</sv:value> + </sv:property> + <sv:property sv:name="resolution" sv:type="String"> + <sv:value>thumbnail</sv:value> + </sv:property> + <sv:property sv:name="size" sv:type="String"> + <sv:value>2407</sv:value> + </sv:property> + <sv:property sv:name="width" sv:type="String"> + <sv:value>100</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="preview"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:resource</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>8f965773-e489-45da-b15b-10f31f4fbce9</sv:value> + </sv:property> + <sv:property sv:name="extension" sv:type="String"> + <sv:value>jpg</sv:value> + </sv:property> + <sv:property sv:name="fileName" sv:type="String"> + <sv:value>swiss-cow</sv:value> + </sv:property> + <sv:property sv:name="height" sv:type="String"> + <sv:value>338</sv:value> + </sv:property> + <sv:property sv:name="jcr:data" sv:type="Binary"> + <sv:value>/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCAFSAcIDASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna4uPk5ebn6Onq8vP09fb3+Pn6/9oADAMBAAIRAxEAPwDgcUmKkxxxSYr7U+XGEUYp+KMUDuMxRin4FIRQFxuKCKdilxQFx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cPWmalo8p2eUpIHHFdgoHJpCoHSqVWV7k+yVjmrOz1GKIIs7qgOeRk/Tmtm1Ewi/fDL+vTNaMMIf71Wks16nNTKpfcpU7GYoPdSKXYT2q/NbhTwMVEUK9qm5fKV1jxyaUKtS4zSbKYrDdv1NSKDjk0mKeBxSHYTLetFP4opXGfNEjsLhAGOCxyM0kpykOeeQefXFFFfIQ+JHuvZnL+MEUalbuFAZ4iWIHLHPesSU/LJ/u/8AstFFe7S+GJ5M/iYtoAYJsjP7o1kr/wAfEdFFbw6mb3PQPABI1GPB6q2ff7tensOF+lFFcdX4mdkNkZPi7/kW9R/69n/9BNSaWSdHsSSSTBHk+vyCiis+iHHcuWRJdsnsKSQncee/+FFFJ7Gh5p8R2P8AaFmMnHzHr7isaP8A1f8AwE0UV6VD+FE4KvxssW3MDg9OeKzJQBniiiufF/Gjqwvws2dL/wCQdMO240WxP9nt9MUUVzHQzX8KAG8jyAeP616S/wDqz/uiiil1ZEjI8QEjw/fEHB8pBn/tolcFHw649qKK9HBfCzgxXxI77wdLIRKDI+AeBuPvXdWZJXkmiiulkdC7J0qncKrdVB+oooq0ZyM/UvlaLbxkgHH1ritPdvN+8enr70UVK3KWyN6BmK8k/nWTqfIfNFFUtxPYwGAWNsDHXp+FdV4KlkYOGdiPKUYJ7Yc0UUq3wjofEbsIAMxxyJOKyoiftF1/11X+S0UVlHqbvoWb7/XAdjKMj/gJpYySoyc/WiiqRLK9+o+zHgcj/GmbRuj4HKCiitFsZSObQASS4A6n+tWOkfHp/SiiuhnNEs6eT9oTnpnFTWU0ttfzm3keIlHBKMVyPwoopPqaR3R7RaktbISSSR1NT9jRRXIzcb2NQOeaKKtEsUU5epooqgLdt2q9F92iis5bjIZfvVWn+9RRTQMibtSUUVZIop4/pRRSYx+KKKKkD//Z</sv:value> + </sv:property> + <sv:property sv:name="jcr:lastModified" sv:type="Date"> + <sv:value>2011-11-20T21:13:53.318+01:00</sv:value> + </sv:property> + <sv:property sv:name="jcr:lastModifiedBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="jcr:mimeType" sv:type="String"> + <sv:value>image/jpeg</sv:value> + </sv:property> + <sv:property sv:name="resolution" sv:type="String"> + <sv:value>preview</sv:value> + </sv:property> + <sv:property sv:name="size" sv:type="String"> + <sv:value>21735</sv:value> + </sv:property> + <sv:property sv:name="width" sv:type="String"> + <sv:value>450</sv:value> + </sv:property> + </sv:node> + </sv:node> </sv:node> <sv:node sv:name="music0"> <sv:property sv:name="jcr:primaryType" sv:type="Name"> @@ -480,6 +650,72 @@ <sv:value>100</sv:value> </sv:property> </sv:node> + <sv:node sv:name="resolutions"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:resolutions</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>b2b4fd2f-b101-4469-a591-4ed71fe8555c</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2011-11-20T21:13:53.097+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-20T21:13:53.098+01:00</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="thumbnail"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:resource</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>a66bb295-1a71-4a68-96af-b6b80c34b0cf</sv:value> + </sv:property> + <sv:property sv:name="extension" sv:type="String"> + <sv:value>png</sv:value> + </sv:property> + <sv:property sv:name="fileName" sv:type="String"> + <sv:value>sampleflv</sv:value> + </sv:property> + <sv:property sv:name="height" sv:type="String"> + <sv:value>80</sv:value> + </sv:property> + <sv:property sv:name="jcr:data" sv:type="Binary"> + <sv:value>iVBORw0KGgoAAAANSUhEUgAAAGQAAABQCAIAAABga0e4AABNbklEQVR42qS7B1Si99r26/rOet+9kyn2AgJSBAUBERURRSwUkaKiiFiw997b2B177whi7zo9ZSaT3rNTdpJJZpLMZDLpmUzPVMdybjQ77z7v933nO2udJ/d61p9HBJ4f133d198928SDyYHy5QQKBdJgkVzADxYKxWHyKEV4bFxMaqw6JTen7NSJc8+fef3c2fdeeOndF1768OTZj868cWHj/Me6tfO69Ze7Jta7tWutfXNaw4k33//yxoOdn2/v/HJn++c/dn97tHt7e/fm5u61e1vf3N26/MfOXu1++3D36qM/67uHu/+6vnPlj93Ld3cv3dq9eHP34o3di9d3v/h9e7++vLHz+a2dL+7sfnn3v+rrB7uXH+xevb97+d725T+2r9zfuf509+e7m/+48P35dz+SxCZGp2SnZBccf/6FiZmpgfHRjTOn1k4e//TiF2/94/26o82dA30CmVAc4ScK91NoZPzIQLFa2dA3tHT23MDi8s+Pn/62ufvz5u6P23+WiUgogwJSoXJllDI+JiZeFaVWKePV0UlJiVnxcWlJCVnzcxsvPv/mS+eMsJ4798GxFz4YXzpb3zdd3aWv652ePfnm8nPv6RfO6qZPvf7OhZsPd/dh/XR396c/dn++v/vjve2rd57+/4EFpP4/wvr50e6Pt59c+fne/MlzbWP6guqm7qHxuJQ0WaRCGRdTWlNZ1VAbn5ocnRgvlEn8RQKhXCwI5XkHsjx5nkHhfElsdIg6vra3//1vv/vlyc5/hwVqgpJKFNIQhSY+NT0tKy01Iz01NyOtIC+nLCE+I0SsCJWpjjb3nTz+yvPn3jlz9v2T5z7Sr55vHVkqbxuHqunULz//3ouvX3jh/Mfdg1MdAxMfX7x2/d7Wz/e2r93a+u7W06s3Nq/cevI18Lq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Dwxpbe452DqriUrl+opam7sqKBok4AroS9km93aNXr/wEsODY2tl9sLP7+xOjJf362Biyf7ize/X29jfXn/RNrvePrydm1MUkV8WlVkfGFRfX9A5Pnfrwm1+uwnP+2AVe4GvGerh75aExfLxx8bu04gpVfIxI7E92QdPoRLqrC+Ch0WgkEsnR0RG9d+DxeDQaY2Nr39k7eub8W+unXzn9wts//nDrzOlzvr6+dFcy052Kw9vbISxsbM3sUdZQSHsrO6QFnDEOdvAjR6IDmexMdsHTGY4+XIYTGW1y8uTJ1dXV4eHhyb1jZWVlfX19Y2NjaWkJeBkMhoWFxZGRia7OQWVEvFgU3lDXDuG+pLgmSCCrP9rd1j0EsPwDQgb6tUdbegBWUkJWdlZxZ/vg99/9alTWDihr9z7I6uE2ZMufHmz9+sfWL/dgW/N0bOn5yqMjBZVd0QllUZrSuNQadVJFbFpNdGpVSEx+XF5j99T6axe+/f7B1rUHRoMDWF/e3bp678n6i+fDoiK4PBYMKYBFciIAGgwGg8PhsFis/d7h4IBBoxH2aFRads6Q3tA5oO8dnH75/PtvvfkPgY... [truncated message content] |
From: <fg...@us...> - 2011-11-20 17:59:36
|
Revision: 3702 http://openutils.svn.sourceforge.net/openutils/?rev=3702&view=rev Author: fgiust Date: 2011-11-20 17:59:29 +0000 (Sun, 20 Nov 2011) Log Message: ----------- MEDIA-274 SWF alt image and refactoring of existing mediatypes with preview Modified Paths: -------------- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/BaseVideoTypeHandler.java trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/DocumentTypeHandler.java trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java Added Paths: ----------- trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/thumb-swf.png trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/thumb-video.png Modified: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/BaseVideoTypeHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/BaseVideoTypeHandler.java 2011-11-20 17:24:32 UTC (rev 3701) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/BaseVideoTypeHandler.java 2011-11-20 17:59:29 UTC (rev 3702) @@ -107,4 +107,10 @@ return info; } + @Override + public String getReplacementThumbnail() + { + return "/.resources/media/icons/thumb-video.png"; + } + } Modified: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/DocumentTypeHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/DocumentTypeHandler.java 2011-11-20 17:24:32 UTC (rev 3701) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/DocumentTypeHandler.java 2011-11-20 17:59:29 UTC (rev 3702) @@ -37,9 +37,6 @@ import javax.jcr.PropertyType; import javax.jcr.RepositoryException; -import net.sourceforge.openutils.mgnlmedia.media.configuration.MediaConfigurationManager; -import net.sourceforge.openutils.mgnlmedia.media.utils.ImageUtils; - import org.apache.commons.io.IOUtils; import org.apache.commons.lang.StringUtils; import org.apache.pdfbox.pdmodel.PDDocument; @@ -53,15 +50,10 @@ * @author dschivo * @version $Id$ */ -public class DocumentTypeHandler extends BaseTypeHandler +public class DocumentTypeHandler extends MediaWithPreviewImageTypeHandler { /** - * Nodedata name where preview media content is saved - */ - public static final String PREVIEW_NODEDATA_NAME = "image"; - - /** * metadata containing the number of pages */ private static final String METADATA_PAGES = "media_pages"; @@ -74,35 +66,6 @@ /** * {@inheritDoc} */ - public String getThumbnailUrl(Content media) - { - try - { - // check if a thumbnail has been generated - if (media == null - || !media.hasNodeData(PREVIEW_NODEDATA_NAME) - || !ImageUtils.checkOrCreateResolution(media, "thumbnail", PREVIEW_NODEDATA_NAME)) - { - return "/.resources/media/icons/thumb-document.png"; - } - } - catch (RepositoryException e) - { - return "/.resources/media/icons/thumb-document.png"; - } - - return MediaConfigurationManager.getInstance().getURIMappingPrefix() - + media.getHandle() - + "/resolutions/thumbnail/" - + media.getName() - + "." - + ImageUtils.getExtension(media, "thumbnail"); - - } - - /** - * {@inheritDoc} - */ @Override public String getUrl(Content media) { @@ -175,7 +138,7 @@ PDPage page = pages.get(0); - java.awt.image.BufferedImage image = page.convertToImage(BufferedImage.TYPE_INT_ARGB, 36); + java.awt.image.BufferedImage image = page.convertToImage(BufferedImage.TYPE_INT_ARGB, 72); File file = File.createTempFile(filename, ".png"); ImageIO.write(image, "png", file); @@ -248,4 +211,13 @@ } } + + /** + * {@inheritDoc} + */ + @Override + public String getReplacementThumbnail() + { + return "/.resources/media/icons/thumb-document.png"; + } } Modified: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java 2011-11-20 17:24:32 UTC (rev 3701) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/MediaWithPreviewImageTypeHandler.java 2011-11-20 17:59:29 UTC (rev 3702) @@ -20,12 +20,13 @@ package net.sourceforge.openutils.mgnlmedia.media.types.impl; import info.magnolia.cms.core.Content; + +import javax.jcr.RepositoryException; + import net.sourceforge.openutils.mgnlmedia.media.configuration.MediaConfigurationManager; import net.sourceforge.openutils.mgnlmedia.media.utils.ImageUtils; -import org.apache.commons.lang.StringUtils; - /** * Base class for medias that has a dynamic image as thumbnail * @author molaschi @@ -44,19 +45,37 @@ */ public String getThumbnailUrl(Content media) { - if (!ImageUtils.checkOrCreateResolution(media, "thumbnail", PREVIEW_NODEDATA_NAME)) + boolean hasPreview = false; + + try { - return StringUtils.EMPTY; + hasPreview = media.hasNodeData(PREVIEW_NODEDATA_NAME); } + catch (RepositoryException e) + { + // ignore + } - return MediaConfigurationManager.getInstance().getURIMappingPrefix() - + media.getHandle() - + "/resolutions/thumbnail/" - + media.getName() - + "." - + ImageUtils.getExtension(media, "thumbnail"); + if (hasPreview) + { + if (!ImageUtils.checkOrCreateResolution(media, "thumbnail", PREVIEW_NODEDATA_NAME)) + { + return ""; + } + return MediaConfigurationManager.getInstance().getURIMappingPrefix() + + media.getHandle() + + "/resolutions/thumbnail/" + + media.getName() + + "." + + ImageUtils.getExtension(media, "thumbnail"); + } + + return getReplacementThumbnail(); + } + public abstract String getReplacementThumbnail(); + @Override public String getPreviewImageNodeDataName() { Modified: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java 2011-11-20 17:24:32 UTC (rev 3701) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java 2011-11-20 17:59:29 UTC (rev 3702) @@ -19,11 +19,67 @@ package net.sourceforge.openutils.mgnlmedia.media.types.impl; +import info.magnolia.cms.core.Content; +import info.magnolia.cms.util.NodeDataUtil; + +import java.io.InputStream; + +import org.apache.commons.io.IOUtils; +import org.devlib.schmidt.imageinfo.ImageInfo; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + + /** + * Type handler for Flash SWF files. * @author fgiust * @version $Id$ */ -public class SwfTypeHandler extends ImageTypeHandler +public class SwfTypeHandler extends MediaWithPreviewImageTypeHandler { + /** + * Logger. + */ + private Logger log = LoggerFactory.getLogger(SwfTypeHandler.class); + + @Override + public boolean onPostSave(Content media) + { + InputStream stream = null; + try + { + stream = getOriginalFileNodeData(media).getStream(); + ImageInfo ii = new ImageInfo(); + ii.setInput(stream); + if (ii.check()) + { + NodeDataUtil.getOrCreateAndSet(media, METADATA_WIDTH, ii.getWidth()); + NodeDataUtil.getOrCreateAndSet(media, METADATA_HEIGHT, ii.getHeight()); + media.save(); + } + + } + catch (Throwable e) + { + log.warn("Error extracting metadata " + + getOriginalFileNodeData(media).getHandle() + + " " + + e.getClass().getName() + + " " + + e.getMessage(), e); + } + finally + { + IOUtils.closeQuietly(stream); + } + + return super.onPostSave(media); + } + + @Override + public String getReplacementThumbnail() + { + return "/.resources/media/icons/thumb-swf.png"; + } } Added: trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/thumb-swf.png =================================================================== (Binary files differ) Property changes on: trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/thumb-swf.png ___________________________________________________________________ Added: svn:mime-type + image/png Added: trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/thumb-video.png =================================================================== (Binary files differ) Property changes on: trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/thumb-video.png ___________________________________________________________________ Added: svn:mime-type + image/png This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2011-11-20 17:24:39
|
Revision: 3701 http://openutils.svn.sourceforge.net/openutils/?rev=3701&view=rev Author: fgiust Date: 2011-11-20 17:24:32 +0000 (Sun, 20 Nov 2011) Log Message: ----------- MEDIA-274 New mediatype for SWF files - wip Modified Paths: -------------- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/MediaModuleVersionHandler.java trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties Added Paths: ----------- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/AddExtensionToType.java trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/RemoveExtensionFromType.java trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.dialogs.mediaSwfDlg.xml trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.mediatypes.swf.xml trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/type-swf.png Added: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/AddExtensionToType.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/AddExtensionToType.java (rev 0) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/AddExtensionToType.java 2011-11-20 17:24:32 UTC (rev 3701) @@ -0,0 +1,102 @@ +/** + * + * SimpleMedia Module for Magnolia CMS (http://www.openmindlab.com/lab/products/media.html) + * Copyright(C) 2008-2011, Openmind S.r.l. http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ + +package net.sourceforge.openutils.mgnlmedia.media.setup; + +import info.magnolia.cms.beans.config.ContentRepository; +import info.magnolia.cms.core.Content; +import info.magnolia.cms.core.HierarchyManager; +import info.magnolia.module.InstallContext; +import info.magnolia.module.delta.AbstractRepositoryTask; +import info.magnolia.module.delta.TaskExecutionException; + +import javax.jcr.RepositoryException; + +import org.apache.commons.lang.StringUtils; + + +/** + * @author fgiust + * @version $Id$ + */ +public class AddExtensionToType extends AbstractRepositoryTask +{ + + private final String extension; + + private final String mediatype; + + private final String control; + + /** + * @param name + * @param description + */ + public AddExtensionToType(String extension, String mediatype, String control) + { + super("Adding " + extension + " extension to mediatype " + mediatype, "Adding " + + extension + + " extension to mediatype " + + mediatype); + this.extension = extension; + this.mediatype = mediatype; + this.control = control; + } + + /** + * {@inheritDoc} + */ + @Override + protected void doExecute(InstallContext ctx) throws RepositoryException, TaskExecutionException + { + + final HierarchyManager hm = ctx.getHierarchyManager(ContentRepository.CONFIG); + String nodePath = "/modules/media/mediatypes/" + this.mediatype; + + try + { + final Content mediatypenode = hm.getContent(nodePath); + String extensions = mediatypenode.getNodeData("extensions").getString(); + if (!StringUtils.contains(extensions, this.extension)) + { + mediatypenode.setNodeData("extensions", extensions + "," + this.extension); + } + } + catch (RepositoryException e) + { + // ignore and skip + } + + try + { + final Content mediatypenode = hm.getContent(control); + String extensions = mediatypenode.getNodeData("extensions").getString(); + if (!StringUtils.contains(extensions, this.extension)) + { + mediatypenode.setNodeData("extensions", extensions + "," + this.extension); + } + } + catch (RepositoryException e) + { + // ignore and skip + } + + } + +} Property changes on: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/AddExtensionToType.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Modified: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/MediaModuleVersionHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/MediaModuleVersionHandler.java 2011-11-20 16:46:36 UTC (rev 3700) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/MediaModuleVersionHandler.java 2011-11-20 17:24:32 UTC (rev 3701) @@ -179,49 +179,16 @@ "parseremotefiles", Boolean.TRUE)); - // add "jpeg" - tasks.add(new ChangeExistingPropertyTask( - ContentRepository.CONFIG, - "/modules/media/dialogs/mediaImageDlg/tabImage/original", - "extensions", - "jpg,gif,png", - "jpg,jpeg,gif,png")); - tasks.add(new ChangeExistingPropertyTask( - ContentRepository.CONFIG, - "/modules/media/mediatypes/image", - "extensions", - "jpg,gif,png", - "jpg,jpeg,gif,png")); + tasks.add(new AddExtensionToType("jpeg", "image", "/modules/media/dialogs/mediaImageDlg/tabImage/original")); + tasks.add(new AddExtensionToType("ico", "image", "/modules/media/dialogs/mediaImageDlg/tabImage/original")); - // add "ico" - tasks.add(new ChangeExistingPropertyTask( - ContentRepository.CONFIG, - "/modules/media/dialogs/mediaImageDlg/tabImage/original", - "extensions", - "jpg,jpeg,gif,png", - "jpg,jpeg,gif,png,ico")); + tasks.add(new AddExtensionToType("mp4", "video", "/modules/media/dialogs/mediaVideoDlg/tabVideo/original")); + tasks.add(new AddExtensionToType("mpv", "video", "/modules/media/dialogs/mediaVideoDlg/tabVideo/original")); + tasks.add(new AddExtensionToType("ogv", "video", "/modules/media/dialogs/mediaVideoDlg/tabVideo/original")); - tasks.add(new ChangeExistingPropertyTask( - ContentRepository.CONFIG, - "/modules/media/mediatypes/image", - "extensions", - "jpg,jpeg,gif,png", - "jpg,jpeg,gif,png,ico")); + tasks + .add(new RemoveExtensionFromType("swf", "video", "/modules/media/dialogs/mediaVideoDlg/tabVideo/original")); - // add mp4 - tasks.add(new ChangeExistingPropertyTask( - ContentRepository.CONFIG, - "/modules/media/mediatypes/video", - "extensions", - "flv,swf", - "flv,swf,mp4,m4v")); - tasks.add(new ChangeExistingPropertyTask( - ContentRepository.CONFIG, - "/modules/media/dialogs/mediaVideoDlg/tabVideo/original", - "extensions", - "flv,swf", - "flv,swf,mp4,m4v")); - // REVERT old stk support for magnolia < 4.3 if (isModuleInstalled("standard-templating-kit")) { Added: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/RemoveExtensionFromType.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/RemoveExtensionFromType.java (rev 0) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/RemoveExtensionFromType.java 2011-11-20 17:24:32 UTC (rev 3701) @@ -0,0 +1,110 @@ +/** + * + * SimpleMedia Module for Magnolia CMS (http://www.openmindlab.com/lab/products/media.html) + * Copyright(C) 2008-2011, Openmind S.r.l. http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ + +package net.sourceforge.openutils.mgnlmedia.media.setup; + +import info.magnolia.cms.beans.config.ContentRepository; +import info.magnolia.cms.core.Content; +import info.magnolia.cms.core.HierarchyManager; +import info.magnolia.module.InstallContext; +import info.magnolia.module.delta.AbstractRepositoryTask; +import info.magnolia.module.delta.TaskExecutionException; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import javax.jcr.RepositoryException; + +import org.apache.commons.lang.StringUtils; + + +/** + * @author fgiust + * @version $Id$ + */ +public class RemoveExtensionFromType extends AbstractRepositoryTask +{ + + private final String extension; + + private final String mediatype; + + private final String control; + + /** + * @param name + * @param description + */ + public RemoveExtensionFromType(String extension, String mediatype, String control) + { + super("Adding " + extension + " extension to mediatype " + mediatype, "Adding " + + extension + + " extension to mediatype " + + mediatype); + this.extension = extension; + this.mediatype = mediatype; + this.control = control; + } + + /** + * {@inheritDoc} + */ + @Override + protected void doExecute(InstallContext ctx) throws RepositoryException, TaskExecutionException + { + + final HierarchyManager hm = ctx.getHierarchyManager(ContentRepository.CONFIG); + String nodePath = "/modules/media/mediatypes/" + this.mediatype; + + try + { + final Content mediatypenode = hm.getContent(nodePath); + String extensions = mediatypenode.getNodeData("extensions").getString(); + if (StringUtils.contains(extensions, this.extension)) + { + List<String> exts = new ArrayList<String>(Arrays.asList(StringUtils.split(extensions, ","))); + exts.remove(this.extension); + mediatypenode.setNodeData("extensions", StringUtils.join(exts, ",")); + } + } + catch (RepositoryException e) + { + // ignore and skip + } + + try + { + final Content mediatypenode = hm.getContent(control); + String extensions = mediatypenode.getNodeData("extensions").getString(); + if (StringUtils.contains(extensions, this.extension)) + { + List<String> exts = new ArrayList<String>(Arrays.asList(StringUtils.split(extensions, ","))); + exts.remove(this.extension); + mediatypenode.setNodeData("extensions", StringUtils.join(exts, ",")); + } + } + catch (RepositoryException e) + { + // ignore and skip + } + + } + +} Property changes on: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/setup/RemoveExtensionFromType.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java =================================================================== --- trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java (rev 0) +++ trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java 2011-11-20 17:24:32 UTC (rev 3701) @@ -0,0 +1,29 @@ +/** + * + * SimpleMedia Module for Magnolia CMS (http://www.openmindlab.com/lab/products/media.html) + * Copyright(C) 2008-2011, Openmind S.r.l. http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ + +package net.sourceforge.openutils.mgnlmedia.media.types.impl; + +/** + * @author fgiust + * @version $Id$ + */ +public class SwfTypeHandler extends ImageTypeHandler +{ + +} Property changes on: trunk/openutils-mgnlmedia/src/main/java/net/sourceforge/openutils/mgnlmedia/media/types/impl/SwfTypeHandler.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.dialogs.mediaSwfDlg.xml =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.dialogs.mediaSwfDlg.xml (rev 0) +++ trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.dialogs.mediaSwfDlg.xml 2011-11-20 17:24:32 UTC (rev 3701) @@ -0,0 +1,304 @@ +<?xml version="1.0" encoding="UTF-8"?> +<sv:node sv:name="mediaSwfDlg" xmlns:sv="http://www.jcp.org/jcr/sv/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>2402c2ee-3e93-4648-afc4-aa0cb9d46fc7</sv:value> + </sv:property> + <sv:property sv:name="class" sv:type="String"> + <sv:value>net.sourceforge.openutils.mgnlmedia.media.dialog.LayerDialogMVC</sv:value> + </sv:property> + <sv:property sv:name="height" sv:type="String"> + <sv:value>500</sv:value> + </sv:property> + <sv:property sv:name="i18nBasename" sv:type="String"> + <sv:value>net.sourceforge.openutils.mgnlmedia.media.lang.messages</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="label" sv:type="String"> + <sv:value>media.dialogs.mediaSwfDlg.label</sv:value> + </sv:property> + <sv:property sv:name="width" sv:type="String"> + <sv:value>520</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:Data" sv:type="String"> + <sv:value>MetaData</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activatorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="String"> + <sv:value>2004-11-02T15:34:23.417+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastaction" sv:type="Date"> + <sv:value>2008-07-02T15:10:45.780Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T22:59:58.052+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:title" sv:type="String"> + <sv:value/> + </sv:property> + </sv:node> + <sv:node sv:name="tabVideo"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>a64f4eb5-a9cb-4c17-baab-7c4eb1d04c04</sv:value> + </sv:property> + <sv:property sv:name="controlType" sv:type="String"> + <sv:value>tab</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="label" sv:type="String"> + <sv:value>media.dialogs.tabSwf.label</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:Data" sv:type="String"> + <sv:value>MetaData</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activatorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="String"> + <sv:value>2004-11-02T15:34:29.217+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastaction" sv:type="Date"> + <sv:value>2008-07-02T15:10:54.979Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T23:00:08.911+01:00</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="original"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>f6b39267-7267-450e-aa59-c6ae3e3895ed</sv:value> + </sv:property> + <sv:property sv:name="controlType" sv:type="String"> + <sv:value>mediaFile</sv:value> + </sv:property> + <sv:property sv:name="extensions" sv:type="String"> + <sv:value>swf</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="label" sv:type="String"> + <sv:value>media.dialogs.tabSwf.video.label</sv:value> + </sv:property> + <sv:property sv:name="required" sv:type="String"> + <sv:value>true</sv:value> + </sv:property> + <sv:property sv:name="type" sv:type="String"> + <sv:value>Binary</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:Data" sv:type="String"> + <sv:value>MetaData</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activatorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="String"> + <sv:value>2004-11-02T15:34:29.357+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastaction" sv:type="Date"> + <sv:value>2008-07-02T15:15:57.112Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T23:00:28.248+01:00</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="image"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>a243137a-3013-4267-b8e3-097a066e004e</sv:value> + </sv:property> + <sv:property sv:name="controlType" sv:type="String"> + <sv:value>mediaFile</sv:value> + </sv:property> + <sv:property sv:name="description" sv:type="String"> + <sv:value>media.dialogs.mediaSwfDlg.tabSwf.image.description</sv:value> + </sv:property> + <sv:property sv:name="extensions" sv:type="String"> + <sv:value>jpg,gif,png</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="label" sv:type="String"> + <sv:value>media.dialogs.tabSwf.image.label</sv:value> + </sv:property> + <sv:property sv:name="type" sv:type="String"> + <sv:value>Binary</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:Data" sv:type="String"> + <sv:value>MetaData</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activatorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="String"> + <sv:value>2004-11-02T15:34:29.357+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastaction" sv:type="Date"> + <sv:value>2008-07-02T15:14:49.217Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T23:00:51.872+01:00</sv:value> + </sv:property> + </sv:node> + </sv:node> + </sv:node> + <sv:node sv:name="tabAttributes"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>f0dbd995-a36e-4560-b204-868c67acedbd</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="reference" sv:type="String"> + <sv:value>/modules/media/dialogs/common/tabAttributes</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:Data" sv:type="String"> + <sv:value>MetaData</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activatorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="String"> + <sv:value>2004-11-02T15:34:29.217+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastaction" sv:type="Date"> + <sv:value>2008-07-02T16:35:26.540Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T22:59:37.920+01:00</sv:value> + </sv:property> + </sv:node> + </sv:node> + <sv:node sv:name="type"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>d93c93c6-22ec-4ad4-94c8-1aa6fe131521</sv:value> + </sv:property> + <sv:property sv:name="controlType" sv:type="String"> + <sv:value>hidden</sv:value> + </sv:property> + <sv:property sv:name="defaultValue" sv:type="String"> + <sv:value>swf</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activatorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2008-06-21T10:51:52.322Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastaction" sv:type="Date"> + <sv:value>2008-07-02T15:10:45.802Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T22:59:37.921+01:00</sv:value> + </sv:property> + </sv:node> + </sv:node> +</sv:node> Property changes on: trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.dialogs.mediaSwfDlg.xml ___________________________________________________________________ Added: svn:mime-type + text/xml Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.mediatypes.swf.xml =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.mediatypes.swf.xml (rev 0) +++ trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.mediatypes.swf.xml 2011-11-20 17:24:32 UTC (rev 3701) @@ -0,0 +1,99 @@ +<?xml version="1.0" encoding="UTF-8"?> +<sv:node sv:name="swf" xmlns:sv="http://www.jcp.org/jcr/sv/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>b84c36d1-01ee-4f75-84a3-269da3b29798</sv:value> + </sv:property> + <sv:property sv:name="dialog" sv:type="String"> + <sv:value>mediaSwfDlg</sv:value> + </sv:property> + <sv:property sv:name="enabled" sv:type="Boolean"> + <sv:value>true</sv:value> + </sv:property> + <sv:property sv:name="extensions" sv:type="String"> + <sv:value>swf</sv:value> + </sv:property> + <sv:property sv:name="i18nBasename" sv:type="String"> + <sv:value>net.sourceforge.openutils.mgnlmedia.media.lang.messages</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="label" sv:type="String"> + <sv:value>media.types.swf</sv:value> + </sv:property> + <sv:property sv:name="menuIcon" sv:type="String"> + <sv:value>/.resources/media/icons/type-swf.png</sv:value> + </sv:property> + <sv:property sv:name="order" sv:type="Long"> + <sv:value>15</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activatorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2008-06-17T16:49:16.314Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastaction" sv:type="Date"> + <sv:value>2008-06-17T16:51:17.750Z</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T22:59:05.138+01:00</sv:value> + </sv:property> + </sv:node> + <sv:node sv:name="handler"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:contentNode</sv:value> + </sv:property> + <sv:property sv:name="jcr:mixinTypes" sv:type="Name" sv:multiple="true"> + <sv:value>mix:lockable</sv:value> + </sv:property> + <sv:property sv:name="jcr:uuid" sv:type="String"> + <sv:value>7f9e15ed-1f85-4df8-bb63-0cd42c8f4902</sv:value> + </sv:property> + <sv:property sv:name="class" sv:type="String"> + <sv:value>net.sourceforge.openutils.mgnlmedia.media.types.impl.SwfTypeHandler</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:node sv:name="MetaData"> + <sv:property sv:name="jcr:primaryType" sv:type="Name"> + <sv:value>mgnl:metaData</sv:value> + </sv:property> + <sv:property sv:name="jcr:createdBy" sv:type="String"> + <sv:value>admin</sv:value> + </sv:property> + <sv:property sv:name="mgnl:activated" sv:type="Boolean"> + <sv:value>false</sv:value> + </sv:property> + <sv:property sv:name="mgnl:authorid" sv:type="String"> + <sv:value>superuser</sv:value> + </sv:property> + <sv:property sv:name="mgnl:creationdate" sv:type="Date"> + <sv:value>2010-02-14T21:24:17.243+01:00</sv:value> + </sv:property> + <sv:property sv:name="mgnl:lastmodified" sv:type="Date"> + <sv:value>2011-11-19T22:59:15.837+01:00</sv:value> + </sv:property> + </sv:node> + </sv:node> +</sv:node> Property changes on: trunk/openutils-mgnlmedia/src/main/resources/mgnl-bootstrap/media-nooverwrite/config.modules.media.mediatypes.swf.xml ___________________________________________________________________ Added: svn:mime-type + text/xml Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/type-swf.png =================================================================== (Binary files differ) Property changes on: trunk/openutils-mgnlmedia/src/main/resources/mgnl-resources/media/icons/type-swf.png ___________________________________________________________________ Added: svn:mime-type + image/png Modified: trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties 2011-11-20 16:46:36 UTC (rev 3700) +++ trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages.properties 2011-11-20 17:24:32 UTC (rev 3701) @@ -55,13 +55,15 @@ media.types.youtube=External videos media.types.video=Videos media.types.document=Documents +media.types.swf=SWF -media.types.image.load=Upload new image -media.types.audio.load=Upload new mp3 -media.types.youtube.load=Link external video -media.types.video.load=Upload flv/mp4 video -media.types.document.load=Upload new document +media.types.image.load=Upload a new image +media.types.audio.load=Upload a new mp3 +media.types.youtube.load=Link an external video +media.types.video.load=Upload a flv/mp4 video +media.types.document.load=Upload a new document +media.types.swf.load=Upload a new SWF media.download=Download media.edit=Edit @@ -165,3 +167,11 @@ config.search.filters.sorting=Sorting media.info.media_originalpath=Original path: {0} + +media.dialogs.mediaSwfDialog.label=SWF +media.dialogs.tabSwf.label=SWF +media.dialogs.tabSwf.video.label=SWF file +media.dialogs.tabSwf.image.label=Alternative image +media.dialogs.mediaSwfDlg.tabSwf.image.description=The image will be shown if the browser doesn''t support flash + +media.types.all=All Modified: trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties =================================================================== --- trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties 2011-11-20 16:46:36 UTC (rev 3700) +++ trunk/openutils-mgnlmedia/src/main/resources/net/sourceforge/openutils/mgnlmedia/media/lang/messages_it.properties 2011-11-20 17:24:32 UTC (rev 3701) @@ -56,6 +56,7 @@ media.types.youtube=Video esterni media.types.video=Video media.types.document=Documenti +media.types.swf=SWF media.types.image.load=Carica immagine @@ -63,6 +64,7 @@ media.types.youtube.load=Collega video esterno media.types.video.load=Carica video flv/mp4 media.types.document.load=Carica documento +media.types.swf.load=Carica SWF media.download=Scarica media.edit=Modifica @@ -168,3 +170,13 @@ config.search.filters.sorting=Ordinamento media.info.media_originalpath=Posizione originale: {0} + +media.dialogs.mediaSwfDialog.label=SWF +media.dialogs.tabSwf.label=SWF +media.dialogs.tabSwf.video.label=File SWF +media.dialogs.tabSwf.image.label=Immagine alternativa +media.dialogs.mediaSwfDlg.tabSwf.image.description=L''immagine sar\xE0 visualizzata se il browser non supporta flash + +media.types.all=Tutti + + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |