1 10 11 package org.mule.extras.acegi; 12 13 import java.util.Map ; 14 15 import org.acegisecurity.Authentication; 16 import org.acegisecurity.GrantedAuthority; 17 import org.mule.umo.security.UMOAuthentication; 18 19 22 public class AcegiAuthenticationAdapter implements UMOAuthentication 23 { 24 private Authentication delegate; 25 private Map properties; 26 27 public AcegiAuthenticationAdapter(Authentication authentication) 28 { 29 this.delegate = authentication; 30 } 31 32 public AcegiAuthenticationAdapter(Authentication authentication, Map properties) 33 { 34 this.delegate = authentication; 35 this.properties = properties; 36 } 37 38 public void setAuthenticated(boolean b) 39 { 40 delegate.setAuthenticated(b); 41 } 42 43 public boolean isAuthenticated() 44 { 45 return delegate.isAuthenticated(); 46 } 47 48 public GrantedAuthority[] getAuthorities() 49 { 50 return delegate.getAuthorities(); 51 } 52 53 public Object getCredentials() 54 { 55 return delegate.getCredentials(); 56 } 57 58 public Object getDetails() 59 { 60 return delegate.getDetails(); 61 } 62 63 public Object getPrincipal() 64 { 65 return delegate.getPrincipal(); 66 } 67 68 public int hashCode() 69 { 70 return delegate.hashCode(); 71 } 72 73 public boolean equals(Object another) 74 { 75 return delegate.equals(another); 76 } 77 78 public String getName() 79 { 80 return delegate.getName(); 81 } 82 83 public Authentication getDelegate() 84 { 85 return delegate; 86 } 87 88 public Map getProperties() 89 { 90 return properties; 91 } 92 93 public void setProperties(Map properties) 94 { 95 this.properties = properties; 96 } 97 } 98 | Popular Tags |