01: /*
02: * @(#)IIssueState.java
03: *
04: * Copyright (C) 2002-2003 Matt Albrecht
05: * groboclown@users.sourceforge.net
06: * http://groboutils.sourceforge.net
07: *
08: * Part of the GroboUtils package at:
09: * http://groboutils.sourceforge.net
10: *
11: * Permission is hereby granted, free of charge, to any person obtaining a
12: * copy of this software and associated documentation files (the "Software"),
13: * to deal in the Software without restriction, including without limitation
14: * the rights to use, copy, modify, merge, publish, distribute, sublicense,
15: * and/or sell copies of the Software, and to permit persons to whom the
16: * Software is furnished to do so, subject to the following conditions:
17: *
18: * The above copyright notice and this permission notice shall be included in
19: * all copies or substantial portions of the Software.
20: *
21: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22: * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23: * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
24: * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25: * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
26: * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
27: * DEALINGS IN THE SOFTWARE.
28: */
29: package net.sourceforge.groboutils.pmti.v1;
30:
31: /**
32: * Describes the state of an Issue. Issue states may have additional
33: * information associated with them, and as such uses the Attribute methodology
34: * in the same way an Issue does. All implementations of <tt>IIssueState</tt>
35: * must be immutable, unless they are also instances of
36: * <tt>IEditableIssueState</tt>.
37: *
38: * @author Matt Albrecht <a href="mailto:groboclown@users.sourceforge.net">groboclown@users.sourceforge.net</a>
39: * @version $Date: 2003/02/10 22:51:54 $
40: * @since July 7, 2002
41: */
42: public interface IIssueState {
43: /**
44: * Returns the short name of the state.
45: *
46: * @return the short readable name of the state.
47: */
48: public String getName();
49:
50: /**
51: * Retrieves a long, human-readable, description of the state.
52: *
53: * @return the state's description.
54: */
55: public String getDescription();
56:
57: /**
58: * A broad category for the state - it means that the issue has not been
59: * resolved yet, and the code is still open for changes based on this
60: * issue.
61: * <P>
62: * <tt>isOpen()</tt> must always return the opposite of
63: * <tt>isClosed()</tt>; that is, the following code:
64: * <PRE>
65: * isOpen() == !isClosed()
66: * </PRE>
67: * <i>must always</i> evaluate to <tt>true</tt>.
68: */
69: public boolean isOpen();
70:
71: /**
72: * A broad category for the state - it means that the issue has been
73: * resolved, and the code is no longer open for changes based on this
74: * issue.
75: * <P>
76: * <tt>isClosed()</tt> must always return the opposite of
77: * <tt>isOpen()</tt>; that is, the following code:
78: * <PRE>
79: * isOpen() == !isClosed()
80: * </PRE>
81: * <i>must always</i> evaluate to <tt>true</tt>.
82: */
83: public boolean isClosed();
84:
85: /**
86: * Returns a list of all attributes associated with this state. All
87: * states of a particular type should have the same set of issues. If
88: * the problem tracker does not have attributes associated with an issue
89: * state, then this must still return a non-<tt>null</tt>, but the set
90: * will be empty.
91: *
92: * @return the set of tracker-specific and issue type-specific attributes
93: * and values associated with this issue. Can never return
94: * <tt>null</tt>.
95: */
96: public IAttributeSet getAttributes();
97: }
|