You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by gn...@apache.org on 2009/04/10 15:23:44 UTC
svn commit: r763927 [3/4] - in /geronimo/sandbox/gnodet/blueprint: ./ src/
src/main/ src/main/java/ src/main/java/org/ src/main/java/org/apache/
src/main/java/org/apache/felix/ src/main/java/org/apache/felix/blueprint/
src/main/java/org/apache/felix/bl...
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/ParserContext.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/ParserContext.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/ParserContext.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/ParserContext.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.namespace;
+
+import org.w3c.dom.Node;
+
+import org.osgi.service.blueprint.reflect.ComponentMetadata;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Apr 2, 2009
+ * Time: 9:38:28 PM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ParserContext {
+
+ ComponentDefinitionRegistry getComponentDefinitionRegistry();
+
+ ComponentMetadata getEnclosingComponent();
+
+ Node getSourceNode();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/package.html
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/package.html?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/package.html (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/namespace/package.html Fri Apr 10 13:23:41 2009
@@ -0,0 +1,32 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<html>
+<head>
+</head>
+<body>
+
+Blueprint Namespace Package Version 1.0.
+
+Bundles wishing to use this package must list the package in the Import-Package
+header of the bundle's manifest. For example:
+
+<code>Import-Package: org.osgi.service.blueprint.namespace;version="[1.0,2.0)"</code>
+
+This package provides the top-level interfaces needed for implementing a namespace handler.
+
+</body>
+</html>
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ArrayValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ArrayValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ArrayValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ArrayValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Apr 2, 2009
+ * Time: 9:41:23 PM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ArrayValue extends Value {
+
+ Value[] getArray();
+
+ String getValueType();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/BindingListenerMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/BindingListenerMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/BindingListenerMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/BindingListenerMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:47:40 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface BindingListenerMetadata {
+
+ /**
+ * The component instance that will receive bind and unbind
+ * events. The returned value must reference a component and therefore be
+ * either a ComponentValue, ReferenceValue, or ReferenceNameValue.
+ *
+ * @return the listener component reference.
+ */
+ Value getListenerComponent();
+
+ /**
+ * The name of the method to invoke on the listener component when
+ * a matching service is bound to the reference
+ *
+ * @return the bind callback method name.
+ */
+ String getBindMethodName();
+
+ /**
+ * The name of the method to invoke on the listener component when
+ * a service is unbound from the reference.
+ *
+ * @return the unbind callback method name.
+ */
+ String getUnbindMethodName();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/CollectionBasedServiceReferenceComponentMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/CollectionBasedServiceReferenceComponentMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/CollectionBasedServiceReferenceComponentMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/CollectionBasedServiceReferenceComponentMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,82 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:46:34 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface CollectionBasedServiceReferenceComponentMetadata extends
+ ServiceReferenceComponentMetadata {
+
+ /**
+ * Create natural ordering based on comparison on service objects.
+ */
+ public static final int ORDER_BASIS_SERVICES = 1;
+
+ /**
+ * Create natural ordering based on comparison of service reference objects.
+ */
+ public static final int ORDER_BASIS_SERVICE_REFERENCES = 2;
+
+ /**
+ * Collection contains service instances
+ */
+ public static final int MEMBER_TYPE_SERVICES = 1;
+
+ /**
+ * Collection contains service references
+ */
+ public static final int MEMBER_TYPE_SERVICE_REFERENCES = 2;
+
+ /**
+ * The type of collection to be created.
+ *
+ * @return Class object for the specified collection type (List, Set).
+ */
+ Class getCollectionType();
+
+ /**
+ * The comparator specified for ordering the collection, or null if no
+ * comparator was specified.
+ *
+ * @return if a comparator was specified then a Value object identifying the
+ * comparator (a ComponentValue, ReferenceValue, or ReferenceNameValue) is
+ * returned. If no comparator was specified then null will be returned.
+ */
+ Value getComparator();
+
+ /**
+ * The basis on which to perform ordering, if specified.
+ *
+ * @return one of ORDER_BASIS_SERVICES and ORDER_BASIS_SERVICE_REFERENCES
+ */
+ int getOrderingComparisonBasis();
+
+ /**
+ * Whether the collection will contain service instances, or service references.
+ *
+ * @return one of MEMBER_TYPE_SERVICES and MEMBER_TYPE_SERVICE_REFERENCES
+ */
+ int getMemberType();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.Set;
+
+
+/**
+ * Metadata for a component defined within a given module context.
+ *
+ * @see LocalComponentMetadata
+ * @see ServiceReferenceComponentMetadata
+ * @see ServiceExportComponentMetadata
+ */
+public interface ComponentMetadata {
+
+ /**
+ * The name of the component.
+ *
+ * @return component name. The component name may be null if this is an anonymously
+ * defined inner component.
+ */
+ String getName();
+
+ /**
+ * The names of any components listed in a "depends-on" attribute for this
+ * component.
+ *
+ * @return an immutable set of component names for components that we have explicitly
+ * declared a dependency on, or an empty set if none.
+ */
+ Set getExplicitDependencies();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ComponentValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:40:31 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ComponentValue extends Value {
+
+ ComponentMetadata getComponentMetadata();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ConstructorInjectionMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ConstructorInjectionMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ConstructorInjectionMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ConstructorInjectionMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,37 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.List;
+
+/**
+ */
+public interface ConstructorInjectionMetadata {
+
+ /**
+ * The parameter specifications that determine which constructor to invoke
+ * (in the case of overloading) and what arguments to pass to it.
+ *
+ * @return an immutable list of ParameterSpecification, or an empty list if the default
+ * constructor is to be invoked. The list is ordered by ascending parameter index.
+ * I.e., the first parameter is first in the list, and so on.
+ */
+ List getParameterSpecifications();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ListValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ListValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ListValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ListValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.List;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:42:02 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ListValue extends Value {
+
+ List getList();
+
+ String getValueType();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/LocalComponentMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/LocalComponentMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/LocalComponentMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/LocalComponentMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,110 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.Collection;
+
+public interface LocalComponentMetadata extends ComponentMetadata {
+
+ static final String SCOPE_SINGLETON = "singleton";
+ static final String SCOPE_PROTOTYPE = "prototype";
+ static final String SCOPE_BUNDLE = "bundle";
+
+ /**
+ * The name of the class type specified for this component.
+ *
+ * @return the name of the component class.
+ */
+ String getClassName();
+
+ /**
+ * The name of the init method specified for this component, if any.
+ *
+ * @return the method name of the specified init method, or null if
+ * no init method was specified.
+ */
+ String getInitMethodName();
+
+
+ /**
+ * The name of the destroy method specified for this component, if any.
+ *
+ * @return the method name of th * destroy method was specified.
+ */
+ String getDestroyMethodName();
+
+ /**
+ * The constructor injection metadata for this component.
+ *
+ * @return the constructor injection metadata. This is guaranteed to be
+ * non-null and will refer to the default constructor if no explicit
+ * constructor injection was specified for the component.
+ */
+ ConstructorInjectionMetadata getConstructorInjectionMetadata();
+
+ /**
+ * The property injection metadata for this component.
+ *
+ * @return an array containing one entry for each property to be injected. If
+ * no property injection was specified for this component then an empty array
+ * will be returned.
+ */
+ Collection getPropertyInjectionMetadata();
+
+ /**
+ * Is this component to be lazily instantiated?
+ *
+ * @return true, iff this component definition specifies lazy
+ * instantiation.
+ */
+ boolean isLazy();
+
+ /**
+ * The metadata describing how to create the component instance by invoking a
+ * method (as opposed to a constructor) if factory methods are used.
+ *
+ * @return the method injection metadata for the specified factory method, or null if no
+ * factory method is used for this component.
+ */
+ MethodInjectionMetadata getFactoryMethodMetadata();
+
+ /**
+ * The component instance on which to invoke the factory method (if specified).
+ *
+ * @return when a factory method and factory component has been specified for this
+ * component, this operation returns the metadata specifying the component on which
+ * the factory method is to be invoked. When no factory component has been specified
+ * this operation will return null. A return value of null with a non-null factory method
+ * indicates that the factory method should be invoked as a static method on the
+ * component class itself. For a non-null return value, the Value object returned will
+ * be either a ComponentValue or a ReferenceValue
+ */
+ Value getFactoryComponent();
+
+ /**
+ * The specified scope for the component lifecycle.
+ *
+ * @return a String indicating the scope specified for the component.
+ *
+ * @see #SCOPE_SINGLETON
+ * @see #SCOPE_PROTOTYPE
+ * @see #SCOPE_BUNDLE
+ */
+ String getScope();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MapValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MapValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MapValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MapValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,38 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.Map;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:41:21 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface MapValue extends Value {
+
+ String getValueType();
+
+ String getKeyType();
+
+ Map getMap();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MethodInjectionMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MethodInjectionMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MethodInjectionMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/MethodInjectionMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.List;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:34:45 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface MethodInjectionMetadata {
+
+ /**
+ * The name of the method to be invoked.
+ *
+ * @return the method name, overloaded methods are disambiguated by
+ * parameter specifications.
+ */
+ String getName();
+
+ /**
+ * The parameter specifications that determine which method to invoke
+ * (in the case of overloading) and what arguments to pass to it.
+ *
+ * @return an array of parameter specifications, or an empty array if the
+ * method takes no arguments.
+ */
+ List getParameterSpecifications();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/NullValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/NullValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/NullValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/NullValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:42:41 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface NullValue extends Value {
+
+ public static final NullValue NULL = new NullValue() {};
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ParameterSpecification.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ParameterSpecification.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ParameterSpecification.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ParameterSpecification.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:37:03 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ParameterSpecification {
+
+
+ /**
+ * The value to inject into the parameter.
+ *
+ * @return the parameter value
+ */
+ Value getValue();
+
+ /**
+ * The type to convert the value into when invoking the constructor or
+ * factory method. If no explicit type was specified on the component
+ * definition then this method returns null.
+ *
+ * @return the explicitly specified type to convert the value into, or
+ * null if no type was specified in the component definition.
+ */
+ String getTypeName();
+
+ /**
+ * The (zero-based) index into the parameter list of the method or
+ * constructor to be invoked for this parameter. This is determined
+ * either by explicitly specifying the index attribute in the component
+ * declaration, or by declaration order of constructor-arg elements if the
+ * index was not explicitly set.
+ *
+ * @return the zero-based parameter index
+ */
+ int getIndex();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertiesValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertiesValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertiesValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertiesValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.Properties;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:42:24 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface PropertiesValue extends Value {
+
+ Properties getPropertiesValue();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertyInjectionMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertyInjectionMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertyInjectionMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/PropertyInjectionMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:34:23 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface PropertyInjectionMetadata {
+
+ /**
+ * The name of the property to be injected, following JavaBeans
+ * conventions.
+ *
+ * @return the property name.
+ */
+ String getName();
+
+ /**
+ * The value to inject the property with.
+ *
+ * @return the property value.
+ */
+ Value getValue();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceNameValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceNameValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceNameValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceNameValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:41:04 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ReferenceNameValue extends Value {
+
+ String getReferenceName();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ReferenceValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:40:48 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ReferenceValue extends Value {
+
+ /**
+ * The name of the referenced component.
+ */
+ String getComponentName();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListenerMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListenerMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListenerMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListenerMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,53 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:44:46 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface RegistrationListenerMetadata {
+
+ /**
+ * The component instance that will receive registration and unregistration
+ * events. The returned value must reference a component and therefore be
+ * either a ComponentValue, ReferenceValue, or ReferenceNameValue.
+ *
+ * @return the listener component reference.
+ */
+ Value getListenerComponent();
+
+ /**
+ * The name of the method to invoke on the listener component when
+ * the exported service is registered with the service registry.
+ *
+ * @return the registration callback method name.
+ */
+ String getRegistrationMethodName();
+
+ /**
+ * The name of the method to invoke on the listener component when
+ * the exported service is unregistered from the service registry.
+ *
+ * @return the unregistration callback method name.
+ */
+ String getUnregistrationMethodName();}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceExportComponentMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceExportComponentMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceExportComponentMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceExportComponentMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,104 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.Properties;
+import java.util.Collection;
+import java.util.Set;
+import java.util.Map;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:43:22 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ServiceExportComponentMetadata extends ComponentMetadata {
+
+ /**
+ * Do not auto-detect types for advertised service intefaces
+ */
+ public static final int EXPORT_MODE_DISABLED = 1;
+
+ /**
+ * Advertise all Java interfaces implemented by the exported component as
+ * service interfaces.
+ */
+ public static final int EXPORT_MODE_INTERFACES = 2;
+
+ /**
+ * Advertise all Java classes in the hierarchy of the exported component's type
+ * as service interfaces.
+ */
+ public static final int EXPORT_MODE_CLASS_HIERARCHY = 3;
+
+ /**
+ * Advertise all Java classes and interfaces in the exported component's type as
+ * service interfaces.
+ */
+ public static final int EXPORT_MODE_ALL = 4;
+
+ /**
+ * The component that is to be exported as a service. Value must refer to a component and
+ * therefore be either a ComponentValue, ReferenceValue, or ReferenceNameValue.
+ *
+ * @return the component to be exported as a service.
+ */
+ Value getExportedComponent();
+
+ /**
+ * The type names of the set of interface types that the service should be advertised
+ * as supporting.
+ *
+ * @return an immutable set of (String) type names, or an empty set if using auto-export
+ */
+ Set getInterfaceNames();
+
+ /**
+ * Return the auto-export mode specified.
+ *
+ * @return One of EXPORT_MODE_DISABLED, EXPORT_MODE_INTERFACES, EXPORT_MODE_CLASS_HIERARCHY, EXPORT_MODE_ALL
+ */
+ int getAutoExportMode();
+
+ /**
+ * The user declared properties to be advertised with the service.
+ *
+ * @return Properties object containing the set of user declared service properties (may be
+ * empty if no properties were specified).
+ */
+ Map getServiceProperties();
+
+ /**
+ * The ranking value to use when advertising the service
+ *
+ * @return service ranking
+ */
+ int getRanking();
+
+ /**
+ * The listeners that have registered to be notified when the exported service
+ * is registered and unregistered with the framework.
+ *
+ * @return an immutable collection of RegistrationListenerMetadata
+ */
+ Collection getRegistrationListeners();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceComponentMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceComponentMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceComponentMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceComponentMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,79 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.Collection;
+import java.util.Set;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:45:26 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface ServiceReferenceComponentMetadata extends ComponentMetadata {
+
+ /**
+ * A matching service is required at all times.
+ */
+ public static final int AVAILABILITY_MANDATORY = 1;
+
+ /**
+ * A matching service is not required to be present.
+ */
+ public static final int AVAILABILITY_OPTIONAL = 2;
+
+ /**
+ * Whether or not a matching service is required at all times.
+ *
+ * @return one of MANDATORY_AVAILABILITY or OPTIONAL_AVAILABILITY
+ */
+ int getServiceAvailabilitySpecification();
+
+ /**
+ * The interface types that the matching service must support
+ *
+ * @return an array of type names
+ */
+ Set getInterfaceNames();
+
+ /**
+ * The value of the component name attribute, if specified.
+ *
+ * @return the component name attribute value, or null if the attribute was not specified
+ */
+ String getComponentName();
+
+ /**
+ * The filter expression that a matching service must pass
+ *
+ * @return filter expression
+ */
+ String getFilter();
+
+ /**
+ * The set of listeners registered to receive bind and unbind events for
+ * backing services.
+ *
+ * @return an immutable collection of registered BindingListenerMetadata
+ */
+ Collection getBindingListeners();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/SetValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/SetValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/SetValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/SetValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+import java.util.Set;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:41:41 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface SetValue extends Value {
+
+ String getValueType();
+
+ Set getSet();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/TypedStringValue.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/TypedStringValue.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/TypedStringValue.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/TypedStringValue.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:42:53 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface TypedStringValue extends Value {
+
+ /**
+ * The string value (unconverted) of this value).
+ */
+ String getStringValue();
+
+
+ /**
+ * The name of the type to which this value should be coerced. May be
+ * null.
+ */
+ String getTypeName();
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/UnaryServiceReferenceComponentMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/UnaryServiceReferenceComponentMetadata.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/UnaryServiceReferenceComponentMetadata.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/UnaryServiceReferenceComponentMetadata.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * Created by IntelliJ IDEA.
+ * User: gnodet
+ * Date: Mar 26, 2009
+ * Time: 11:46:14 AM
+ * To change this template use File | Settings | File Templates.
+ */
+public interface UnaryServiceReferenceComponentMetadata extends
+ ServiceReferenceComponentMetadata {
+
+ /**
+ * Timeout for service invocations when a matching backing service
+ * is unavailable.
+ *
+ * @return service invocation timeout in milliseconds
+ */
+ long getTimeout();
+
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/Value.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/Value.java?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/Value.java (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/Value.java Fri Apr 10 13:23:41 2009
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.osgi.service.blueprint.reflect;
+
+/**
+ * A value to inject into a field, property, method argument or constructor
+ * argument.
+ */
+public interface Value {
+ // deliberately left empty
+}
Added: geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/package.html
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/package.html?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/package.html (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/java/org/osgi/service/blueprint/reflect/package.html Fri Apr 10 13:23:41 2009
@@ -0,0 +1,109 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<html>
+<head>
+</head>
+<body>
+
+Blueprint Reflection Package Version 1.0.
+
+Bundles wishing to use this package must list the package in the Import-Package
+header of the bundle's manifest. For example:
+
+<code>Import-Package: org.osgi.service.blueprint.reflect;version="[1.0,2.0)"</code>
+
+This package provides a reflection based view of the configuration information for a given module
+context. The top-level mapping between configuration elements and reflection types is as follows:
+
+ <table>
+ <tr>
+ <th>Configuration Element</th>
+ <th>Corresponding Reflection Type(s)</th>
+ </tr>
+ <tr>
+ <td>component</td>
+ LocalComponentMetadata, ComponentValue
+ <td></td>
+ </tr>
+ <tr>
+ <td>reference</td>
+ <td>UnaryServiceReferenceComponentMetadata</td>
+ </tr>
+ <tr>
+ <td>ref-set,ref-list</td>
+ <td>CollectionBasedServiceReferenceComponentMetadata</td>
+ </tr>
+ <tr>
+ <td>service</td>
+ <td>ServiceExportComponentMetadata</td>
+ </tr>
+ <tr>
+ <td>constructor-arg</td>
+ <td>ConstructorInjectionMetadata, ParameterSpecification</td>
+ </tr>
+ <tr>
+ <td>property</td>
+ <td>PropertyInjectionMetadata</td>
+ </tr>
+ <tr>
+ <td>listener</td>
+ <td>BindingListenerMetadata</td>
+ </tr>
+ <tr>
+ <td>registration-listener</td>
+ <td>RegistrationListenerMetadata</td>
+ </tr>
+ <tr>
+ <td>array</td>
+ <td>ArrayValue</td>
+ </tr>
+ <tr>
+ <td>ref</td>
+ <td>ReferenceValue</td>
+ </tr>
+ <tr>
+ <td>id-ref</td>
+ <td>ReferenceNameValue</td>
+ </tr>
+ <tr>
+ <td>list</td>
+ <td>ListValue</td>
+ </tr>
+ <tr>
+ <td>map</td>
+ <td>MapValue</td>
+ </tr>
+ <tr>
+ <td>null</td>
+ <td>NullValue</td>
+ </tr>
+ <tr>
+ <td>props</td>
+ <td>PropertiesValue</td>
+ </tr>
+ <tr>
+ <td>set</td>
+ <td>SetValue</td>
+ </tr>
+ <tr>
+ <td>value</td>
+ <td>TypedStringValue</td>
+ </tr>
+ </table>
+
+</body>
+</html>
Added: geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint-compendium.xsd
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint-compendium.xsd?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint-compendium.xsd (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint-compendium.xsd Fri Apr 10 13:23:41 2009
@@ -0,0 +1,94 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<xsd:schema xmlns="http://www.osgi.org/xmlns/blueprint-compendium/v1.0.0"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:osgi="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+ targetNamespace="http://www.osgi.org/xmlns/blueprint-compendium/v1.0.0"
+ elementFormDefault="qualified"
+ attributeFormDefault="unqualified"
+ version="1.0.0">
+
+ <xsd:import namespace="blueprint.xsd"/>
+
+ <!-- property placeholder -->
+
+ <xsd:element name="property-placeholder" type="TpropertyPlaceholder"/>
+
+
+ <xsd:complexType name="TpropertyPlaceholder">
+ <xsd:complexContent>
+ <xsd:extension base="osgi:TidentifiedType">
+ <xsd:sequence minOccurs="0" maxOccurs="1">
+ <!-- nested properties declaration -->
+ <xsd:element name="default-properties" type="TdefaultProperties" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="persistent-id" type="xsd:string" use="required"/>
+ <xsd:attribute name="placeholder-prefix" type="xsd:string" use="optional" default="${"/>
+ <xsd:attribute name="placeholder-suffix" type="xsd:string" use="optional" default="}"/>
+ <xsd:attribute name="defaults-ref" type="xsd:string" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="TdefaultProperties">
+ <xsd:sequence minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="osgi:property"/>
+ </xsd:sequence>
+ </xsd:complexType>
+
+ <!-- managed-property -->
+
+ <xsd:element name="managed-properties" type="TmanagedProperties"/>
+
+ <xsd:complexType name="TmanagedProperties">
+ <xsd:attribute name="persistent-id" type="xsd:string" use="required"/>
+ <xsd:attribute name="update-strategy" type="TupdateStrategyType" use="optional"/>
+ <xsd:attribute name="update-method" type="xsd:string" use='optional'/>
+ </xsd:complexType>
+
+ <xsd:simpleType name="TupdateStrategyType">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="none"/>
+ <xsd:enumeration value="component-managed"/>
+ <xsd:enumeration value="container-managed"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <!-- managed-service-factory -->
+
+ <xsd:element name="managed-service-factory" type="TmanagedServiceFactory"/>
+
+ <xsd:complexType name="TmanagedServiceFactory">
+ <xsd:complexContent>
+ <xsd:extension base="osgi:TidentifiedType">
+ <xsd:sequence>
+ <xsd:group ref="osgi:serviceElements"/>
+ <xsd:element name="managed-component" type="TmanagedComponent" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="factory-pid" type="xsd:string" use="required"/>
+ <xsd:attribute name="auto-export" type="osgi:TautoExportModes" default="disabled"/>
+ <xsd:attribute name="ranking" type="xsd:int" default="0"/>
+ <xsd:anyAttribute namespace="##other" processContents="lax"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="TmanagedComponent">
+ <xsd:group ref="osgi:componentElements"/>
+ <xsd:attribute name="class" type="xsd:string"/>
+ <xsd:attribute name="init-method" type="xsd:string"/>
+ <xsd:attribute name="destroy-method" type="xsd:string"/>
+ <xsd:attribute name="factory-method" type="xsd:string"/>
+ <xsd:attribute name="factory-component" type="xsd:string"/>
+ <xsd:anyAttribute namespace="##other" processContents="lax"/>
+ </xsd:complexType>
+
+ <!-- cm-properties -->
+
+ <xsd:element name="cm-properties" type="TcmProperties"/>
+
+ <xsd:complexType name="TcmProperties">
+ <xsd:attribute name="persistent-id" type="xsd:string" use="required"/>
+ <xsd:attribute name="update" type="xsd:boolean" use="optional" default="false"/>
+ </xsd:complexType>
+
+</xsd:schema>
Added: geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint.xsd
URL: http://svn.apache.org/viewvc/geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint.xsd?rev=763927&view=auto
==============================================================================
--- geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint.xsd (added)
+++ geronimo/sandbox/gnodet/blueprint/src/main/resources/org/apache/felix/blueprint/blueprint.xsd Fri Apr 10 13:23:41 2009
@@ -0,0 +1,468 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<xsd:schema xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+ elementFormDefault="qualified"
+ attributeFormDefault="unqualified"
+ version="1.0.0">
+
+ <!--
+
+ TODO: service/interfaces can have child elements other than "value"
+ TODO: service can not have a nested component element
+ TODO: ref and idref elements have the same schema definition, are both actually needed ?
+ TODO: what is reference/@component-name about ?
+
+ 5.3.1: the component/@name attribute has been removed from the schema
+ 5.3.3.1: idref/@local and ref/@local do not exist in the schema
+ the Converter describe in the spec in "Type Conversion" paragraph is inconsistent with the javadoc in the spec
+ the Module-Context-Type-Converter manifest header should not contain the from, as it's not part of the Converter interface anymore
+
+ TODO: section 5.3.3.1 shows an example with component/@name which attribute does not exist
+
+ -->
+
+ <!-- Schema elements for core component declarations -->
+
+ <xsd:complexType name="TidentifiedType" abstract="true">
+ <xsd:attribute name="id" type="xsd:ID"/>
+ </xsd:complexType>
+
+ <xsd:element name="components">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element ref="description" minOccurs="0"/>
+ <xsd:element ref="type-converters" minOccurs="0" maxOccurs="1"/>
+ <xsd:choice minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="component"/>
+ <xsd:element ref="ref-list"/>
+ <xsd:element ref="ref-set"/>
+ <xsd:element ref="reference"/>
+ <xsd:element ref="service"/>
+ <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:choice>
+ </xsd:sequence>
+ <xsd:attribute name="default-lazy-init" default="false" type="xsd:boolean"/>
+ <xsd:attribute name="default-init-method" type="xsd:string"/>
+ <xsd:attribute name="default-destroy-method" type="xsd:string"/>
+ <xsd:attributeGroup ref="defaults"/>
+ <xsd:anyAttribute namespace="##other" processContents="lax"/>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="description">
+ <xsd:complexType mixed="true">
+ <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="type-converters">
+ <xsd:complexType mixed="true">
+ <xsd:choice minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="component"/>
+ <xsd:element ref="ref"/>
+ </xsd:choice>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:group name="componentElements">
+ <xsd:sequence>
+ <xsd:element ref="description" minOccurs="0"/>
+ <xsd:choice minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="constructor-arg"/>
+ <xsd:element ref="property"/>
+ <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:choice>
+ </xsd:sequence>
+ </xsd:group>
+
+ <xsd:attributeGroup name="componentAttributes">
+ <xsd:attribute name="class" type="xsd:string"/>
+ <xsd:attribute name="scope" type="xsd:string"/>
+ <xsd:attribute name="lazy-init" default="default" type="Tdefaultable-boolean"/>
+ <xsd:attribute name="depends-on" type="xsd:string"/>
+ <xsd:attribute name="init-method" type="xsd:string"/>
+ <xsd:attribute name="destroy-method" type="xsd:string"/>
+ <xsd:attribute name="factory-method" type="xsd:string"/>
+ <xsd:attribute name="factory-component" type="xsd:string"/>
+ <xsd:anyAttribute namespace="##other" processContents="lax"/>
+ </xsd:attributeGroup>
+
+ <xsd:element name="component">
+ <xsd:complexType>
+ <xsd:complexContent>
+ <xsd:extension base="TidentifiedType">
+ <xsd:group ref="componentElements"/>
+ <xsd:attributeGroup ref="componentAttributes"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:group name="valueElement">
+ <xsd:sequence>
+ <xsd:choice minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="component"/>
+ <xsd:element ref="ref"/>
+ <xsd:element ref="idref"/>
+ <xsd:element ref="value"/>
+ <xsd:element ref="null"/>
+ <xsd:element ref="list"/>
+ <xsd:element ref="set"/>
+ <xsd:element ref="map"/>
+ <xsd:element ref="array"/>
+ <xsd:element ref="props"/>
+ <xsd:element ref="ref-list"/>
+ <xsd:element ref="ref-set"/>
+ <xsd:element ref="reference"/>
+ <xsd:element ref="service"/>
+ <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:choice>
+ </xsd:sequence>
+ </xsd:group>
+
+ <xsd:group name="keyElement">
+ <xsd:sequence>
+ <xsd:choice minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="component"/>
+ <xsd:element ref="ref"/>
+ <xsd:element ref="idref"/>
+ <xsd:element ref="value"/>
+ <xsd:element ref="list"/>
+ <xsd:element ref="set"/>
+ <xsd:element ref="map"/>
+ <xsd:element ref="array"/>
+ <xsd:element ref="props"/>
+ <xsd:element ref="ref-list"/>
+ <xsd:element ref="ref-set"/>
+ <xsd:element ref="reference"/>
+ <xsd:element ref="service"/>
+ <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:choice>
+ </xsd:sequence>
+ </xsd:group>
+
+ <xsd:element name="constructor-arg">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element ref="description" minOccurs="0"/>
+ <xsd:group ref="valueElement"/>
+ </xsd:sequence>
+ <xsd:attribute name="index" type="xsd:string"/>
+ <xsd:attribute name="type" type="xsd:string"/>
+ <xsd:attribute name="ref" type="xsd:string"/>
+ <xsd:attribute name="value" type="xsd:string"/>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="property" type="TpropertyType"/>
+
+ <xsd:element name="ref">
+ <xsd:complexType>
+ <xsd:complexContent>
+ <xsd:restriction base="xsd:anyType">
+ <xsd:attribute name="component" type="xsd:string" use="required"/>
+ </xsd:restriction>
+ </xsd:complexContent>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="idref">
+ <xsd:complexType>
+ <xsd:complexContent>
+ <xsd:restriction base="xsd:anyType">
+ <xsd:attribute name="component" type="xsd:string" use="required"/>
+ </xsd:restriction>
+ </xsd:complexContent>
+ </xsd:complexType>
+ </xsd:element>
+
+
+ <xsd:element name="value">
+ <xsd:complexType mixed="true">
+ <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:attribute name="type" type="xsd:string"/>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="null">
+ <xsd:complexType mixed="true">
+ <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="list" type="TlistSetArrayType"/>
+ <xsd:element name="set" type="TlistSetArrayType"/>
+ <xsd:element name="map" type="TmapType"/>
+ <xsd:element name="array" type="TlistSetArrayType"/>
+ <xsd:element name="entry" type="TentryType"/>
+ <xsd:element name="props" type="TpropsType"/>
+
+ <xsd:element name="key">
+ <xsd:complexType>
+ <xsd:group ref="keyElement"/>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:element name="prop">
+ <xsd:complexType mixed="true">
+ <xsd:attribute name="key" type="xsd:string" use="required"/>
+ <xsd:attribute name="value" type="xsd:string" use="optional"/>
+ </xsd:complexType>
+ </xsd:element>
+
+ <xsd:complexType name="TpropertyType">
+ <xsd:sequence>
+ <xsd:element ref="description" minOccurs="0"/>
+ <xsd:group ref="valueElement"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="required"/>
+ <xsd:attribute name="ref" type="xsd:string"/>
+ <xsd:attribute name="value" type="xsd:string"/>
+ </xsd:complexType>
+
+ <!-- Collection Types -->
+
+ <!-- base collection type -->
+ <xsd:complexType name="TbaseCollectionType"/>
+
+ <!-- base type for collections that have (possibly) typed nested values -->
+ <xsd:complexType name="TtypedCollectionType">
+ <xsd:complexContent>
+ <xsd:extension base="TbaseCollectionType">
+ <xsd:attribute name="value-type" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+
+ <!-- 'map' element type -->
+ <xsd:complexType name="TmapType">
+ <xsd:complexContent>
+ <xsd:extension base="TtypedCollectionType">
+ <xsd:sequence>
+ <xsd:choice minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="entry"/>
+ </xsd:choice>
+ </xsd:sequence>
+ <xsd:attribute name="key-type" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <!-- 'entry' element type -->
+ <xsd:complexType name="TentryType">
+ <xsd:sequence>
+ <xsd:element ref="key" minOccurs="0"/>
+ <xsd:group ref="valueElement"/>
+ </xsd:sequence>
+ <xsd:attribute name="key" type="xsd:string"/>
+ <xsd:attribute name="key-ref" type="xsd:string"/>
+ <xsd:attribute name="value" type="xsd:string"/>
+ <xsd:attribute name="value-ref" type="xsd:string"/>
+ </xsd:complexType>
+
+ <!-- 'list' and 'set' collection type -->
+ <xsd:complexType name="TlistSetArrayType">
+ <xsd:complexContent>
+ <xsd:extension base="TtypedCollectionType">
+ <xsd:group ref="valueElement" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <!-- 'props' collection type -->
+ <xsd:complexType name="TpropsType">
+ <xsd:complexContent>
+ <xsd:extension base="TbaseCollectionType">
+ <xsd:sequence>
+ <xsd:choice minOccurs="0" maxOccurs="unbounded">
+ <xsd:element ref="prop"/>
+ </xsd:choice>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <!-- simple internal types -->
+ <xsd:simpleType name="Tdefaultable-boolean">
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="default"/>
+ <xsd:enumeration value="true"/>
+ <xsd:enumeration value="false"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <!-- Elements from Spring Dynamic Modules project -->
+
+ <xsd:attributeGroup name="defaults">
+ <xsd:attribute name="default-timeout" type="xsd:long" default="30000"/>
+ <xsd:attribute name="default-availability" type="Tavailability" default="mandatory" />
+ </xsd:attributeGroup>
+
+ <xsd:simpleType name="TdefaultCardinalityOptions">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="1..X"/>
+ <xsd:enumeration value="0..X"/>
+ </xsd:restriction>
+
+ </xsd:simpleType>
+
+ <!-- reference -->
+ <xsd:element name="reference" type="TsingleReference"/>
+
+
+ <xsd:complexType name="Treference">
+ <xsd:complexContent>
+ <xsd:extension base="TidentifiedType">
+ <xsd:sequence minOccurs="0" maxOccurs="unbounded">
+ <xsd:element name="interfaces" type="TlistSetArrayType" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="listener" type="Tlistener" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="interface" use="optional" type="xsd:token"/>
+ <xsd:attribute name="filter" use="optional" type="xsd:string"/>
+ <xsd:attribute name="component-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="availability" use="optional" type="Tavailability" default="mandatory"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+
+ <xsd:complexType name="Tlistener">
+ <xsd:choice>
+ <xsd:element ref="ref"/>
+ <xsd:element ref="component"/>
+ <xsd:element ref="reference"/>
+ <xsd:element ref="service"/>
+ <xsd:sequence minOccurs="0" maxOccurs="1">
+ <!-- nested component declaration -->
+ <xsd:any namespace="##other" minOccurs="1" maxOccurs="1" processContents="skip"/>
+ </xsd:sequence>
+ </xsd:choice>
+ <!-- shortcut for bean references -->
+ <xsd:attribute name="ref" type="xsd:string" use="optional"/>
+ <xsd:attribute name="bind-method" type="xsd:token" use="required"/>
+ <xsd:attribute name="unbind-method" type="xsd:token" use="required"/>
+ </xsd:complexType>
+
+ <!-- single reference -->
+ <xsd:complexType name="TsingleReference">
+ <xsd:complexContent>
+ <xsd:extension base="Treference">
+ <xsd:attribute name="timeout" use="optional" type="xsd:long"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="Tavailability">
+ <xsd:restriction base="xsd:token">
+ <xsd:enumeration value="mandatory"/>
+ <xsd:enumeration value="optional"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <!-- reference collections (set, list) -->
+ <xsd:element name="ref-list" type="TreferenceCollection"/>
+
+ <xsd:element name="ref-set" type="TreferenceCollection"/>
+
+
+ <xsd:complexType name="TreferenceCollection">
+ <xsd:complexContent>
+ <xsd:extension base="Treference">
+ <xsd:sequence minOccurs="0" maxOccurs="1">
+ <xsd:element name="comparator" type="Tcomparator"/>
+ </xsd:sequence>
+ <xsd:attribute name="comparator-ref" type="xsd:string" use="optional"/>
+ <xsd:attribute name="member-type" type="TmemberType" use="optional"/>
+ <xsd:attribute name="ordering-basis" type="TorderingBasis" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="TmemberType">
+ <xsd:restriction base="xsd:token">
+ <xsd:enumeration value="service-instance"/>
+ <xsd:enumeration value="service-reference"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:complexType name="Tcomparator">
+ <xsd:choice>
+ <xsd:element ref="ref"/>
+ <xsd:element ref="component"/>
+ <xsd:element ref="reference"/>
+ <xsd:element ref="service"/>
+ <xsd:sequence minOccurs="1" maxOccurs="1">
+ <!-- nested component declaration -->
+ <xsd:any namespace="##other" minOccurs="1" maxOccurs="1" processContents="skip"/>
+ </xsd:sequence>
+ </xsd:choice>
+ </xsd:complexType>
+
+ <xsd:simpleType name="TorderingBasis">
+ <xsd:restriction base="xsd:token">
+ <xsd:enumeration value="service"/>
+ <xsd:enumeration value="service-reference"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+
+ <!-- service -->
+ <xsd:element name="service" type="Tservice"/>
+
+
+ <xsd:complexType name="Tservice">
+ <xsd:complexContent>
+ <xsd:extension base="TidentifiedType">
+ <xsd:choice>
+ <xsd:group ref="serviceElements"/>
+ <!-- nested component declaration -->
+ <xsd:any namespace="##other" minOccurs="0" maxOccurs="1" processContents="skip"/>
+ </xsd:choice>
+ <xsd:attribute name="interface" type="xsd:token" use="optional"/>
+ <xsd:attribute name="ref" type="xsd:string" use="optional"/>
+ <xsd:attribute name="depends-on" type="xsd:string" use="optional"/>
+ <xsd:attribute name="auto-export" type="TautoExportModes" default="disabled"/>
+ <xsd:attribute name="ranking" type="xsd:int" default="0"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:group name="serviceElements">
+ <xsd:sequence>
+ <xsd:element name="interfaces" type="TlistSetArrayType" minOccurs="0"/>
+ <xsd:element name="service-properties" minOccurs="0" type="TmapType"/>
+ <xsd:element name="registration-listener" type="TserviceRegistrationListener" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:group>
+
+ <xsd:complexType name="TserviceRegistrationListener">
+ <xsd:choice>
+ <xsd:element ref="ref"/>
+ <xsd:element ref="component"/>
+ <xsd:element ref="reference"/>
+ <xsd:element ref="service"/>
+ <xsd:sequence minOccurs="0" maxOccurs="1">
+ <!-- nested bean declaration -->
+ <xsd:any namespace="##other" minOccurs="1" maxOccurs="1" processContents="skip"/>
+ </xsd:sequence>
+ </xsd:choice>
+
+ <!-- shortcut for bean references -->
+ <xsd:attribute name="ref" type="xsd:string" use="optional"/>
+ <xsd:attribute name="registration-method" type="xsd:token" use="required"/>
+ <xsd:attribute name="unregistration-method" type="xsd:token" use="required"/>
+ </xsd:complexType>
+
+ <xsd:simpleType name="TautoExportModes">
+ <xsd:restriction base="xsd:token">
+ <xsd:enumeration value="disabled"/>
+ <xsd:enumeration value="interfaces"/>
+ <xsd:enumeration value="class-hierarchy"/>
+ <xsd:enumeration value="all-classes"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+
+</xsd:schema>
\ No newline at end of file