oracle.ide.log
Interface LogRecognizer

public interface LogRecognizer

The LogRecognizer is used when attempting to create a log
page by opening a file in the LogWindow. After the user selects
a file in the URLChooser the LogManager cycles through
all registered LogRecognizers to find one that recognizes
the file and can create itself from the file.

recognize(java.net.URL url)
Gets the Class of the data item associated with the
specified URL.

Method Detail

recognize

java.lang.Class recognize(java.net.URL url)

Gets the Class of the data item associated with the
specified URL. Implementations must return
null if the URL is not recognized. The
Class returned must be the data model class. This
value is passed to the create(URL, Class) method
which will create the LogPage

Parameters:

url - unique URL identifying the document.

Returns:

the data Class.

create

Creates an instance of the LogPage associated with the
specified URL. This method is called by the
LogManager. This method must return a LogPage
instance. The type parameter specifies the
Class of the data object.

Parameters:

url - unique URL identifying the document.

type - the data Class.

Returns:

log page

Throws:

java.lang.IllegalAccessException

java.lang.InstantiationException

getFilter

Gets the URLFilter for the LogRecognizer.
The URLFilter is used to limit what file types can be opened
in the LogWindow so the user won't try to open file types that
there is no chance of a LogPage displaying.