001/* 002 * (C) Copyright 2006-2008 Nuxeo SAS (http://nuxeo.com/) and contributors. 003 * 004 * All rights reserved. This program and the accompanying materials 005 * are made available under the terms of the GNU Lesser General Public License 006 * (LGPL) version 2.1 which accompanies this distribution, and is available at 007 * http://www.gnu.org/licenses/lgpl.html 008 * 009 * This library is distributed in the hope that it will be useful, 010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 012 * Lesser General Public License for more details. 013 * 014 * Contributors: 015 * troger 016 * 017 * $Id$ 018 */ 019 020package org.nuxeo.ecm.platform.annotations.configuration.service; 021 022import org.nuxeo.common.xmap.annotation.XNode; 023import org.nuxeo.common.xmap.annotation.XNodeList; 024import org.nuxeo.common.xmap.annotation.XObject; 025 026/** 027 * @author <a href="mailto:troger@nuxeo.com">Thomas Roger</a> 028 */ 029@XObject("webAnnotation") 030public class WebAnnotationDefinitionDescriptor { 031 032 @XNode("@uri") 033 private String uri; 034 035 @XNode("@name") 036 private String name; 037 038 @XNode("@icon") 039 private String icon; 040 041 @XNode("@type") 042 private String type; 043 044 @XNode("@enabled") 045 private Boolean enabled = true; 046 047 @XNode("@listIcon") 048 private String listIcon; 049 050 @XNode("@createIcon") 051 private String createIcon; 052 053 @XNode("@inMenu") 054 private Boolean inMenu = false; 055 056 @XNodeList(value = "field", type = WebAnnotationFieldDescriptor[].class, componentType = WebAnnotationFieldDescriptor.class) 057 private WebAnnotationFieldDescriptor[] fields = new WebAnnotationFieldDescriptor[0]; 058 059 public String getUri() { 060 return uri; 061 } 062 063 /** 064 * @return the label. 065 */ 066 public String getName() { 067 return name; 068 } 069 070 public String getIcon() { 071 return icon; 072 } 073 074 public String getType() { 075 return type; 076 } 077 078 public Boolean isEnabled() { 079 return enabled; 080 } 081 082 public String getListIcon() { 083 return listIcon; 084 } 085 086 public String getCreateIcon() { 087 return createIcon; 088 } 089 090 public Boolean isInMenu() { 091 return inMenu; 092 } 093 094 public WebAnnotationFieldDescriptor[] getFields() { 095 return fields; 096 } 097 098}