JpaInspector cannot override inspectProperty()
I want to use JpaInspector
class that is written for Metawidget. However when I insert this class into my Java project in Netbeans 6.8, It gives an error for inspectProperty()
method of JpaInspector
class, "method does not override or implement a method from supertype". Does it mean that parent c开发者_如何转开发lass of JpaInspector
, that is BaseObjectInspector
, does not have such a method? Or what should I do to use JpaInspector
in my project?
Update
Ok, I import the package "org.metawidget.inspector.jpa.JpaInspector"; however, although some fields of my entity class are set as nullable = false, the stars are not seen. Why is it?
Gulcan,
I'm confused: are you inserting the source code for JpaInspector into your project? I'm unclear why you would want to do that. You can add JpaInspector to Metawidget by using metawidget.xml and CompositeInspector. For example:
<inspector>
<compositeInspector>
<inspectors>
<array>
<metawidgetAnnotationInspector />
<jpaInspector />
</array>
</inspectors>
Or you can add it programmatically. In neither case do you need the JpaInspector source code.
Regards,
Richard.
精彩评论