How to add a facet to an existed project in my plug-in?

In my plug-in on Workshop, I want to add a facet to a project dynamicly, and I try two ways, but it does't work:
1: use method "installProjectFacet"
facetedProject.installProjectFacet(fv,fv.createActionConfig(Action.Type.INSTALL,project.getName()), monitor);
The exception is :
org.eclipse.core.runtime.CoreException: Class com.bea.wlw.xmlbeans.feature.XMLBeansBuilderFeatureConfiguration$Factory is not an instance of org.eclipse.wst.common.project.facet.core.IActionConfigFactory.
at org.eclipse.wst.common.project.facet.core.internal.ProjectFacetVersion.createActionConfig(ProjectFacetVersion.java:141)
at ilog.integration.bea.workshop.AddXMLBeanFacet.execute(AddXMLBeanFacet.java:171)
2: use method setFixedProjectFacets
final Set <ProjectFacet> sourceFixed=facetedProject.getFixedProjectFacets();
                         Set <ProjectFacet> updatedFixed=new HashSet<ProjectFacet>();
                         Iterator it=sourceFixed.iterator();
                         while(it.hasNext()){
                              updatedFixed.add((ProjectFacet)it.next());
                         updatedFixed.add(f);
                         final Set <ProjectFacet> destFixed=updatedFixed;
                         facetedProject.setFixedProjectFacets(destFixed);
after executed, there is no changes.
Can you give me some advice?

After I add "org.eclipse.wst.common.project.facet.core" to my plug-in dependencies, the above exception does't appeared, the installProjectFacet can be executed without exception.
But when I release the plug-in and setup on workshop, there was a new exception when executed, I meets a new problem:
Root exception:
java.lang.NoClassDefFoundError: org/eclipse/wst/common/project/facet/core/IProjectFacet
at ilog.integration.bea.workshop.ui.shared.utils.AbstractArtifactsGenerator.importSchemas(AbstractArtifactsGenerator.java:138)
at ilog.integration.bea.workshop.ui.ws.WSArtifactsGenerator.createTypeMembers(WSArtifactsGenerator.java:93)
at ilog.integration.bea.workshop.ui.ws.pages.NewDecisionServiceWizardPage.createTypeMembers(NewDecisionServiceWizardPage.java:49)
at ilog.integration.bea.workshop.ui.shared.pages.NewTypeWizardPage.createType(NewTypeWizardPage.java:1844)
at ilog.integration.bea.workshop.ui.shared.wizards.DecisionServiceCreationWizard.finishPage(DecisionServiceCreationWizard.java:71)
at org.eclipse.jdt.internal.ui.wizards.NewElementWizard$2.run(NewElementWizard.java:117)
at org.eclipse.jdt.internal.core.BatchOperation.executeOperation(BatchOperation.java:39)
at org.eclipse.jdt.internal.core.JavaModelOperation.run(JavaModelOperation.java:718)
at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1721)
at org.eclipse.jdt.core.JavaCore.run(JavaCore.java:3844)
at org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter.run(WorkbenchRunnableAdapter.java:87)
at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)
Why can’t find the class IProjectFace? I haved added project facet plug-in into my plug-in dependencies, so I am confused. Does our plug-in needs other setting except eclipse plug-in's dependecies?
no pains, no gains

