KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jface > viewers > ICellEditorValidator


1 /*******************************************************************************
2  * Copyright (c) 2000, 2006 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.jface.viewers;
12
13 /**
14  * An interface for validating a cell editor's input.
15  * <p>
16  * This interface should be implemented by classes that wish to
17  * act as cell editor validators.
18  * </p>
19  */

20 public interface ICellEditorValidator {
21     /**
22      * Returns a string indicating whether the given value is valid;
23      * <code>null</code> means valid, and non-<code>null</code> means
24      * invalid, with the result being the error message to display
25      * to the end user.
26      * <p>
27      * It is the responsibility of the implementor to fully format the
28      * message before returning it.
29      * </p>
30      *
31      * @param value the value to be validated
32      * @return the error message, or <code>null</code> indicating
33      * that the value is valid
34      */

35     public String JavaDoc isValid(Object JavaDoc value);
36 }
37
Popular Tags