Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to get Profile ID

995445Mar 26 2013 — edited Mar 26 2013
Hi,

I registered several profiles for deployment, and need to know each profile type and profile ID for the project selected dynamically.
Profile name could be acquired from Profile classs method, getName(), but there is no support for getting the Profile ID method.

Below is the part of source code of the trial and error I made.

/************
DeploymentProfiles profiles = DeploymentProfiles.getInstance(proj);

for (Profile prof : profiles.getProfiles()) {


jarArchProfile = (ArchiveProfile) prof;
URL jarURL = jarArchProfile.getJarURL();

profileName = jarArchProfile.getName();

ProfileFactory.SpiData spi = ProfileFactory.SpiData.getInstance(context);
profileId = spi.getProfileId();

profileType = ProfileTypes.getInstance().getTypeFor(profileId);


*****************/


Is there any way to acquire Profile ID and Profile Type values for a Profile?

Best regards,
Cliff

Edited by: 992442 on 2013. 3. 26 오후 7:12

Edited by: 992442 on 2013. 3. 26 오후 7:13

Edited by: 992442 on 2013. 3. 26 오후 7:13

Edited by: 992442 on 2013. 3. 26 오후 7:14
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 23 2013
Added on Mar 26 2013
0 comments
336 views