Similar Messages

  • Cp 8 - How to add ppt slides to an existing project with space to the left and right ?

    After much trial and error, i know exactly what I want. The priority for me is clear and unscaled captured video, and my project resolution shall be 1260x700. 
    now, i want to bring my ppt slides in and respect the aspect ratio- this means that there will be blank space to the left and right of the slides. The active area of the ppt slide should be about  700 h and 4/3 * 700 width. To avoid scaling, i would love them to be 699 x 932 and have the areas to the left and right blank. i am also willing to make my project 1260x702.
    The objective here is to avoid scaling. I have seen that things look great when scaling is avoided.

    Maybe you'll find some ideas here: Create and Use a "Knockout" Master Slide - Captivate blog

  • How to add new row and update existing rows at a time form the upload file

    hi
    How to add new row and update existing rows at a time form the upload file
    example:ztable(existing table)
    bcent                      smh            nsmh         valid date
    0001112465      7.4                       26.06.2007
    0001112466      7.5                       26.06.2007
    000111801                      7.6                       26.06.2007
    1982                      7.8                       26.06.2007
    Flat file structure
    bcent                       nsmh         valid date
    0001112465     7.8     26.06.2007  ( update into above table in nsmh)
    0001112466     7.9     26.06.2007  ( update into above table in nsmh) 
    000111801                     7.6      26.06.2007 ( update into above table in nsmh
    1985                      11              26.06.2007   new row it should insert in table
    thanks,
    Sivagopal R

    Hi,
    First upload the file into an internal table. If you are using a file that is on application server. Use open dataset and close dataset.
    Then :
    Loop at it.
    *insert or modify as per your requirement.
    Endloop.
    Regards,
    Srilatha.

  • [Ai-CS4] How to add an  art board to existing document ?

    hi all,
    can anybody suggest me how to add a new artboard to existing document? I didn't find any ArtBoard Palette in CS4. But in CS5 it is given.
    thanks,
    D.A

    The Artboard panel is new to AiCS5. In CS4, a new artboard can be added by doing either of the two:
    1. Pick the Artboard Tool and click-drag it in the canvas area of the Illustrator document.
    2. Pick the Artboard Tool, click on the 'New Artboard' button in the Control Panel. Then select the desired size from the list of Artboard Presets in the Control Panel and then click in the desired area of the canvas to add a new Artboard.
    Hope this helps.
    Neeraj

  • How to add a user to an existing group????

    Can't seem to find how to add a user to an existing group (staff). I am trying to share data (rw) between my admin account (root) and a development user. On any other UNIX system I would just add the user name in the /etc/group file & logout/login in. It don't work here!
    Suggestions??
    thanx
    mt

    OS X doesn't use /etc/groups. This file is present but does nothing AFAIK.
    Leopard uses directory services to handle groups and users.
    membership in groups with GID>500 can be handled from GUI in system preferences->accounts. other groups can be handled from terminal with dscl (directory services command line). do man dscl for details.
    to add a user to a group you'd do
    sudo dscl . append /groups/groupname GroupMembership username
    However, there should be no need to do it with "staff". every user with an account on your computer is a member of staff by default.

  • How to add a file to an existing package programmatically in Acrobat 8?

    Hello
    Is it possible to add a file to an existing package programmatically in Acrobat 8? (embed a pdf file in a pdf package programmatically); If so, how should I do it?
    Thanks in advance,

    Finally, I found out how to add a file to an existing package programmatically by using JavaScript (function: app.execMenuItem("AddFileAttachment")). Thanks for your help Ironsenth. However, I need to specify the file to attach programmatically and I can't figure out how to do it.
    Could you let me know where I can find this information (what document to read)? Is there any parameters for the 'AddFileAttachment' method?
    Thanks in advance,

  • How to import linphone library in our existing project ?

    how to import linphone library in our existing project ?

    Hi,
    This article will guide you how to deploy the external jar files to the application server.
    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/60a0f850-c451-2c10-a6a6-ddcabfa3a65b&overridelayout=true
    Add the library project to the public part of your caf project to use the jar files.
    Regards,
    Gayathri

  • How to add a new tab for the project?

    Dear All Experts,
        Could you tell me how to add a new tab for the project?
        Pls refer to the screenshot as below:
    Thanks!
    Xinling Zhang

    Hi,
        The new tab in cj20n , and the new tab can only be displayed in the highed level.Pls refer to below
        And in cj02, there is no this tab also in the wbs detailed screen,
    Thanks!
    Xinling

  • How to add a new system in existing 3 system lanscape in stms

    Hi,
    we have 3 system in our STMS i.e Dev->Qua->Prod. now we have install one more quality system for business requirement and add the same saystem in stms.
    now my query is that how we can add this new system in existing transport route so that transport request can be added automatically to import queue of both quality system once released from development system.

    Hi Nadar,
    It is possible, But not recommended. Better if you have solution like...
    DEV-->QAS1-->QAS2-->PRD
    But it is possible by using transport groups. There are lots of posts aleady regarding this.
    Basis Stms Configuration Notes
    http://sap.ittoolbox.com/groups/technical-functional/sap-basis/4-system-landscape-stms-2712918
    4-system landscape
    STMS config for dual prod (w/ auto synch)
    Thanks
    Asad

  • How to Add the Cost Element in Existing Zreport Painter

    hi friends
    i have issue with report painter
    one Cost Element is not picked in Z Report which was created in Report painter
    transaction data could be found in standard reports.
    please expain how to Add the missing Cost Element in Existing  ZReport
    Point will be awarded.
    Thanks

    Check your sets first, if the cost element is missing from there, then change the set using GS02
    Cheers
    Prakash

  • How to add create partition to an existing table?

    hi,
    please tell me how to add partition to an existing table.
    i have tried
    alter table mvr add partition sno
    but getting error : ORA-14501: object is not partitioned
    thanks.

    Just Googling for ora-14501 resulted in the following
    Adding a partition results in ORA-14501: object is not partitioned
    It is really sad you can not do this on your own, and always need someone to do this for you.
    Sybrand Bakker
    Senior Oracle DBA

  • How to add Power BI to my existing SharePoint account?

    I have my own SharePoint Online account already created and Now I want to integrate Power BI in It.
    How should I add Power BI to my existing account?
    I am using SharePoint Online.

    Are you the tenant admin?
    Thanks!
    Ed Price, Power BI & SQL Server Customer Program Manager (Blog,
    Small Basic,
    Wiki Ninjas,
    Wiki)
    Answer an interesting question?
    Create a wiki article about it!

  • How to add a new filter in existing BIWS (WEBI) for dashboard consumption

    Hello Experts, we have 7 web service query's connected to a dashboard. Basically it is one WSDL URL and 7 Get Methods...Web service queries are BIWS (via WEBI document instance). There are filters setup for each of these web service methods.
    Recently there was a request to add 2 new fields to the webi document and also the 2 fields need to be included as filters in the 7 methods. I know there is an option to edit the method, but when i edit the method, i cannot find the 2 new fields in list to set as filters.Can anybody help me understand how to add filters to an existiing web service method? I do not want to delete the method and republish the block as web service.
    Any help will be great and points rewarded.
    Thank you
    Ann

    Hi Ann,
    You can create a new WebServices or modify the document block on which the webservices is published.
    Once the block is modified you might be able to see the new objects in the filters.
    Thanks,
    Amit

  • Tabstrib - how to add a tab into a existing tabstrip ?

    Hello,
    I have add a tab into a existing tabstrip. What is step by step the procedure to do ?
    If I go on the existing tabstrip, I can't see the "create a new tab" or something likr that.
    Tks,
    R

    HI,
    Double click in the Corner area of TabStrip and enter the number TAB CONTROL in the Attributes pop up window
    Or simply drag a Push Button and place on the Tabstrip Control
    Cheerz
    Ram

  • How to add a node to already existing hierarchy in BW?

    Hi Gurus,
    Can someone please tell me step by step how to add a node to the hierarchy.
    Thank you,
    Olga

    If I need to add an element to the node, I right click on the node and is it 'insert Characteristic'?
    Sorry I must add one more thing.If it is the first time you add an element to the node then right click the folder(node).But if you already have elements in the node then right click any element and choose add element(country,material whatever).If you choose add a characteristic, then you add another type of element(e.g you have materials in the node and add some countries by choosing add a characteristic)
    When I try to add a node, it gives me a list of nodes I can choose from
    In fact when you right click a folder, there must be an option like "Create nodes".Do you right click on a folder, don't you?You create nodes like that.
    Nevertheless, there is one more way to edit or create a hierarchy.You can load a hierarchy from a flat file.But I am not sure it is worth it.If you have lots of elements and nodes then I propose you to go that way.Step by step document:
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/601b0771-92c4-2d10-a081-f947a516bd20?QuickLink=index&overridelayout=true

Maybe you are looking for