
aQute.bnd.component.annotations.Activate Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of biz.aQute.bndlib Show documentation
Show all versions of biz.aQute.bndlib Show documentation
bndlib: A Swiss Army Knife for OSGi
The newest version!
/*******************************************************************************
* Copyright (c) Contributors to the Eclipse Foundation
*
* Licensed 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.
*
* SPDX-License-Identifier: Apache-2.0
*******************************************************************************/
package aQute.bnd.component.annotations;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* Identify the annotated member as part of the activation of a Service
* Component.
*
* When this annotation is applied to a:
*
* - Method - The method is the {@code activate} method of the Component.
* - Constructor - The constructor will be used to construct the Component and
* can be called with activation objects and bound services as parameters.
* - Field - The field will contain an activation object of the Component. The
* field must be set after the constructor is called and before calling any
* other method on the fully constructed component instance. That is, there is a
* happens-before relationship between the field being set and calling
* any method on the fully constructed component instance such as the
* {@code activate} method.
*
*
* This annotation is not processed at runtime by Service Component Runtime. It
* must be processed by tools and used to add a Component Description to the
* bundle.
*
* @see "The init, activate, and activation-fields attributes of the component element of a Component Description."
* @author $Id: 44eb374708a4e811ce1293546e4479dece5e1b45 $
* @since 1.1
*/
@Retention(RetentionPolicy.CLASS)
@Target({
ElementType.METHOD, ElementType.FIELD, ElementType.CONSTRUCTOR
})
public @interface Activate {
// marker annotation
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy