Package org.netbeans.gradle.project.api.config

Examples of org.netbeans.gradle.project.api.config.ProfileDef


        int suffixLength = PROFILE_FILE_NAME_SUFFIX.length();
        for (File profileFile: profileFiles) {
            String fileName = profileFile.getName();
            if (fileName.length() >= suffixLength) {
                String profileName = fileName.substring(0, fileName.length() - suffixLength);
                result.add(new ProfileDef(null, fileName, profileName));
            }
        }
        return result;
    }
View Full Code Here


    public static ProfileDef getStandardProfileDef(String profileName) {
        if (profileName == null) {
            return null;
        }
        else {
            return new ProfileDef(null, profileName + PROFILE_FILE_NAME_SUFFIX, profileName);
        }
    }
View Full Code Here

        this.groupName = def.getGroupName();
        this.fileName = def.getFileName();
    }

    public NbGradleConfiguration findSameConfig(Collection<? extends NbGradleConfiguration> configs) {
        NbGradleConfiguration toSearch = new NbGradleConfiguration(new ProfileDef(groupName, fileName, "?"));
        for (NbGradleConfiguration config: configs) {
            if (toSearch.equals(config)) {
                return config;
            }
        }
View Full Code Here

                !command.isBlocking());
    }

    @Override
    public MutableProperty<PredefinedTask> tryGetBuiltInTask(String command) {
        ProfileDef profile = project.getCurrentProfile().getProfileDef();
        GradleCommandTemplate commandTemplate
                = project.getMergedCommandQuery().tryGetDefaultGradleCommand(profile, command);

        final PredefinedTask task = commandTemplate != null
                ? templateToPredefined(command, commandTemplate)
View Full Code Here

        String profileName = panel.getProfileName();
        if (profileName.isEmpty()) {
            return;
        }
        ProfileDef profileDef = SettingsFiles.getStandardProfileDef(profileName);
        NbGradleConfiguration newConfig = new NbGradleConfiguration(profileDef);
        ProfileItem newProfile = new ProfileItem(newConfig);

        project.getLookup().lookup(NbGradleSingleProjectConfigProvider.class).addConfiguration(newConfig);
View Full Code Here

    public ProjectProperties getProperties() {
        return properties;
    }

    public ProjectProperties getPrivateProperties() {
        ProfileDef privateDef = new ProfileDef("private", "aux-config", "Private profiles");
        return getPropertiesForProfile(privateDef, false, null);
    }
View Full Code Here

        }
        return properties;
    }

    private CustomCommandActions getCommandActions(NbGradleConfiguration config, String command) {
        ProfileDef profileDef = config.getProfileDef();
        return project.getMergedCommandQuery().tryGetCommandDefs(profileDef, command);
    }
View Full Code Here

        File lastProfileFile = getLastProfileFile();

        NbGradleConfiguration config = activeConfig.get();
        if (config != null) {
            ProfileDef profileDef = config.getProfileDef();
            if (profileDef == null) {
                if (!lastProfileFile.delete()) {
                    LOGGER.log(Level.FINE, "Last profile file could not be deleted: {0}", lastProfileFile);
                }
                return;
View Full Code Here

TOP

Related Classes of org.netbeans.gradle.project.api.config.ProfileDef

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.