public class SMARTParser extends ShellParser
Constructor and Description |
---|
SMARTParser()
Constructs a SMARTParser and reads the list of disk
devices to query
|
Modifier and Type | Method and Description |
---|---|
String |
getInfo()
Return a String with information about this class
|
EventRecord[] |
monitor()
Invokes query() to do the parsing and handles parsing errors for
each one of the disks specified in the configuration.
|
EventRecord |
query(String device)
Reads and parses the output of smartctl for a specified disk and
creates an appropriate EventRecord that holds the desirable
information for it.
|
findAll, findPattern, monitor
public SMARTParser()
public EventRecord query(String device) throws Exception
query
in class ShellParser
device
- the disk device name to queryException
public EventRecord[] monitor()
monitor
in interface Monitored
monitor
in class ShellParser
public String getInfo()
Copyright © 2010 The Apache Software Foundation