Annotation of java/classes/org/w3c/jigsaw/acl/HTTPPrincipal.java, revision 1.4
1.1 bmahe 1: // HTTPPrincipal.java
1.4 ! bmahe 2: // $Id: HTTPPrincipal.java,v 1.3 1999/04/27 12:33:26 bmahe Exp $
1.1 bmahe 3: // (c) COPYRIGHT MIT, INRIA and Keio, 1999.
4: // Please first read the full copyright statement in file COPYRIGHT.html
5:
6: package org.w3c.jigsaw.acl;
7:
8: import java.net.InetAddress;
9: import java.security.Principal;
10:
11: import org.w3c.jigsaw.http.Request;
12:
13: /**
1.4 ! bmahe 14: * @version $Revision: 1.3 $
1.1 bmahe 15: * @author Benoît Mahé (bmahe@w3.org)
16: */
1.4 ! bmahe 17: public class HTTPPrincipal implements Principal {
1.1 bmahe 18:
19: protected InetAddress inetaddress = null;
20:
21: protected InetAddress getInetAddress() {
22: return inetaddress;
23: }
24:
1.4 ! bmahe 25: public boolean equals(Object another) {
! 26: return false;
! 27: }
! 28:
! 29: public String getName() {
! 30: return "httpprincipal";
! 31: }
! 32:
1.3 bmahe 33: public String toString() {
34: return inetaddress.toString();
35: }
1.1 bmahe 36:
1.4 ! bmahe 37: public HTTPPrincipal(Request request) {
1.3 bmahe 38: this.inetaddress = request.getClient().getInetAddress();
1.1 bmahe 39: }
40:
41: }
Webmaster