KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > core > resources > mapping > ResourceMappingContext


1 /*******************************************************************************
2  * Copyright (c) 2004, 2005 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.core.resources.mapping;
12
13 /**
14  * A resource mapping context is provided to a resource mapping when traversing
15  * the resources of the mapping. The type of context may determine what resources
16  * are included in the traversals of a mapping.
17  * <p>
18  * There are currently two resource mapping contexts: the local mapping context
19  * (represented by the singleton {@link #LOCAL_CONTEXT}),
20  * and {@link RemoteResourceMappingContext}. Implementors of {@link ResourceMapping}
21  * should not assume that these are the only valid contexts (in order to allow future
22  * extensibility). Therefore, if the provided context is not of one of the above mentioned types,
23  * the implementor can assume that the context is a local context.
24  * </p>
25  * <p>
26  * This class may be subclassed by clients; this class is not intended to be
27  * instantiated directly.
28  * </p>
29  *
30  * @see ResourceMapping
31  * @see RemoteResourceMappingContext
32  * @since 3.2
33  */

34 public class ResourceMappingContext {
35
36     /**
37      * This resource mapping context is used to indicate that the operation
38      * that is requesting the traversals is performing a local operation.
39      * Because the operation is local, the resource mapping is free to be
40      * as precise as desired about what resources make up the mapping without
41      * concern for performing optimized remote operations.
42      */

43     public static final ResourceMappingContext LOCAL_CONTEXT = new ResourceMappingContext();
44
45 }
46
Popular Tags