Widgetset Compilation of Self-made component library

Hi,

I developed a couple of GWT composite components and their analogue server-side vaadin components arranging them in a Vaadin application. I tested them inside this application and they worked correctly both from client and server side.

With that made, I created a Java class library with those client and server components (including java sources of course) in order to create a component library to be used in other vaadin projects.

The point is that when creating a test vaadin application and including in the classpath the component library, the widgetset doesn’t find my components, hence not compiling them. The library purely replicates the same package structure as it was in the first vaadin application where instead of having the packages in a separate library, they were part of the project.

I don’t understand that. The library should merely include those packages in the classpath and the compiler should be able to see them.

Does anyone know a reason for that?

I attach a screenshot of the project structure, as also the contents of the module descriptor…

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit 1.7.0//EN" "http://google-web-toolkit.googlecode.com/svn/tags/1.7.0/distro-source/core/src/gwt-module.dtd">
<module>
      
    <inherits name="com.vaadin.terminal.gwt.DefaultWidgetSet" />
    <stylesheet src="anchuraPaneles.css"/>

    
</module>

As said, the library when run as a standalone vaadin application (replicating the package structure inside the default package of a vaadin application) runs and compiles fine. When packaging in a library and including that library in a standalone vaadin project, the widgetset compilation will fail in finding the paintables.

Any help is greatly appreciated.

Thanks in advance.

Carlos Conti.

13302.png

You need to define your library as an Vaadin addon package by adding some properties to the META-INF/MANIFEST.MF. In your case you will need to include the Vaadin-Widgetsets attribute.

Take a look at
https://vaadin.com/directory/help/creating-vaadin-add-ons
for some instructions and the actual specification can be found at
http://dev.vaadin.com/wiki/VaadinAddon
.

Cool thanks for telling!
This one would have been difficult to catch, sine the most difficult part was done. Was only this configuration issue…

Thanks it works now.

Just for my information, what I don’t understand is that the class that compiles the widgetset is “com.google.gwt.dev.Compiler”… but where is it stated that the compiler will ommit those modules depending on which settings included in the manifest file. I believe that Vaadin must do some sort of customization there, but don’t know how or where…

Carlos.