/** * Method addProfile. * * @param profile */ public void addProfile( Profile profile ) { getProfiles().add( profile ); } //-- void addProfile( Profile )
/** * Method removeProfile. * * @param profile */ public void removeProfile( Profile profile ) { getProfiles().remove( profile ); } //-- void removeProfile( Profile )
for ( Iterator it = root.getProfiles().iterator(); it.hasNext(); )
serializer.startTag( NAMESPACE, tagName ); serializer.attribute( "", "xsi:schemaLocation", "http://maven.apache.org/PROFILES/1.0.0 http://maven.apache.org/xsd/profiles-1.0.0.xsd" ); if ( ( profilesRoot.getProfiles() != null ) && ( profilesRoot.getProfiles().size() > 0 ) ) for ( Iterator iter = profilesRoot.getProfiles().iterator(); iter.hasNext(); )
private static void extractProfiles(Set<String> profileIds, File file) { extractProfilesFromModelLineage(file, profileIds); File basedir = FileUtil.normalizeFile(file.getParentFile()); FileObject fileObject = FileUtil.toFileObject(basedir); //read from profiles.xml Iterator it2 = MavenSettingsSingleton.createProfilesModel(fileObject).getProfiles().iterator(); while (it2.hasNext()) { org.apache.maven.profiles.Profile prof = (org.apache.maven.profiles.Profile) it2.next(); profileIds.add(prof.getId()); } }
/** * Method updateProfilesRoot * * @param value * @param element * @param counter * @param xmlTag */ protected void updateProfilesRoot(ProfilesRoot value, String xmlTag, Counter counter, Element element) { Element root = element; Counter innerCount = new Counter(counter.getDepth() + 1); iterateProfile(innerCount, root, value.getProfiles(),"profiles","profile"); findAndReplaceSimpleLists(innerCount, root, value.getActiveProfiles(), "activeProfiles", "activeProfile"); } //-- void updateProfilesRoot(ProfilesRoot, String, Counter, Element)
/** * Method updateProfilesRoot. * * @param value * @param element * @param counter * @param xmlTag */ protected void updateProfilesRoot(ProfilesRoot value, String xmlTag, Counter counter, Element element) { Element root = element; Counter innerCount = new Counter(counter.getDepth() + 1); iterateProfile(innerCount, root, value.getProfiles(),"profiles","profile"); findAndReplaceSimpleLists(innerCount, root, value.getActiveProfiles(), "activeProfiles", "activeProfile"); } //-- void updateProfilesRoot(ProfilesRoot, String, Counter, Element)
public org.apache.maven.profiles.Profile getNetbeansPrivateProfile(boolean addIfNotPresent) { if (privateProfile == null) { List lst = profiles.getProfiles(); if (lst != null) { Iterator it = lst.iterator();