1 /*******************************************************************************
2  * Copyright (c) 2000, 2010 IBM Corporation and others.
3  *
4  * This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License 2.0
6  * which accompanies this distribution, and is available at
7  * https://www.eclipse.org/legal/epl-2.0/
8  *
9  * SPDX-License-Identifier: EPL-2.0
10  *
11  * Contributors:
12  *     IBM Corporation - initial API and implementation
13  *     Serge Beauchamp (Freescale Semiconductor) - [229633] Group Support
14  *     Broadcom Corporation - build configurations
15  *******************************************************************************/
16 package org.eclipse.core.internal.resources;
17 
18 import org.eclipse.core.resources.*;
19 import org.eclipse.core.runtime.QualifiedName;
20 
21 public interface ICoreConstants {
22 
23 	// Standard resource properties
24 	/** map of builders to their last built state. */
25 	QualifiedName K_BUILD_LIST = new QualifiedName(ResourcesPlugin.PI_RESOURCES, "BuildMap"); //$NON-NLS-1$
26 
27 	/**
28 	 * Command line argument indicating a workspace refresh on startup is requested.
29 	 */
30 	String REFRESH_ON_STARTUP = "-refresh"; //$NON-NLS-1$
31 
32 	// resource info constants
33 	long I_NULL_SYNC_INFO = -1;
34 
35 	// Useful flag masks for resource info states
36 	int M_OPEN = 0x1;
37 	int M_LOCAL_EXISTS = 0x2;
38 	int M_PHANTOM = 0x8;
39 	int M_USED = 0x10;
40 	int M_TYPE = 0xF00;
41 	int M_TYPE_START = 8;
42 	int M_MARKERS_SNAP_DIRTY = 0x1000;
43 	int M_SYNCINFO_SNAP_DIRTY = 0x2000;
44 	/**
45 	 * Marks this resource as derived.
46 	 * @since 2.0
47 	 */
48 	int M_DERIVED = 0x4000;
49 	/**
50 	 * Marks this resource as a team-private member of its container.
51 	 * @since 2.0
52 	 */
53 	int M_TEAM_PRIVATE_MEMBER = 0x8000;
54 	/**
55 	 * Marks this resource as a hidden resource.
56 	 * @since 3.4
57 	 */
58 	int M_HIDDEN = 0x200000;
59 
60 	/**
61 	 * Marks this resource as a linked resource.
62 	 * @since 2.1
63 	 */
64 	int M_LINK = 0x10000;
65 	/**
66 	 * Marks this resource as virtual.
67 	 * @since 3.6
68 	 */
69 	int M_VIRTUAL = 0x80000;
70 	/**
71 	 * The file has no content description.
72 	 * @since 3.0
73 	 */
74 	int M_NO_CONTENT_DESCRIPTION = 0x20000;
75 	/**
76 	 * The file has a default content description.
77 	 * @since 3.0
78 	 */
79 	int M_DEFAULT_CONTENT_DESCRIPTION = 0x40000;
80 
81 	/**
82 	 * Marks this resource as having undiscovered children
83 	 * @since 3.1
84 	 */
85 	int M_CHILDREN_UNKNOWN = 0x100000;
86 
87 	/**
88 	 * Set of flags that should be cleared when the contents for a file change.
89 	 * @since 3.0
90 	 */
91 	int M_CONTENT_CACHE = M_NO_CONTENT_DESCRIPTION | M_DEFAULT_CONTENT_DESCRIPTION;
92 
93 	int NULL_FLAG = -1;
94 
95 	/**
96 	 * A private preference stored in a preference node to indicate the preference
97 	 * version that is used.  This version identifier is used to handle preference
98 	 * migration when old preferences are loaded.
99 	 */
100 	String PREF_VERSION_KEY = "version"; //$NON-NLS-1$
101 
102 	/**
103 	 * A private preference stored in a preference node to indicate the preference
104 	 * version that is used.  This version identifier is used to handle preference
105 	 * migration when old preferences are loaded.
106 	 */
107 	String PREF_VERSION = "1"; //$NON-NLS-1$
108 
109 	// Internal status codes
110 	// Information Only [00-24]
111 	// Warnings [25-74]
112 	int CRASH_DETECTED = 10035;
113 
114 	// Errors [75-99]
115 
116 	int PROJECT_SEGMENT_LENGTH = 1;
117 	int MINIMUM_FOLDER_SEGMENT_LENGTH = 2;
118 	int MINIMUM_FILE_SEGMENT_LENGTH = 2;
119 
120 	int WORKSPACE_TREE_VERSION_1 = 67305985;
121 	int WORKSPACE_TREE_VERSION_2 = 67305986;
122 
123 	// helper constants for empty structures
124 	IBuildConfiguration[] EMPTY_BUILD_CONFIG_ARRAY = new IBuildConfiguration[0];
125 	IProject[] EMPTY_PROJECT_ARRAY = new IProject[0];
126 	IResource[] EMPTY_RESOURCE_ARRAY = new IResource[0];
127 	IFileState[] EMPTY_FILE_STATES = new IFileState[0];
128 }
129