org.jmythapi.protocol.response
Interface IStorageGroupFile

All Superinterfaces:
Cloneable, IPropertyAware<IStorageGroupFile.Props>, IVersionable
All Known Implementing Classes:
StorageGroupFile

public interface IStorageGroupFile
extends IVersionable, IPropertyAware<IStorageGroupFile.Props>

An interface to get the files of a MythTV storage group.

This interface represents the response of a IBackend.queryStorageGroupFile(String, String, String) request.
This interface is property-aware. See the properties-list for all properties of this interface.

A response example:

A recording file:
<0>FILE_TYPE: file | <1>FILE_PATH: /var/lib/mythtv/recordings/11123_20110321200900.mpg | <2>LAST_MOD: Mon Mar 21 22:39:28 CET 2011 | <3>FILE_SIZE: 3815729968
A preview image:
<0>FILE_TYPE: file | <1>FILE_PATH: /var/lib/mythtv/recordings/1063_20110329201000.mpg.png | <2>LAST_MOD: Sun Apr 10 09:46:32 CEST 2011 | <3>FILE_SIZE: 86681
The reponse to a fileNameOnly query:
<0>FILE_TYPE: file | <1>FILE_PATH: 1063_20110329203500.mpg | <2>LAST_MOD: null | <3>FILE_SIZE: null
A storage-group directory:
<0>FILE_TYPE: sgdir | <1>FILE_PATH: /var/lib/mythtv/recordings | <2>LAST_MOD: null | <3>FILE_SIZE: null

See Also:
IBackend.queryStorageGroupFile(java.lang.String, java.lang.String, java.lang.String), QUERY_SG_FILEQUERY

Nested Class Summary
static class IStorageGroupFile.Props
          The properties of an IStorageGroupFile response.
 
Method Summary
 String getFilePath()
          Gets the full path to the file
 Long getFileSize()
          Gets the file size
 String getFileType()
          Gets the type of the file.
 Date getLastModified()
          Gets the last modified date of the file
 boolean isDirectory()
          Checks if the current entry is a directory.
 
Methods inherited from interface org.jmythapi.IVersionable
getVersionNr
 
Methods inherited from interface org.jmythapi.IPropertyAware
getProperties, getProperty, getPropertyClass, getPropertyCount, getPropertyIndex, getPropertyMap, getPropertyValue, getPropertyValue, getPropertyValueObject, getPropertyValues, setPropertyValue, setPropertyValue, setPropertyValueObject
 

Method Detail

isDirectory

boolean isDirectory()
Checks if the current entry is a directory.

Returns:
true if the entry is a directory.

getFileType

String getFileType()
Gets the type of the file.

Returns:
file if the entry is a file.
See Also:
IStorageGroupFile.Props.FILE_TYPE

getFilePath

String getFilePath()
Gets the full path to the file

Returns:
the full file path
See Also:
IStorageGroupFile.Props.FILE_PATH

getLastModified

Date getLastModified()
Gets the last modified date of the file

Returns:
the files last-mod date
See Also:
IStorageGroupFile.Props.LAST_MOD

getFileSize

Long getFileSize()
Gets the file size

Returns:
the file size.
See Also:
IStorageGroupFile.Props.FILE_SIZE


Copyright © 2008-2013. All Rights Reserved.