1 package org.apache.turbine.util; 2 3 18 19 import java.io.IOException ; 20 import java.io.PrintWriter ; 21 import java.util.Locale ; 22 import java.util.Map ; 23 import javax.servlet.ServletConfig ; 24 import javax.servlet.ServletContext ; 25 import javax.servlet.http.HttpServletRequest ; 26 import javax.servlet.http.HttpServletResponse ; 27 import javax.servlet.http.HttpSession ; 28 29 import org.apache.ecs.Document; 30 import org.apache.ecs.Element; 31 import org.apache.ecs.StringElement; 32 33 import org.apache.turbine.om.security.User; 34 import org.apache.turbine.util.parser.CookieParser; 35 import org.apache.turbine.util.parser.ParameterParser; 36 import org.apache.turbine.util.security.AccessControlList; 37 import org.apache.turbine.util.template.TemplateInfo; 38 39 53 public interface RunData 54 { 55 60 ParameterParser getParameters(); 61 62 67 CookieParser getCookies(); 68 69 74 HttpServletRequest getRequest(); 75 76 81 HttpServletResponse getResponse(); 82 83 88 HttpSession getSession(); 89 90 95 ServletConfig getServletConfig(); 96 97 102 ServletContext getServletContext(); 103 104 109 AccessControlList getACL(); 110 111 116 void setACL(AccessControlList acl); 117 118 124 boolean isPageSet(); 125 126 132 Document getPage(); 133 134 139 boolean hasAction(); 140 141 148 String getAction(); 149 150 155 void setAction(String action); 156 157 169 String getLayout(); 170 171 176 void setLayout(String layout); 177 178 184 String getLayoutTemplate(); 185 186 195 void setLayoutTemplate(String layout); 196 197 202 boolean hasScreen(); 203 204 209 String getScreen(); 210 211 216 void setScreen(String screen); 217 218 224 String getScreenTemplate(); 225 226 234 void setScreenTemplate(String screen); 235 236 241 String getTemplateEncoding(); 242 243 248 void setTemplateEncoding(String encoding); 249 250 255 TemplateInfo getTemplateInfo(); 256 257 262 boolean hasMessage(); 263 264 270 String getMessage(); 271 272 277 void setMessage(String msg); 278 279 285 void addMessage(String msg); 286 287 293 StringElement getMessageAsHTML(); 294 295 300 void setMessage(Element msg); 301 302 308 void addMessage(Element msg); 309 310 313 void unsetMessage(); 314 315 321 FormMessages getMessages(); 322 323 328 void setMessages(FormMessages msgs); 329 330 335 String getTitle(); 336 337 342 void setTitle(String title); 343 344 349 boolean userExists(); 350 351 356 User getUser(); 357 358 363 void setUser(User user); 364 365 371 User getUserFromSession(); 372 373 378 boolean removeUserFromSession(); 379 380 386 boolean isOutSet(); 387 388 396 PrintWriter getOut() 397 throws IOException ; 398 399 405 void declareDirectResponse(); 406 407 416 Locale getLocale(); 417 418 423 void setLocale(Locale locale); 424 425 434 String getCharSet(); 435 436 441 void setCharSet(String charset); 442 443 454 String getContentType(); 455 456 461 void setContentType(String ct); 462 463 469 String getRedirectURI(); 470 471 477 void setRedirectURI(String ruri); 478 479 484 int getStatusCode(); 485 486 491 void setStatusCode(int sc); 492 493 498 SystemError[] getSystemErrors(); 499 500 505 void setSystemError(SystemError err); 506 507 512 Map getJNDIContexts(); 513 514 519 void setJNDIContexts(Map contexts); 520 521 526 String getServerScheme(); 527 528 533 String getServerName(); 534 535 540 int getServerPort(); 541 542 547 String getContextPath(); 548 549 554 String getScriptName(); 555 556 561 ServerData getServerData(); 562 563 568 String getRemoteAddr(); 569 570 575 String getRemoteHost(); 576 577 582 String getUserAgent(); 583 584 588 void populate(); 589 590 593 void save(); 594 595 600 String getStackTrace(); 601 602 607 Throwable getStackTraceException(); 608 609 615 void setStackTrace(String trace, 616 Throwable exp); 617 618 624 Map getVarDebug(); 625 626 634 void setDebugVariable(String name, Object value); 635 636 641 Map getDebugVariables(); 642 } 643 | Popular Tags |