<commit_before>/*******************************************************************************
 * Copyright (c) 2010 <NAME>.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     <NAME> - initial API and implementation
 *******************************************************************************/
package aQute.bnd.build.model;

import java.beans.*;
import java.io.*;
import java.util.*;
import java.util.Map.Entry;

import org.osgi.framework.*;

import aQute.bnd.build.model.clauses.*;
import aQute.bnd.build.model.conversions.*;
import aQute.lib.properties.*;
import aQute.lib.types.*;
import aQute.libg.header.*;
import aQute.libg.version.Version;

/**
 * A model for a Bnd file. In the first iteration, use a simple Properties
 * object; this will need to be enhanced to additionally record formatting, e.g.
 * line breaks and empty lines, and comments.
 *
 * @author <NAME>
 */
public class BndEditModel {

    public static final String LINE_SEPARATOR = " \\\n\t";
	public static final String LIST_SEPARATOR = ",\\\n\t";

	protected static final String ISO_8859_1 = "ISO-8859-1"; //$NON-NLS-1$

	@SuppressWarnings("deprecation")
    protected static String[] KNOWN_PROPERTIES = new String[] {
		Constants.BUNDLE_SYMBOLICNAME,
		Constants.BUNDLE_VERSION,
		Constants.BUNDLE_ACTIVATOR,
		Constants.EXPORT_PACKAGE,
		Constants.IMPORT_PACKAGE,
		aQute.lib.osgi.Constants.PRIVATE_PACKAGE,
		aQute.lib.osgi.Constants.SOURCES,
		aQute.lib.osgi.Constants.VERSIONPOLICY,
		aQute.lib.osgi.Constants.SERVICE_COMPONENT,
		aQute.lib.osgi.Constants.CLASSPATH,
		aQute.lib.osgi.Constants.BUILDPATH,
		aQute.lib.osgi.Constants.BUILDPACKAGES,
		aQute.lib.osgi.Constants.RUNBUNDLES,
		aQute.lib.osgi.Constants.RUNPROPERTIES,
		aQute.lib.osgi.Constants.SUB,
//		BndConstants.RUNFRAMEWORK,
		aQute.lib.osgi.Constants.RUNVM,
//		BndConstants.RUNVMARGS,
//		BndConstants.TESTSUITES,
		aQute.lib.osgi.Constants.TESTCASES,
		aQute.lib.osgi.Constants.PLUGIN,
		aQute.lib.osgi.Constants.PLUGINPATH,
//		BndConstants.RUNREQUIRE,
//		BndConstants.RUNEE,
//		BndConstants.RUNREPOS,
//		BndConstants.RESOLVE_MODE
	};

	public static final String BUNDLE_VERSION_MACRO = "${" + Constants.BUNDLE_VERSION + "}";

	private final Map<String, Converter<? extends Object, String>> converters = new HashMap<String, Converter<? extends Object,String>>();
	private final Map<String, Converter<String, ? extends Object>> formatters = new HashMap<String, Converter<String, ? extends Object>>();
//	private final DataModelHelper obrModelHelper = new DataModelHelperImpl();

	private final PropertyChangeSupport propChangeSupport = new PropertyChangeSupport(this);
	private final Properties properties = new Properties();;

	private File bndResource;<commit_msg>Set some more to protected<commit_after>/*******************************************************************************
 * Copyright (c) 2010 <NAME>.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     <NAME> - initial API and implementation
 *******************************************************************************/
package aQute.bnd.build.model;

import java.beans.*;
import java.io.*;
import java.util.*;
import java.util.Map.Entry;

import org.osgi.framework.*;

import aQute.bnd.build.model.clauses.*;
import aQute.bnd.build.model.conversions.*;
import aQute.lib.properties.*;
import aQute.lib.types.*;
import aQute.libg.header.*;
import aQute.libg.version.Version;

/**
 * A model for a Bnd file. In the first iteration, use a simple Properties
 * object; this will need to be enhanced to additionally record formatting, e.g.
 * line breaks and empty lines, and comments.
 *
 * @author <NAME>
 */
public class BndEditModel {

    public static final String LINE_SEPARATOR = " \\\n\t";
	public static final String LIST_SEPARATOR = ",\\\n\t";

	protected static final String ISO_8859_1 = "ISO-8859-1"; //$NON-NLS-1$

	@SuppressWarnings("deprecation")
    protected static String[] KNOWN_PROPERTIES = new String[] {
		Constants.BUNDLE_SYMBOLICNAME,
		Constants.BUNDLE_VERSION,
		Constants.BUNDLE_ACTIVATOR,
		Constants.EXPORT_PACKAGE,
		Constants.IMPORT_PACKAGE,
		aQute.lib.osgi.Constants.PRIVATE_PACKAGE,
		aQute.lib.osgi.Constants.SOURCES,
		aQute.lib.osgi.Constants.VERSIONPOLICY,
		aQute.lib.osgi.Constants.SERVICE_COMPONENT,
		aQute.lib.osgi.Constants.CLASSPATH,
		aQute.lib.osgi.Constants.BUILDPATH,
		aQute.lib.osgi.Constants.BUILDPACKAGES,
		aQute.lib.osgi.Constants.RUNBUNDLES,
		aQute.lib.osgi.Constants.RUNPROPERTIES,
		aQute.lib.osgi.Constants.SUB,
//		BndConstants.RUNFRAMEWORK,
		aQute.lib.osgi.Constants.RUNVM,
//		BndConstants.RUNVMARGS,
//		BndConstants.TESTSUITES,
		aQute.lib.osgi.Constants.TESTCASES,
		aQute.lib.osgi.Constants.PLUGIN,
		aQute.lib.osgi.Constants.PLUGINPATH,
//		BndConstants.RUNREQUIRE,
//		BndConstants.RUNEE,
//		BndConstants.RUNREPOS,
//		BndConstants.RESOLVE_MODE
	};

	public static final String BUNDLE_VERSION_MACRO = "${" + Constants.BUNDLE_VERSION + "}";

	protected final Map<String, Converter<? extends Object, String>> converters = new HashMap<String, Converter<? extends Object,String>>();
	protected final Map<String, Converter<String, ? extends Object>> formatters = new HashMap<String, Converter<String, ? extends Object>>();
//	private final DataModelHelper obrModelHelper = new DataModelHelperImpl();

	private final PropertyChangeSupport propChangeSupport = new PropertyChangeSupport(this);
	private final Properties properties = new Properties();;

	private File bndResource;
{'fraction_non_alphanumeric': 0.16410082896295042, 'fraction_numerical': 0.006428692268651667, 'mean_word_length': 4.882587064676617, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2890180', 'n_tokens_mistral': 1973, 'n_tokens_neox': 1899, 'n_words': 417}