1 31 32 package org.opencms.editors.fckeditor; 33 34 import javax.servlet.http.HttpSession ; 35 36 47 public class CmsFCKEditorConfiguration { 48 49 50 public static final String SESSION_ATTRIBUTE = "__fckeditorconfig"; 51 52 53 private String m_resourcePath; 54 55 56 private String m_uriStyleSheet; 57 58 61 public CmsFCKEditorConfiguration() { 62 63 } 65 66 74 public static CmsFCKEditorConfiguration getConfiguration(HttpSession session) { 75 76 Object o = session.getAttribute(SESSION_ATTRIBUTE); 77 if (o != null && o instanceof CmsFCKEditorConfiguration) { 78 session.removeAttribute(SESSION_ATTRIBUTE); 79 return (CmsFCKEditorConfiguration)o; 80 } 81 return new CmsFCKEditorConfiguration(); 82 } 83 84 89 public String getResourcePath() { 90 91 return m_resourcePath; 92 } 93 94 99 public String getUriStyleSheet() { 100 101 return m_uriStyleSheet; 102 } 103 104 109 public void setConfiguration(HttpSession session) { 110 111 session.setAttribute(SESSION_ATTRIBUTE, this); 112 } 113 114 119 public void setResourcePath(String resourcePath) { 120 121 m_resourcePath = resourcePath; 122 } 123 124 129 public void setUriStyleSheet(String uriStyleSheet) { 130 131 m_uriStyleSheet = uriStyleSheet; 132 } 133 134 } | Popular Tags |