1 5 package com.opensymphony.webwork.views.jsp; 6 7 import com.mockobjects.servlet.MockHttpSession; 8 9 import java.util.Enumeration ; 10 import java.util.Hashtable ; 11 12 13 19 public class WebWorkMockHttpSession extends MockHttpSession { 20 22 Hashtable attributes = new Hashtable (); 23 24 26 public void setAttribute(String s, Object o) { 27 attributes.put(s, o); 28 } 29 30 public Object getAttribute(String s) { 31 return attributes.get(s); 32 } 33 34 public Enumeration getAttributeNames() { 35 return attributes.keys(); 36 } 37 38 public void setExpectedAttribute(String s, Object o) { 39 throw new UnsupportedOperationException (); 40 } 41 42 public void setExpectedRemoveAttribute(String s) { 43 throw new UnsupportedOperationException (); 44 } 45 46 public void removeAttribute(String s) { 47 attributes.remove(s); 48 } 49 50 public void setupGetAttribute(String s, Object o) { 51 throw new UnsupportedOperationException (); 52 } 53 54 public void setupGetAttributeNames(Enumeration enumeration) { 55 throw new UnsupportedOperationException (); 56 } 57 } 58 | Popular Tags |