001 /* 002 Copyright (C) 2003 Renaud Pawlak 003 004 This program is free software; you can redistribute it and/or modify 005 it under the terms of the GNU Lesser General Public License as 006 published by the Free Software Foundation; either version 2 of the 007 License, or (at your option) any later version. 008 009 This program is distributed in the hope that it will be useful, 010 but WITHOUT ANY WARRANTY; without even the implied warranty of 011 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 012 GNU Lesser General Public License for more details. 013 014 You should have received a copy of the GNU Lesser General Public License 015 along with this program; if not, write to the Free Software 016 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ 017 018 package org.objectweb.jac.aspects.session; 019 020 /** 021 * This is the configuration interface of the session aspect. 022 * 023 * @see SessionAC 024 * 025 * @author Renaud Pawlak */ 026 027 public interface SessionConf { 028 029 /** 030 * This configuration method tells which methods of which objects 031 * must handdle the sessions (wrapped by the session wrapper). 032 * 033 * @param classExpr a class pointcut expression 034 * @param methodExpr a method pointcut expression 035 * @param objectExpr an object pointcut expression 036 * 037 * @see org.objectweb.jac.aspects.session.SessionWrapper */ 038 039 void defineSessionHandlers(String classExpr, String methodExpr, String objectExpr); 040 041 /** 042 * This configuration method defines per-session objects. 043 * 044 * <p>A per-session object is an object that have a different state 045 * depending on the session. Each user will see a different state 046 * for the same object. 047 * 048 * <p>Warning: this feature is not compatible with persistent 049 * objects! 050 * 051 * @param classExpr a class pointcut expression 052 * @param objectExpr an object pointcut expression 053 * 054 * @see org.objectweb.jac.aspects.session.SessionWrapper */ 055 056 void definePerSessionObjects(String classExpr, String objectExpr); 057 058 /** 059 * Add some attributes to the list of attributes of the context to 060 * be saved and restored by the session aspect. 061 * @param attributes names of attributes 062 */ 063 void declareStoredAttributes(String attributes[]); 064 065 }