Commit f1184d57 by Michael Koch Committed by Michael Koch

AbstractAction.java: Reformated.

2004-01-23  Michael Koch  <konqueror@gmx.de>

	* javax/swing/AbstractAction.java: Reformated.

From-SVN: r76424
parent f0bf056e
2004-01-23 Michael Koch <konqueror@gmx.de>
* javax/swing/AbstractAction.java: Reformated.
2004-01-23 Michael Koch <konqueror@gmx.de>
* java/text/CollationElementIterator.java:
(setText): New method.
......
......@@ -75,99 +75,124 @@ public abstract class AbstractAction
/**
* Constructor AbstractAction
*/
public AbstractAction() {
public AbstractAction()
{
this(""); // TODO: default name
} // AbstractAction()
}
/**
* Constructor AbstractAction
*
* @param name TODO
*/
public AbstractAction(String name) {
public AbstractAction(String name)
{
this(name, null); // TODO: default icon??
} // AbstractAction()
}
/**
* Constructor AbstractAction
*
* @param name TODO
* @param icon TODO
*/
public AbstractAction(String name, Icon icon) {
public AbstractAction(String name, Icon icon)
{
putValue(NAME, name);
putValue(SMALL_ICON, icon);
} // AbstractAction()
}
/**
* readObject
* @param stream TODO
*
* @param stream the stream to read from
*
* @exception ClassNotFoundException TODO
* @exception IOException TODO
* @exception IOException if an error occurs
*/
private void readObject(ObjectInputStream stream)
throws ClassNotFoundException, IOException {
throws ClassNotFoundException, IOException
{
// TODO
} // readObject()
}
/**
* writeObject
* @param stream TODO
* @exception IOException TODO
*
* @param stream the stream to write to
*
* @exception IOException if an error occurs
*/
private void writeObject(ObjectOutputStream stream) throws IOException {
private void writeObject(ObjectOutputStream stream) throws IOException
{
// TODO
} // writeObject()
}
/**
* clone
*
* @return Object
*
* @exception CloneNotSupportedException TODO
* @returns Object
*/
protected Object clone() throws CloneNotSupportedException {
// What to do??
return null;
} // clone()
protected Object clone() throws CloneNotSupportedException
{
AbstractAction copy = (AbstractAction) super.clone();
copy.store = (HashMap) store.clone();
return copy;
}
/**
* getValue
* @param key TODO
* @returns Object
* Returns a value for a given key from the built-in store.
*
* @param key the key to get the value for
*
* @return Object
*/
public Object getValue(String key) {
public Object getValue(String key)
{
return store.get(key);
} // getValue()
}
/**
* putValue
* @param key TODO
* @param value TODO
* Puts a key/value pair into the built-in store.
*
* @param key the key
* @param value the value
*/
public void putValue(String key, Object value) {
public void putValue(String key, Object value)
{
store.put(key, value);
} // putValue()
}
/**
* isEnabled
* @returns boolean
*
* @return boolean
*/
public boolean isEnabled() {
public boolean isEnabled()
{
return enabled;
} // isEnabled()
}
/**
* setEnabled
*
* @param enabled TODO
*/
public void setEnabled(boolean enabled) {
public void setEnabled(boolean enabled)
{
this.enabled = enabled;
} // setEnabled()
}
/**
* getKeys
* @returns Object[]
*/
public Object[] getKeys() {
public Object[] getKeys()
{
return store.keySet().toArray();
} // getKeys()
}
/**
* firePropertyChange
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment