001/* 002 * (C) Copyright 2006-2007 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 * <a href="mailto:at@nuxeo.com">Anahide Tchertchian</a> 016 * 017 * $Id: ValueBindingDescriptor.java 21462 2007-06-26 21:16:36Z sfermigier $ 018 */ 019 020package org.nuxeo.ecm.platform.ui.web.rest.descriptors; 021 022import org.nuxeo.common.xmap.annotation.XNode; 023import org.nuxeo.common.xmap.annotation.XObject; 024 025/** 026 * Descriptor for a value binding. 027 * 028 * @author <a href="mailto:at@nuxeo.com">Anahide Tchertchian</a> 029 */ 030@XObject("binding") 031public class ValueBindingDescriptor { 032 033 @XNode("@name") 034 protected String name; 035 036 @XNode("") 037 protected String expression; 038 039 /** 040 * If set to false, the binding will not be called to get the value (and use it to preserve it in the redirect URL 041 * after a POST) 042 * 043 * @since 5.4.2 044 */ 045 @XNode("@callGetter") 046 protected boolean callGetter = true; 047 048 /** 049 * If set to false, the binding will not be called to set the value 050 * 051 * @since 5.4.2 052 */ 053 @XNode("@callSetter") 054 protected boolean callSetter = true; 055 056 public String getExpression() { 057 return expression; 058 } 059 060 public String getName() { 061 return name; 062 } 063 064 public boolean getCallGetter() { 065 return callGetter; 066 } 067 068 public boolean getCallSetter() { 069 return callSetter; 070 } 071 072}