comparison org.eclipse.jface/src/org/eclipse/jface/dialogs/IMessageProvider.d @ 12:bc29606a740c

Added dwt-addons in original directory structure of eclipse.org
author Frank Benoit <benoit@tionex.de>
date Sat, 14 Mar 2009 18:23:29 +0100
parents
children
comparison
equal deleted inserted replaced
11:43904fec5dca 12:bc29606a740c
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 * Port to the D programming language:
11 * Frank Benoit <benoit@tionex.de>
12 *******************************************************************************/
13 module org.eclipse.jface.dialogs.IMessageProvider;
14
15 import java.lang.all;
16
17 /**
18 * Minimal interface to a message provider. Used for dialog pages which can
19 * provide a message with an icon.
20 *
21 * @since 2.0
22 */
23 public interface IMessageProvider {
24 /**
25 * Constant for a regular message (value 0).
26 * <p>
27 * Typically this indicates that the message should be shown without an
28 * icon.
29 * </p>
30 */
31 public const static int NONE = 0;
32
33 /**
34 * Constant for an info message (value 1).
35 */
36 public const static int INFORMATION = 1;
37
38 /**
39 * Constant for a warning message (value 2).
40 */
41 public const static int WARNING = 2;
42
43 /**
44 * Constant for an error message (value 3).
45 */
46 public const static int ERROR = 3;
47
48 /**
49 * Returns the current message for this message provider.
50 * <p>
51 * A message provides instruction or information to the user.
52 * </p>
53 *
54 * @return the message, or <code>null</code> if none
55 */
56 public String getMessage();
57
58 /**
59 * Returns a value indicating if the message is a an information message, a
60 * warning message, or an error message.
61 * <p>
62 * Returns one of <code>NONE</code>,<code>INFORMATION</code>,
63 * <code>WARNING</code>, or <code>ERROR</code>.
64 * </p>
65 *
66 * @return the message type
67 */
68 public int getMessageType();
69 }