Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 349711 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/equinox/metatype/i1/Attribute.java (+46 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
import java.util.List;
4
5
/**
6
 * A value for an attribute of an object.
7
 * 
8
 * An Attribute contains the data from a single <code>&lt;attribute&gt;</code> 
9
 * element within the metadata XML. It represents a value, whose intent and 
10
 * format are described by the associated {@link #getAttributeDefinition() 
11
 * attribute definition}, for a configuration dictionary.
12
 * 
13
 * @ThreadSafe
14
 * @noimplement This interface is not intended to be implemented by clients.
15
 */
16
public interface Attribute extends Extendable {
17
	/**
18
	 * Returns the attribute definition associated with this attribute as 
19
	 * defined by the <code>adref</code> attribute of the <code>
20
	 * &lt;attribute&gt;</code> element.
21
	 * 
22
	 * @return The attribute definition associated with this attribute.
23
	 */
24
	EquinoxAttributeDefinition getAttributeDefinition();
25
26
	/**
27
	 * Returns the values for this attribute as specified within the <code>
28
	 * content</code> attribute of the <code>&lt;attribute&gt;</code> element. 
29
	 * If there is more than one value, the returned string will be a 
30
	 * comma-delimited list. All escape characters are retained.
31
	 * 
32
	 * @return The values for this attribute.
33
	 */
34
	String getContent();
35
36
	/**
37
	 * Returns the list of values for this attribute as specified within zero 
38
	 * or more child <code>&lt;value&gt;</code> elements of the <code>
39
	 * &lt;attribute&gt;</code> element. The list order represents the element 
40
	 * order presented within the XML. The list will be empty if no <code>
41
	 * &lt;value&gt;</code> elements were present.
42
	 * 
43
	 * @return A list of values for this attribute.
44
	 */
45
	List<String> getValues();
46
}
(-)src/org/eclipse/equinox/metatype/i1/Designate.java (+15 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
public interface Designate extends Extendable {
4
	String getBundle();
5
6
	String getFactoryPid();
7
8
	boolean isMerge();
9
10
	boolean isOptional();
11
12
	DesignateObject getObject();
13
14
	String getPid();
15
}
(-)src/org/eclipse/equinox/metatype/i1/DesignateObject.java (+9 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
import java.util.List;
4
5
public interface DesignateObject extends Extendable {
6
	List<Attribute> getAttributes();
7
8
	EquinoxObjectClassDefinition getObjectClassDefinition();
9
}
(-)src/org/eclipse/equinox/metatype/i1/EquinoxAttributeDefinition.java (+7 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
import org.osgi.service.metatype.AttributeDefinition;
4
5
public interface EquinoxAttributeDefinition extends AttributeDefinition, Extendable {
6
	// Empty interface to support extendable attribute definitions.
7
}
(-)src/org/eclipse/equinox/metatype/i1/EquinoxMetaTypeInformation.java (+7 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
import org.osgi.service.metatype.MetaTypeInformation;
4
5
public interface EquinoxMetaTypeInformation extends MetaTypeInformation {
6
	EquinoxObjectClassDefinition getObjectClassDefinition(String id, String locale);
7
}
(-)src/org/eclipse/equinox/metatype/i1/EquinoxMetaTypeService.java (+8 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
import org.osgi.framework.Bundle;
4
import org.osgi.service.metatype.MetaTypeService;
5
6
public interface EquinoxMetaTypeService extends MetaTypeService {
7
	EquinoxMetaTypeInformation getMetaTypeInformation(Bundle bundle);
8
}
(-)src/org/eclipse/equinox/metatype/i1/EquinoxObjectClassDefinition.java (+10 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
import java.util.List;
4
import org.osgi.service.metatype.ObjectClassDefinition;
5
6
public interface EquinoxObjectClassDefinition extends ObjectClassDefinition, Extendable {
7
	List<Designate> getDesignates();
8
9
	EquinoxAttributeDefinition[] getAttributeDefinitions(int filter);
10
}
(-)src/org/eclipse/equinox/metatype/i1/Extendable.java (+10 lines)
Added Link Here
1
package org.eclipse.equinox.metatype.i1;
2
3
import java.util.Map;
4
import java.util.Set;
5
6
public interface Extendable {
7
	Map<String, String> getExtensionAttributes(String schema);
8
9
	Set<String> getExtensionSchemas();
10
}

Return to bug 349711