Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Template engine can't see my pagesAfterTemplateSelectionProvide class

Great! That works; my class is now getting called.  will have to actually
put in a page there now. :)
I do notice that  getCreatedPages is called, but not createAdditionalPages
which the comments imply would get called first to construct them.
I can handle it either way.
Is that right?


...Beth

Beth Tibbitts  (859) 243-4981  (TL 545-4981)
High Productivity Tools / Parallel Tools  http://eclipse.org/ptp
IBM T.J.Watson Research Center
Mailing Address:  IBM Corp., 455 Park Place, Lexington, KY 40511


                                                                           
             bala.torati@symbi                                             
             an.com                                                        
             Sent by:                                                   To 
             cdt-dev-bounces@e         "CDT General developers list."      
             clipse.org                <cdt-dev@xxxxxxxxxxx>               
                                                                        cc 
                                                                           
             09/28/2007 12:44                                      Subject 
             PM                        Re: [cdt-dev] Template engine can't 
                                       see my                              
                                       pagesAfterTemplateSelectionProvide  
             Please respond to         class                               
               "CDT General                                                
             developers list."                                             
             <cdt-dev@eclipse.                                             
                   org>                                                    
                                                                           
                                                                           





Hi Beth,

I have attached a fix for this problem, not using the reflection API
directly. Originally it was implemented in the "Eclipse way" to create the
executable class using ExtensionRegistry, when I implemented it as a
standalone plugin. But during the integration of TE into new project model,
and the seperation of core and ui parts of the TE resulted in calling the
Reflection API directly. I fixed this problem now with the following patch.
Did you open a defect for this issue? If not, please ask a committer to
apply this patch, if you found it's ok.



Regards,
-Bala


                                                                           
 Beth Tibbitts                                                             
 <tibbitts@xxxxxxxxxx>                                                     
 Sent by:                                                               To 
 cdt-dev-bounces@xxxxxxxxxxx          cdt-dev@xxxxxxxxxxx                  
                                                                        cc 
                                                                           
 28/09/2007 12:30                                                  Subject 
                                      [cdt-dev] Template engine can't see  
                                      my                                   
      Please respond to               pagesAfterTemplateSelectionProvide   
   "CDT General developers            class                                
            list."                                                         
    <cdt-dev@xxxxxxxxxxx>                                                  
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           






I'm getting a ClassNotFoundException when the template engine tries to load
my  pagesAfterTemplateSelectionProvider class.
The class is indeed there.

java.lang.ClassNotFoundException:
org.eclipse.ptp.pldt.wizards.wizardPages.MPIPageProvider
     ....
     at org.eclipse.cdt.ui.templateengine.Template.getExtraCreatedPages(
Template.java:147)

<template
           filterPattern=" "
           id="org.eclipse.ptp.pldt.projects.MPIhelloWorldCProject"
           location="templates/MPIhelloWorldCproject/template.xml"
           pagesAfterTemplateSelectionProvider=
"org.eclipse.ptp.pldt.wizards.wizardPages.MPIPageProvider"
           projectType=."org.eclipse.cdt.build.core.buildArtefactType.exe"
>
     </template>

in Template.java it's using Class.forName instead of the eclipse class
loader

//e.g.
pagesProvider="org.eclipse.ptp.pldt.wizards.wizardPages.MPIPageProvider";
Class clazz = Class.forName(pagesProvider);
instead of something like.

ExtensionRegistry.createExecutableExtension()




Have you been able to get this to work using a class in another project
from template engine, as the pagesAfterTemplateSelectionProvider class?

Are these changes what you were talking about that will be coming in 4.0.2?



...Beth

Beth Tibbitts  (859) 243-4981  (TL 545-4981)
High Productivity Tools / Parallel Tools  http://eclipse.org/ptp
IBM T.J.Watson Research Center
Mailing Address:  IBM Corp., 455 Park Place, Lexington, KY 40511

_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-dev



Taking our world with us...
Make sure you visit the Symbian Smartphone Show, 16-17 October 2007, Excel,
London
smartphoneshow.com


**********************************************************************
Symbian Software Ltd is a company registered in England and Wales with
registered number 4190020 and registered office at 2-6 Boundary Row,
Southwark, London, SE1 8HP, UK. This message is intended only for use by
the named addressee and may contain privileged and/or confidential
information. If you are not the named addressee you should not disseminate,
copy or take any action in reliance on it. If you have received this
message in error please notify postmaster@xxxxxxxxxxx and delete the
message and any attachments accompanying it immediately. Neither Symbian
nor any of its Affiliates accepts liability for any corruption,
interception, amendment, tampering or viruses occurring to this message in
transit or for any message sent by its employees which is not in compliance
with Symbian corporate policy.
**********************************************************************(See
attached file: fix_template_extrapages.txt.zip)
_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-dev


Attachment: fix_template_extrapages.txt.zip
Description: Zip archive


Back to the top