No source code is available for type com.google.gwt.visualization.client.visualizations.PieChart

1 resposta
B

Pessoal,

Estou com uma aplicação que utiliza GWT, mais especificamente a API de Visualization do GWT: gwt-visualization-1.0.2.jar

Ao utilizar o componente PieChart e testar a aplicação, os seguintes erro de compilação aparecem:

11:32:13.078 [ERROR] [view] Line 35: No source code is available for type com.google.gwt.visualization.client.visualizations.PieChart; did you forget to inherit a required module?
11:32:13.093 [ERROR] [view] Line 57: No source code is available for type com.google.gwt.visualization.client.AbstractDataTable; did you forget to inherit a required module?
11:32:13.093 [ERROR] [view] Line 58: No source code is available for type com.google.gwt.visualization.client.DataTable; did you forget to inherit a required module?
11:32:13.109 [ERROR] [view] Line 59: No source code is available for type com.google.gwt.visualization.client.AbstractDataTable.ColumnType; did you forget to inherit a required module?

Sendo assim, adicionei os módulos no meu view.gwt.xml, na esperança de resolver os erros:

... ...

E o seguinte erro ocorreu:

Loading modules

view

Loading inherited module com.google.gwt.visualization.client.visualizations.PieChart

[ERROR] Unable to find com/google/gwt/visualization/client/visualizations/PieChart.gwt.xml on your classpath; could be a typo, or maybe you forgot to include a classpath entry for source?

[ERROR] Line 12: Unexpected exception while processing element inherits

com.google.gwt.core.ext.UnableToCompleteException: (see previous log entries)

at com.google.gwt.dev.cfg.ModuleDefLoader.nestedLoad(ModuleDefLoader.java:239)

at com.google.gwt.dev.cfg.ModuleDefSchema$BodySchema.__inherits_begin(ModuleDefSchema.java:354)

at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at com.google.gwt.dev.util.xml.HandlerMethod.invokeBegin(HandlerMethod.java:223)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.startElement(ReflectiveParser.java:270)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:533)

at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:220)

at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.emptyElement(XMLDTDValidator.java:819)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:872)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1693)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)

at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1242)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.parse(ReflectiveParser.java:327)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.access$100(ReflectiveParser.java:48)

at com.google.gwt.dev.util.xml.ReflectiveParser.parse(ReflectiveParser.java:398)

at com.google.gwt.dev.cfg.ModuleDefLoader.nestedLoad(ModuleDefLoader.java:257)

at com.google.gwt.dev.cfg.ModuleDefLoader$1.load(ModuleDefLoader.java:169)

at com.google.gwt.dev.cfg.ModuleDefLoader.doLoadModule(ModuleDefLoader.java:283)

at com.google.gwt.dev.cfg.ModuleDefLoader.loadFromClassPath(ModuleDefLoader.java:141)

at com.google.gwt.dev.DevModeBase.loadModule(DevModeBase.java:867)

at com.google.gwt.dev.DevMode.loadModule(DevMode.java:425)

at com.google.gwt.dev.DevMode.doSlowStartup(DevMode.java:340)

at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:953)

at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:690)

at com.google.gwt.dev.DevMode.main(DevMode.java:251)

[ERROR] Failure while parsing XML

com.google.gwt.core.ext.UnableToCompleteException: (see previous log entries)

at com.google.gwt.dev.util.xml.DefaultSchema.onHandlerException(DefaultSchema.java:56)

at com.google.gwt.dev.util.xml.Schema.onHandlerException(Schema.java:66)

at com.google.gwt.dev.util.xml.Schema.onHandlerException(Schema.java:66)

at com.google.gwt.dev.util.xml.HandlerMethod.invokeBegin(HandlerMethod.java:233)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.startElement(ReflectiveParser.java:270)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:533)

at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:220)

at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.emptyElement(XMLDTDValidator.java:819)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:872)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1693)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)

at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1242)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.parse(ReflectiveParser.java:327)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.access$100(ReflectiveParser.java:48)

at com.google.gwt.dev.util.xml.ReflectiveParser.parse(ReflectiveParser.java:398)

at com.google.gwt.dev.cfg.ModuleDefLoader.nestedLoad(ModuleDefLoader.java:257)

at com.google.gwt.dev.cfg.ModuleDefLoader$1.load(ModuleDefLoader.java:169)

at com.google.gwt.dev.cfg.ModuleDefLoader.doLoadModule(ModuleDefLoader.java:283)

at com.google.gwt.dev.cfg.ModuleDefLoader.loadFromClassPath(ModuleDefLoader.java:141)

at com.google.gwt.dev.DevModeBase.loadModule(DevModeBase.java:867)

at com.google.gwt.dev.DevMode.loadModule(DevMode.java:425)

at com.google.gwt.dev.DevMode.doSlowStartup(DevMode.java:340)

at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:953)

at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:690)

at com.google.gwt.dev.DevMode.main(DevMode.java:251)

[ERROR] Unexpected error while processing XML

com.google.gwt.core.ext.UnableToCompleteException: (see previous log entries)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.parse(ReflectiveParser.java:351)

at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.access$100(ReflectiveParser.java:48)

at com.google.gwt.dev.util.xml.ReflectiveParser.parse(ReflectiveParser.java:398)

at com.google.gwt.dev.cfg.ModuleDefLoader.nestedLoad(ModuleDefLoader.java:257)

at com.google.gwt.dev.cfg.ModuleDefLoader$1.load(ModuleDefLoader.java:169)

at com.google.gwt.dev.cfg.ModuleDefLoader.doLoadModule(ModuleDefLoader.java:283)

at com.google.gwt.dev.cfg.ModuleDefLoader.loadFromClassPath(ModuleDefLoader.java:141)

at com.google.gwt.dev.DevModeBase.loadModule(DevModeBase.java:867)

at com.google.gwt.dev.DevMode.loadModule(DevMode.java:425)

at com.google.gwt.dev.DevMode.doSlowStartup(DevMode.java:340)

at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:953)

at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:690)

at com.google.gwt.dev.DevMode.main(DevMode.java:251)

Alguém já teve algum problema parecido e conseguiu resolver?

Abraços

1 Resposta

A

o caminho que tu especificou está realmente certo? ele está apontando para esse erro aqui:

[ERROR] Unable to find ‘com/google/gwt/visualization/client/visualizations/PieChart.gwt.xml’ on your classpath; could be a typo, or maybe you forgot to include a classpath entry for source?

[ERROR] Line 12: Unexpected exception while processing element ‘inherits’

seu problema será resolvido se você confirmar o caminho do xml que ele ta precisando para carregar as outras coisas (o com/google/gwt/visualization/client/visualizations/PieChart.gwt.xml)

Criado 17 de janeiro de 2010
Ultima resposta 18 de jan. de 2010
Respostas 1
Participantes 2