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 *******************************************************************************/ 14 package org.eclipse.core.resources; 15 16 import org.eclipse.core.runtime.*; 17 18 /** 19 * Represents status related to resources in the Resources plug-in and 20 * defines the relevant status code constants. 21 * Status objects created by the Resources plug-in bear its unique id 22 * (<code>ResourcesPlugin.PI_RESOURCES</code>) and one of 23 * these status codes. 24 * 25 * @see org.eclipse.core.runtime.IStatus 26 * @see ResourcesPlugin#PI_RESOURCES 27 * @noimplement This interface is not intended to be implemented by clients. 28 * @noextend This interface is not intended to be extended by clients. 29 */ 30 public interface IResourceStatus extends IStatus { 31 32 /* 33 * Status code definitions 34 */ 35 36 // General constants [0-98] 37 // Information Only [0-32] 38 // Warnings [33-65] 39 /** Status code constant (value 35) indicating that a given 40 * nature set does not satisfy its constraints. 41 * Severity: warning. Category: general. 42 */ 43 int INVALID_NATURE_SET = 35; 44 45 // Errors [66-98] 46 47 /** Status code constant (value 75) indicating that a builder failed. 48 * Severity: error. Category: general. 49 */ 50 int BUILD_FAILED = 75; 51 52 /** Status code constant (value 76) indicating that an operation failed. 53 * Severity: error. Category: general. 54 */ 55 int OPERATION_FAILED = 76; 56 57 /** Status code constant (value 77) indicating an invalid value. 58 * Severity: error. Category: general. 59 */ 60 int INVALID_VALUE = 77; 61 62 // Local file system constants [200-298] 63 // Information Only [200-232] 64 65 // Warnings [233-265] 66 67 /** Status code constant (value 234) indicating that a project 68 * description file (.project), was missing but it has been repaired. 69 * Severity: warning. Category: local file system. 70 */ 71 int MISSING_DESCRIPTION_REPAIRED = 234; 72 73 /** Status code constant (value 235) indicating the local file system location 74 * for a resource overlaps the location of another resource. 75 * Severity: warning. Category: local file system. 76 */ 77 int OVERLAPPING_LOCATION = 235; 78 79 // Errors [266-298] 80 81 /** Status code constant (value 268) indicating a resource unexpectedly 82 * exists on the local file system. 83 * Severity: error. Category: local file system. 84 */ 85 int EXISTS_LOCAL = 268; 86 87 /** Status code constant (value 269) indicating a resource unexpectedly 88 * does not exist on the local file system. 89 * Severity: error. Category: local file system. 90 */ 91 int NOT_FOUND_LOCAL = 269; 92 93 /** Status code constant (value 270) indicating the local file system location for 94 * a resource could not be computed. 95 * Severity: error. Category: local file system. 96 */ 97 int NO_LOCATION_LOCAL = 270; 98 99 /** Status code constant (value 271) indicating an error occurred while 100 * reading part of a resource from the local file system. 101 * Severity: error. Category: local file system. 102 */ 103 int FAILED_READ_LOCAL = 271; 104 105 /** Status code constant (value 272) indicating an error occurred while 106 * writing part of a resource to the local file system. 107 * Severity: error. Category: local file system. 108 */ 109 int FAILED_WRITE_LOCAL = 272; 110 111 /** Status code constant (value 273) indicating an error occurred while 112 * deleting a resource from the local file system. 113 * Severity: error. Category: local file system. 114 */ 115 int FAILED_DELETE_LOCAL = 273; 116 117 /** Status code constant (value 274) indicating the workspace view of 118 * the resource differs from that of the local file system. The requested 119 * operation has been aborted to prevent the possible loss of data. 120 * Severity: error. Category: local file system. 121 */ 122 int OUT_OF_SYNC_LOCAL = 274; 123 124 /** Status code constant (value 275) indicating this file system is not case 125 * sensitive and a resource that differs only in case unexpectedly exists on 126 * the local file system. 127 * Severity: error. Category: local file system. 128 */ 129 int CASE_VARIANT_EXISTS = 275; 130 131 /** Status code constant (value 276) indicating a file exists in the 132 * file system but is not of the expected type (file instead of directory, 133 * or vice-versa). 134 * Severity: error. Category: local file system. 135 */ 136 int WRONG_TYPE_LOCAL = 276; 137 138 /** Status code constant (value 277) indicating that the parent 139 * file in the file system is marked as read-only. 140 * Severity: error. Category: local file system. 141 * @since 2.1 142 */ 143 int PARENT_READ_ONLY = 277; 144 145 /** Status code constant (value 278) indicating a file exists in the 146 * file system but its name is not a valid resource name. 147 * Severity: error. Category: local file system. 148 */ 149 int INVALID_RESOURCE_NAME = 278; 150 151 /** Status code constant (value 279) indicating that the 152 * file in the file system is marked as read-only. 153 * Severity: error. Category: local file system. 154 * @since 3.0 155 */ 156 int READ_ONLY_LOCAL = 279; 157 158 // Workspace constants [300-398] 159 // Information Only [300-332] 160 161 // Warnings [333-365] 162 163 /** Status code constant (value 333) indicating that a workspace path 164 * variable unexpectedly does not exist. 165 * Severity: warning. Category: workspace. 166 * @since 2.1 167 */ 168 int VARIABLE_NOT_DEFINED_WARNING = 333; 169 170 // Errors [366-398] 171 172 /** Status code constant (value 366) indicating a resource exists in the 173 * workspace but is not of the expected type. 174 * Severity: error. Category: workspace. 175 */ 176 int RESOURCE_WRONG_TYPE = 366; 177 178 /** Status code constant (value 367) indicating a resource unexpectedly 179 * exists in the workspace. 180 * Severity: error. Category: workspace. 181 */ 182 int RESOURCE_EXISTS = 367; 183 184 /** Status code constant (value 368) indicating a resource unexpectedly 185 * does not exist in the workspace. 186 * Severity: error. Category: workspace. 187 */ 188 int RESOURCE_NOT_FOUND = 368; 189 190 /** Status code constant (value 369) indicating a resource unexpectedly 191 * does not have content local to the workspace. 192 * Severity: error. Category: workspace. 193 */ 194 int RESOURCE_NOT_LOCAL = 369; 195 196 /** Status code constant (value 370) indicating a workspace 197 * is unexpectedly closed. 198 * Severity: error. Category: workspace. 199 */ 200 int WORKSPACE_NOT_OPEN = 370; 201 202 /** Status code constant (value 372) indicating a project is 203 * unexpectedly closed. 204 * Severity: error. Category: workspace. 205 */ 206 int PROJECT_NOT_OPEN = 372; 207 208 /** Status code constant (value 374) indicating that the path 209 * of a resource being created is occupied by an existing resource 210 * of a different type. 211 * Severity: error. Category: workspace. 212 */ 213 int PATH_OCCUPIED = 374; 214 215 /** Status code constant (value 375) indicating that the sync partner 216 * is not registered with the workspace synchronizer. 217 * Severity: error. Category: workspace. 218 */ 219 int PARTNER_NOT_REGISTERED = 375; 220 221 /** Status code constant (value 376) indicating a marker unexpectedly 222 * does not exist in the workspace tree. 223 * Severity: error. Category: workspace. 224 */ 225 int MARKER_NOT_FOUND = 376; 226 227 /** Status code constant (value 377) indicating a resource is 228 * unexpectedly not a linked resource. 229 * Severity: error. Category: workspace. 230 * @since 2.1 231 */ 232 int RESOURCE_NOT_LINKED = 377; 233 234 /** Status code constant (value 378) indicating that linking is 235 * not permitted on a certain project. 236 * Severity: error. Category: workspace. 237 * @since 2.1 238 */ 239 int LINKING_NOT_ALLOWED = 378; 240 241 /** Status code constant (value 379) indicating that a workspace path 242 * variable unexpectedly does not exist. 243 * Severity: error. Category: workspace. 244 * @since 2.1 245 */ 246 int VARIABLE_NOT_DEFINED = 379; 247 248 /** Status code constant (value 380) indicating that an attempt was made to modify 249 * the workspace while it was locked. Resource changes are disallowed 250 * during certain types of resource change event notification. 251 * Severity: error. Category: workspace. 252 * @see IResourceChangeEvent 253 * @since 2.1 254 */ 255 int WORKSPACE_LOCKED = 380; 256 257 /** Status code constant (value 381) indicating that a problem occurred while 258 * retrieving the content description for a resource. 259 * Severity: error. Category: workspace. 260 * @see IFile#getContentDescription 261 * @since 3.0 262 */ 263 int FAILED_DESCRIBING_CONTENTS = 381; 264 265 /** Status code constant (value 382) indicating that a problem occurred while 266 * setting the charset for a resource. 267 * Severity: error. Category: workspace. 268 * @see IContainer#setDefaultCharset(String, IProgressMonitor) 269 * @see IFile#setCharset(String, IProgressMonitor) 270 * @since 3.0 271 */ 272 int FAILED_SETTING_CHARSET = 382; 273 274 /** Status code constant (value 383) indicating that a problem occurred while 275 * getting the charset for a resource. 276 * Severity: error. Category: workspace. 277 * @since 3.0 278 */ 279 int FAILED_GETTING_CHARSET = 383; 280 281 /** Status code constant (value 384) indicating a build configuration with 282 * the specified ID unexpectedly does not exist. 283 * Severity: error. Category: workspace. 284 * @since 3.7 285 */ 286 int BUILD_CONFIGURATION_NOT_FOUND = 384; 287 288 // Internal constants [500-598] 289 // Information Only [500-532] 290 291 // Warnings [533-565] 292 293 // Errors [566-598] 294 295 /** Status code constant (value 566) indicating an error internal to the 296 * platform has occurred. 297 * Severity: error. Category: internal. 298 */ 299 int INTERNAL_ERROR = 566; 300 301 /** Status code constant (value 567) indicating the platform could not read 302 * some of its metadata. 303 * Severity: error. Category: internal. 304 */ 305 int FAILED_READ_METADATA = 567; 306 307 /** Status code constant (value 568) indicating the platform could not write 308 * some of its metadata. 309 * Severity: error. Category: internal. 310 */ 311 int FAILED_WRITE_METADATA = 568; 312 313 /** Status code constant (value 569) indicating the platform could not delete 314 * some of its metadata. 315 * Severity: error. Category: internal. 316 */ 317 int FAILED_DELETE_METADATA = 569; 318 319 /** 320 * Returns the path of the resource associated with this status. 321 * 322 * @return the path of the resource related to this status 323 */ getPath()324 IPath getPath(); 325 } 326