KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > update > core > IIncludedFeatureReference


1 /*******************************************************************************
2  * Copyright (c) 2000, 2006 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.update.core;
12
13 import org.eclipse.core.runtime.CoreException;
14 import org.eclipse.core.runtime.IAdaptable;
15 import org.eclipse.core.runtime.IProgressMonitor;
16 import org.eclipse.update.configuration.IConfiguredSite;
17
18
19
20 /**
21  * Included Feature reference.
22  * A reference to a included feature.
23  * <p>
24  * Clients may implement this interface. However, in most cases clients should
25  * directly instantiate or subclass the provided implementation of this
26  * interface.
27  * </p>
28  * <p>
29  * <b>Note:</b> This class/interface is part of an interim API that is still under development and expected to
30  * change significantly before reaching stability. It is being made available at this early stage to solicit feedback
31  * from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken
32  * (repeatedly) as the API evolves.
33  * </p>
34  * @see org.eclipse.update.core.FeatureReference
35  * @since 2.0.1
36  */

37 public interface IIncludedFeatureReference extends IFeatureReference, IAdaptable {
38
39     /**
40      * Returns the referenced feature.
41      * This is a factory method that creates the full feature object.
42      * equivalent to getFeature(false,null);
43      *
44      * @return the referenced feature
45      * @deprecated use getFeature(IProgressMonitor)
46      * @since 2.0
47      */

48     public IFeature getFeature() throws CoreException;
49
50     /**
51      * Returns the referenced feature.
52      * This is a factory method that creates the full feature object.
53      *
54      * @param perfectMatch <code>true</code> if the perfect match feature feature should be returned
55      * <code>false</code> if the best match feature should be returned.
56      * @param configuredSite the configured site to search for the Feature. If
57      * the configured site is <code>null</code> the search will be done in the current configured site.
58      * @return the referenced feature
59      * instead
60      * @since 2.0.2
61      * <b>Note:</b> This method is part of an interim API that is still under development and expected to
62      * change significantly before reaching stability. It is being made available at this early stage to solicit feedback
63      * from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken
64      * (repeatedly) as the API evolves.
65      * @deprecated use getFeature(IProgressMonitor)
66      */

67     public IFeature getFeature(boolean perfectMatch,IConfiguredSite configuredSite) throws CoreException;
68
69     /**
70      * Returns the referenced feature.
71      * This is a factory method that creates the full feature object.
72      *
73      * @param perfectMatch <code>true</code> if the perfect match feature feature should be returned
74      * <code>false</code> if the best match feature should be returned.
75      * @param configuredSite the configured site to search for the Feature. If
76      * the configured site is <code>null</code> the search will be done in the current configured site.
77      * @param monitor the progress monitor
78      * @return the referenced feature
79      * @since 2.1
80      * <b>Note:</b> This method is part of an interim API that is still under
81      * development and expected to change significantly before reaching
82      * stability. It is being made available at this early stage to solicit
83      * feedback from pioneering adopters on the understanding that any code that
84      * uses this API will almost certainly be broken (repeatedly) as the API
85      * evolves.
86      * @deprecated use getFeature(IProgressMonitor)
87      */

88     public IFeature getFeature(boolean perfectMatch,IConfiguredSite configuredSite, IProgressMonitor monitor) throws CoreException;
89
90
91     /**
92      * Returns <code>true</code> if the feature is optional, <code>false</code> otherwise.
93      *
94      * @return boolean
95      * @since 2.0.1
96      */

97     public boolean isOptional();
98
99     /**
100      * Returns the matching rule for this included feature.
101      * The rule will determine the ability of the included feature to move version
102      * without causing the overall feature to appear broken.
103      *
104      * The default is <code>RULE_PERFECT</code>
105      *
106      * @see IUpdateConstants#RULE_PERFECT
107      * @see IUpdateConstants#RULE_EQUIVALENT
108      * @see IUpdateConstants#RULE_COMPATIBLE
109      * @see IUpdateConstants#RULE_GREATER_OR_EQUAL
110      * @return int representation of feature matching rule.
111      * @since 2.0.2
112      * @deprecated since 3.0 included feature version is exactly specified
113      */

114     public int getMatch();
115     
116     /**
117      * Returns the search location for this included feature.
118      * The location will be used to search updates for this feature.
119      *
120      * The default is <code>SEARCH_ROOT</code>
121      *
122      * @see IUpdateConstants#SEARCH_ROOT
123      * @see IUpdateConstants#SEARCH_SELF
124      * @return int representation of feature searching rule.
125      * @since 2.0.2
126      */

127
128     public int getSearchLocation();
129
130 }
131
Popular Tags