001/* 002 * This library is part of OpenCms - 003 * the Open Source Content Management System 004 * 005 * Copyright (c) Alkacon Software GmbH & Co. KG (http://www.alkacon.com) 006 * 007 * This library is free software; you can redistribute it and/or 008 * modify it under the terms of the GNU Lesser General Public 009 * License as published by the Free Software Foundation; either 010 * version 2.1 of the License, or (at your option) any later version. 011 * 012 * This library is distributed in the hope that it will be useful, 013 * but WITHOUT ANY WARRANTY; without even the implied warranty of 014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 015 * Lesser General Public License for more details. 016 * 017 * For further information about Alkacon Software, please see the 018 * company website: http://www.alkacon.com 019 * 020 * For further information about OpenCms, please see the 021 * project website: http://www.opencms.org 022 * 023 * You should have received a copy of the GNU Lesser General Public 024 * License along with this library; if not, write to the Free Software 025 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 026 */ 027 028package org.opencms.ade.galleries.shared; 029 030import org.opencms.gwt.shared.CmsIconBean; 031import org.opencms.util.CmsUUID; 032 033import java.util.Date; 034import java.util.LinkedHashMap; 035import java.util.Map; 036 037/** 038 * This bean contains the preview content for the selected item.<p> 039 * 040 * @since 8.0.0 041 */ 042public class CmsResourceInfoBean extends CmsIconBean { 043 044 /** The description of the resource. */ 045 private String m_description; 046 047 /** The last modification date. */ 048 private Date m_lastModified; 049 050 /** The no edit reason. If empty editing is allowed. */ 051 private String m_noEditReason; 052 053 /** The HTML content generated by the preview formatter. */ 054 private String m_previewContent; 055 056 /** The main properties. */ 057 private Map<String, String> m_properties; 058 059 /** The path to the selected resource. */ 060 private String m_resourcePath; 061 062 /** The resource type name. */ 063 private String m_resourceType; 064 065 /** The file size. */ 066 private String m_size; 067 068 /** The structure id of the resource. */ 069 private CmsUUID m_structureId; 070 071 /** The title of the resource. */ 072 private String m_title; 073 074 /** 075 * The constructor.<p> 076 */ 077 public CmsResourceInfoBean() { 078 079 m_properties = new LinkedHashMap<String, String>(); 080 } 081 082 /** 083 * Returns the description of the resource.<p> 084 * 085 * @return the description 086 */ 087 public String getDescription() { 088 089 return m_description; 090 } 091 092 /** 093 * Returns the last modification date.<p> 094 * 095 * @return the last modification date 096 */ 097 public Date getLastModified() { 098 099 return m_lastModified; 100 } 101 102 /** 103 * Returns the no edit reason. If empty editing is allowed.<p> 104 * 105 * @return the no edit reason 106 */ 107 public String getNoEditReason() { 108 109 return m_noEditReason; 110 } 111 112 /** 113 * Returns the preview content.<p> 114 * 115 * @return the preview content 116 */ 117 public String getPreviewContent() { 118 119 return m_previewContent; 120 } 121 122 /** 123 * Returns the properties.<p> 124 * 125 * @return the properties 126 */ 127 public Map<String, String> getProperties() { 128 129 return m_properties; 130 } 131 132 /** 133 * Returns the resource path.<p> 134 * 135 * @return the resource path 136 */ 137 public String getResourcePath() { 138 139 return m_resourcePath; 140 } 141 142 /** 143 * Returns the resource type name.<p> 144 * 145 * @return the resource type name 146 */ 147 public String getResourceType() { 148 149 return m_resourceType; 150 } 151 152 /** 153 * Returns the file size.<p> 154 * 155 * @return the file size 156 */ 157 public String getSize() { 158 159 return m_size; 160 } 161 162 /** 163 * Gets the structure id of the resource.<p> 164 * @return the structure id of the resource 165 */ 166 public CmsUUID getStructureId() { 167 168 return m_structureId; 169 } 170 171 /** 172 * Returns the title of the resource.<p> 173 * 174 * @return the title 175 */ 176 public String getTitle() { 177 178 return m_title; 179 } 180 181 /** 182 * Sets the description of the resource.<p> 183 * 184 * @param description the description to set 185 */ 186 public void setDescription(String description) { 187 188 m_description = description; 189 } 190 191 /** 192 * Sets the last modification date.<p> 193 * 194 * @param lastModified the last modification date to set 195 */ 196 public void setLastModified(Date lastModified) { 197 198 m_lastModified = lastModified; 199 } 200 201 /** 202 * Sets the no edit reason.<p> 203 * 204 * @param noEditReason the no edit reason to set 205 */ 206 public void setNoEditReason(String noEditReason) { 207 208 m_noEditReason = noEditReason; 209 } 210 211 /** 212 * Sets the preview content.<p> 213 * 214 * @param previewContent the preview content to set 215 */ 216 public void setPreviewContent(String previewContent) { 217 218 m_previewContent = previewContent; 219 } 220 221 /** 222 * Sets the propeties.<p> 223 * 224 * @param propeties the propeties to set 225 */ 226 public void setProperties(Map<String, String> propeties) { 227 228 m_properties = propeties; 229 } 230 231 /** 232 * Sets the resource path.<p> 233 * 234 * @param resourcePath the resource path to set 235 */ 236 public void setResourcePath(String resourcePath) { 237 238 m_resourcePath = resourcePath; 239 } 240 241 /** 242 * Sets the resource type name.<p> 243 * 244 * @param resourceType the resource type name to set 245 */ 246 public void setResourceType(String resourceType) { 247 248 m_resourceType = resourceType; 249 } 250 251 /** 252 * Sets the file size.<p> 253 * 254 * @param size the file size to set 255 */ 256 public void setSize(String size) { 257 258 m_size = size; 259 } 260 261 /** 262 * Sets the resource structure id.<p> 263 * 264 * @param structureId the resource structure id 265 */ 266 public void setStructureId(CmsUUID structureId) { 267 268 m_structureId = structureId; 269 } 270 271 /** 272 * Sets the title of the resource.<p> 273 * 274 * @param title the title to set 275 */ 276 public void setTitle(String title) { 277 278 m_title = title; 279 } 280}