org.jtheque.core.utils.db
Class DaoNotes

java.lang.Object
  extended by org.jtheque.core.utils.db.DaoNotes

public final class DaoNotes
extends Object

A data access object for the notes.

Author:
Baptiste Wicht

Nested Class Summary
static class DaoNotes.NoteType
          A properties class for notes.
 
Method Summary
 Note getDefaultNote()
          Return the default note.
static Image getImage(Note note)
          Return the image for the specified note.
static DaoNotes getInstance()
          Return the unique instance of the class.
 Note getNote(DaoNotes.NoteType value)
          Return the note with the specific value.
 Note[] getNotes()
          Return all the notes of the dao.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static DaoNotes getInstance()
Return the unique instance of the class.

Returns:
The singleton of DaoNotes.

getNotes

public Note[] getNotes()
Return all the notes of the dao.

Returns:
An array containing all the notes.

getNote

public Note getNote(DaoNotes.NoteType value)
Return the note with the specific value.

Parameters:
value - The value of the note we want
Returns:
The note with this value or null if we doesn't it.

getImage

public static Image getImage(Note note)
Return the image for the specified note. The image is still buffered.

Parameters:
note - The note to get the image for.
Returns:
The image for the note.

getDefaultNote

public Note getDefaultNote()
Return the default note.

Returns:
The default note.


Copyright © 2010 JTheque. All Rights Reserved.