1/*2* Licensed to the Apache Software Foundation (ASF) under one or more3* contributor license agreements. See the NOTICE file distributed with4* this work for additional information regarding copyright ownership.5* The ASF licenses this file to You under the Apache License, Version 2.06* (the "License"); you may not use this file except in compliance with7* the License. You may obtain a copy of the License at8* 9* http://www.apache.org/licenses/LICENSE-2.010* 11* Unless required by applicable law or agreed to in writing, software12* distributed under the License is distributed on an "AS IS" BASIS,13* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.14* See the License for the specific language governing permissions and15* limitations under the License.16*/1718packageorg.apache.jetspeed.sso.impl;
1920import java.io.Serializable;
2122import org.apache.jetspeed.sso.SSOContext;
2324/***25* SSOContextImpl26* Class holding credential information 27*28* @author <a href="mailto:rogerrut@apache.org">Roger Ruttimann</a>29* @version $Id: SSOContextImpl.java 516448 2007-03-09 16:25:47Z ate $30*/31publicclassSSOContextImpl implements SSOContext, Serializable
32 {
33privatelong remotePrincipalId;
34private String remoteCredential;
35private String remotePrincipal;
36private String portalPrincipal;
3738/***39 * Constructor takes all arguments since members can't be altered40 */41publicSSOContextImpl(long remotePrincipalId, String remotePrincipal, String remoteCredential)
42 {
43super();
44this.remotePrincipalId = remotePrincipalId;
45this.remotePrincipal = remotePrincipal;
46this.remoteCredential = remoteCredential;
47 }
4849publicSSOContextImpl(long remotePrincipalId, String remotePrincipal, String remoteCredential, String portalPrincipal)
50 {
51super();
52this.remotePrincipalId = remotePrincipalId;
53this.remotePrincipal = remotePrincipal;
54this.remoteCredential = remoteCredential;
55this.portalPrincipal = portalPrincipal;
56 }
5758/* (non-Javadoc)59 * @see org.apache.jetspeed.sso.SSOContext#getRemotePrincipalId()60 */61publiclong getRemotePrincipalId()
62 {
63returnthis.remotePrincipalId;
64 }
6566/* (non-Javadoc)67 * @see org.apache.jetspeed.sso.SSOContext#getRemotePrincipal()68 */69public String getRemotePrincipalName()
70 {
71returnthis.remotePrincipal;
72 }
7374/* (non-Javadoc)75 * @see org.apache.jetspeed.sso.SSOContext#getRemoteCredential()76 */77public String getRemoteCredential()
78 {
79returnthis.remoteCredential;
80 }
8182/* (non-Javadoc)83 * @see org.apache.jetspeed.sso.SSOContext#getPortalPrincipal()84 */85public String getPortalPrincipalName()
86 {
87returnthis.portalPrincipal;
88 }
8990 }