can you help with the compiling error in Chap06 code? It is like the code constructor is not compatible with declaration in Track.java
Usertypes
In chap06
ant codegen ant prepare are OK.
ant schema resulted in
/examples/ch10/src/com/oreilly/hh/CreateTest.java:73: cannot find symbol [javac] symbol : constructor Track(java.lang.String,java.lang.String,java.sql.Time,java.util.HashSet<com.oreilly.hh.data.Artist>,java.util.Date,com.oreilly.hh.StereoVolume,com.oreilly.hh.SourceMedia,java.util.HashSet<java.lang.String>) [javac] location: class com.oreilly.hh.data.Track [javac] track = new Track("Video Killed the Radio Star",
The signature of constructor in Track.java generated from Track.hbm.xml is public Track(String title, String filePath, Date playTime, Set<Artist> artists, Date added, StereoVolumeType volume, SourceMediaType sourceMedia, Set<String> comments) {^M
The constructor in Track.java is like this
Track track = new Track(title, file, length, new HashSet<Artist>(), new Date(), new StereoVolume(), SourceMedia.CD, new HashSet<String>());
the type of new StereoVolume(), SourceMedia.CD are incompatible...
this should be OK since ant usertypes work but it did not.
any help please. thanks!
Report this post
|