Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [pde-dev] Target as Api Baseline

Hi JD,

Off the top of my head, I think that you should expand ApiModelFactory to have a new addComponents() method that takes a ITargetDefinition.  Alternatively you could pass in a File or URI to the .target file and handle the interaction with the ITargetPlatformService API inside the model factory.  This is similar to what the current addComponents method does.  However, be aware that API tools can be run without OSGi, meaning the ITargetPlatformService would be unavailable.  If you can't handle that case the javadoc should say so and log some sort of warning.

I don't think you would need to extend ApiBaseline to do this.  Certainly you don't want to extend WorkspaceBaseline as it builds a baseline from the current contents of the PDE model (combined workspace and target platform).

Are you planning to make this available in the UI?  You could have a new button on the pref page to add from target.  Then use the ITargetPlatformService to get a list of all targets (even those in the workspace) and allow the user to select one.

Curtis

Inactive hide details for Joseph D Carroll Jr ---07/31/2013 11:12:49 AM---I am working on implementing a new feature that allowJoseph D Carroll Jr ---07/31/2013 11:12:49 AM---I am working on implementing a new feature that allows a developer to specify/use an existing target

From: Joseph D Carroll Jr <jdsalingerjr@xxxxxxxxx>
To: pde-dev@xxxxxxxxxxx,
Date: 07/31/2013 11:12 AM
Subject: [pde-dev] Target as Api Baseline
Sent by: pde-dev-bounces@xxxxxxxxxxx





I am working on implementing a new feature that allows a developer to specify/use an existing target definition as an Api Baseline.

http://www.eclipse.org/forums/index.php/t/244906/
https://bugs.eclipse.org/bugs/show_bug.cgi?id=324310

The feature is almost complete, but the deeper I go the more I am running into problems.  Right now I am stuck on the difference between the classes o.e.pde.api.tools.internal.model.ApiBaseline and WorkspaceBaseline.

The implementation creates a new ITargetBasline which will allow for local targets and targets specified in the workspace through *.target files.  But from a model implementation standpoint, I'm not sure which I should extend from (ApiBaseline or WorkspaceBaseline) or both (and when)... ?

Any clarification would be much appreciated.

Thanks,

JD_______________________________________________
pde-dev mailing list
pde-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/pde-dev

GIF image


Back to the top