package jp.agentec.sinaburocast.vo; import java.io.Serializable; import jp.agentec.sinaburocast.common.SinaburoConstant.UserType; import jp.agentec.sinaburocast.common.ToStringBuilderEx; import jp.agentec.sinaburocast.entity.AdminUser; import jp.agentec.sinaburocast.entity.Member; import org.seasar.framework.container.annotation.tiger.Component; import org.seasar.framework.container.annotation.tiger.InstanceType; /** * 認証結果を保存するオブジェクト * * @author tsukada * */ @Component(instance = InstanceType.SESSION) public class AuthenticatedTokenVO implements Serializable { private static final long serialVersionUID = 7867608341579498533L; /** ユーザーの数値ID */ public Integer userId; /** ユーザーの文字列ID (ログイン時のユーザー名) */ public String loginId; /** ユーザーの登録名(画面表示用) */ public String userName; /** ユーザータイプ */ public Integer userType = UserType.ANONYMOUS; /** userType に応じた XxxAuthLevelVO のID */ public Integer authLevel; public String ipAddress; /*memberテーブルのデータ*/ public Member member; /*adminUserテーブルのデータ*/ public AdminUser adminUser; @Override public String toString() { return new ToStringBuilderEx(this) .append("userId", userId) .append("loginId", loginId) .append("userName", userName) .append("userType", userType) .append("auth_level", authLevel) .append("ipAddress", ipAddress) .toString(); } }