001 /* 002 * Licensed to the Apache Software Foundation (ASF) under one or more contributor license 003 * agreements. See the NOTICE file distributed with this work for additional information regarding 004 * copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the 005 * "License"); you may not use this file except in compliance with the License. You may obtain a 006 * copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable 007 * law or agreed to in writing, software distributed under the License is distributed on an "AS IS" 008 * BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License 009 * for the specific language governing permissions and limitations under the License. 010 */ 011 012 package javax.portlet.faces.annotation; 013 014 import java.lang.annotation.Documented; 015 import java.lang.annotation.ElementType; 016 import java.lang.annotation.Retention; 017 import java.lang.annotation.RetentionPolicy; 018 import java.lang.annotation.Target; 019 020 /** The BridgeRequestScopeAttributeAdded annotation is used on methods as a callback 021 * notification to signal that the instance is in the process of being added 022 * to the container's request scope and that this attribute will be managed 023 * in the bridge request scope. This signal can be used by the instance to flag 024 * that its <code>javax.annotation.PreDestroy</code> method should not perform any cleanup 025 * and instead rely on the method annotated with 026 * <code>javax.portlet.faces.annotation.PreDestroy</code> to do so. The method on 027 * which the PreDestroy annotation is applied MUST 028 * fulfill all of the following criteria - The method MUST NOT have any parameters - 029 * The return type of the method MUST be void. - The method MUST NOT throw a checked 030 * exception. - The method on which PreDestroy is applied MUST be public. - The 031 * method MUST NOT be static. - The method MAY be final. - If the method throws an 032 * unchecked exception it is ignored. 033 */ 034 035 @Documented 036 @Retention(RetentionPolicy.RUNTIME) 037 @Target({ElementType.METHOD}) 038 public @interface BridgeRequestScopeAttributeAdded { 039 } 040