medisyn
Class FileCategory

java.lang.Object
  extended by medisyn.FileCategory
All Implemented Interfaces:
java.lang.Cloneable

public class FileCategory
extends java.lang.Object
implements java.lang.Cloneable

Represents a semantic file category e.g. sport, entertainment, ...

Author:
Leo Bosnjak

Field Summary
private  java.awt.Color color
           
private  int id
           
private  java.lang.String name
           
 
Constructor Summary
FileCategory()
          constructs an empty FileCategory
FileCategory(int id, java.lang.String name)
          constructs an existing FileCategory
FileCategory(int id, java.lang.String name, java.awt.Color color)
          constructs an existing FileCategory
 
Method Summary
protected  FileCategory clone()
          clones the object
 boolean equals(java.lang.Object o)
          does Object o have the same value like me?
 java.awt.Color getColor()
           
 int getId()
           
 java.lang.String getName()
           
 void setColor(java.awt.Color color)
           
 void setId(int id)
           
 void setName(java.lang.String name)
           
 java.lang.String toString()
          return String representation of object
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

id

private int id

name

private java.lang.String name

color

private java.awt.Color color
Constructor Detail

FileCategory

public FileCategory()
constructs an empty FileCategory


FileCategory

public FileCategory(int id,
                    java.lang.String name)
constructs an existing FileCategory


FileCategory

public FileCategory(int id,
                    java.lang.String name,
                    java.awt.Color color)
constructs an existing FileCategory

Method Detail

getId

public int getId()
Returns:
the id

setId

public void setId(int id)
Parameters:
id - the id to set

getName

public java.lang.String getName()
Returns:
the name

setName

public void setName(java.lang.String name)
Parameters:
name - the name to set

clone

protected FileCategory clone()
                      throws java.lang.CloneNotSupportedException
clones the object

Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException

equals

public boolean equals(java.lang.Object o)
does Object o have the same value like me?

Overrides:
equals in class java.lang.Object

toString

public java.lang.String toString()
return String representation of object

Overrides:
toString in class java.lang.Object

getColor

public java.awt.Color getColor()
Returns:
the color

setColor

public void setColor(java.awt.Color color)
Parameters:
color - the color to set