Module tvbrowser
Package devplugin

Interface Program

  • All Known Implementing Classes:
    MutableProgram

    public interface Program
    This interface provides a view of the program object in the host-application.
    Author:
    Martin Oberhauser
    • Method Detail

      • getHighlightingPriorityMaximum

        static int getHighlightingPriorityMaximum()
        Returns:
        The current maximum highlighting priority NOTE: This might change in both directions.
        Since:
        4.2.2
      • getID

        java.lang.String getID()
        Gets the ID of this program. This ID is unique for a certain date. This value becomes invalid when changing the application time zone.
        Returns:
        The ID of this program.
      • getUniqueID

        java.lang.String getUniqueID()
        Gets the unique ID of this program. In contrast to getID() this method returns an ID, which is unique for all programs. This value becomes invalid when changing the application time zone.
        Returns:
        An unique ID of this program.
      • getTitle

        java.lang.String getTitle()
      • getShortInfo

        java.lang.String getShortInfo()
      • getDescription

        java.lang.String getDescription()
        Gets the description of the program
        Returns:
        the description or null, if no description is available
      • getStartTime

        int getStartTime()
        Gets the the start time of the program in minutes after midnight.
        Returns:
        the start time.
      • getHours

        int getHours()
        Gets the hour-component of the start time of the program. This is local time (i.e. for the current time zone). This value becomes invalid when changing the time zone!
        Returns:
        the hour-component of the start time.
      • getMinutes

        int getMinutes()
        Gets the minute-component of the start time of the program. This is local time (i.e. for the current time zone). This value becomes invalid when changing the time zone!
        Returns:
        the minute-component of the start time.
      • getLength

        int getLength()
        Gets the length of this program in minutes.
        Returns:
        the length in minutes or -1, if the length is unknown.
      • getInfo

        int getInfo()
      • getTimeString

        java.lang.String getTimeString()
        get the start time of this program as nicely formatted string
        Returns:
        the start time string
      • getDateString

        java.lang.String getDateString()
        get the date of this program as nicely formatted string
        Returns:
        the date string
      • getEndTimeString

        java.lang.String getEndTimeString()
        get the end time of this program as nicely formatted string
        Returns:
        the end time string
        Since:
        2.5.3
      • getDate

        Date getDate()
        get the date when the program starts.
        Returns:
        the date
      • getBinaryField

        byte[] getBinaryField​(ProgramFieldType type)
        Gets the value of a binary field from the program.
        Parameters:
        type - The type of the wanted field. Must have a binary format.
        Returns:
        The value of the field or null, if there is no value for this field.
      • getTextField

        java.lang.String getTextField​(ProgramFieldType type)
        Gets the value of a text field from the program.
        Parameters:
        type - The type of the wanted field. Must have a text format.
        Returns:
        The value of the field or null, if there is no value for this field.
      • getIntField

        int getIntField​(ProgramFieldType type)
        Gets the value of a int field from the program.
        Parameters:
        type - The type of the wanted field. Must have a int format.
        Returns:
        The value of the field or -1, if there is no value for this field.
      • getIntFieldAsString

        java.lang.String getIntFieldAsString​(ProgramFieldType type)
        Gets the value of a int field as String.
        Parameters:
        type - The type of the wanted field. Must have a int format.
        Returns:
        The value of the field as String or null, if there is no value for this field.
      • getTimeField

        int getTimeField​(ProgramFieldType type)
        Gets the value of a time field from the program.
        Parameters:
        type - The type of the wanted field. Must have a time format.
        Returns:
        The value of the field or -1, if there is no value for this field.
      • getTimeFieldAsString

        java.lang.String getTimeFieldAsString​(ProgramFieldType type)
        Gets the value of a time field as String of the pattern "h:mm".
        Parameters:
        type - The type of the wanted field. Must have a time format.
        Returns:
        The value of the field as String or null, if there is no value for this field.
      • getFieldCount

        int getFieldCount()
        Gets the number of fields this program has.
        Returns:
        the number of fields this program has.
      • getFieldIterator

        java.util.Iterator<ProgramFieldType> getFieldIterator()
        Gets an iterator over the types of all fields this program has.
        Returns:
        an iterator over ProgramFieldTypes.
      • mark

        void mark​(Plugin javaPlugin)
        Marks the program for a Java plugin.
        Parameters:
        javaPlugin - The plugin to mark the program for.
      • unmark

        void unmark​(Plugin javaPlugin)
        Removes the marks from the program for a Java plugin.

        If the program wasn't marked for the plugin, nothing happens.

        Parameters:
        javaPlugin - The plugin to remove the mark for.
      • mark

        void mark​(Marker plugin)
        Marks the program for a plugin.
        Parameters:
        plugin - The plugin to mark the program for.
      • unmark

        void unmark​(Marker plugin)
        Removes the marks from the program for a plugin.

        If the program wasn't marked for the plugin, nothing happens.

        Parameters:
        plugin - The plugin to remove the mark for.
      • isOnAir

        boolean isOnAir()
        Gets whether this program is marked as "on air".
        Returns:
        true if this program if currently on air, false if not.
      • getMarkerArr

        Marker[] getMarkerArr()
        Gets all Markers that have marked this program.
        Returns:
        An array with all Marker that have marked this program.
      • isExpired

        boolean isExpired()
        Gets whether this program is expired.
        Returns:
        true if this program is expired, false if not.
      • getProgramState

        int getProgramState()
        Returns the state of this program.
        Returns:
        The program state.
        Since:
        2.2
      • validateMarking

        void validateMarking()
        Informs the ChangeListeners for repainting if a Plugin uses more than one Icon for the Program.
        Since:
        2.5
        See Also:
        Plugin.getMarkIconsForProgram(Program)
      • getMarkPriority

        @Deprecated(since="4.2.2")
        int getMarkPriority()
        Deprecated.
        since 4.2.2
        Gets the priority of the marking of this program.
        Returns:
        The mark priority.
        Since:
        2.5.1
      • getMarkPriorityMax

        int getMarkPriorityMax()
        Gets the maximum priority of the marking of this program.
        Returns:
        The maximum mark priority.
        Since:
        4.2.2
      • getMarkPriorities

        java.lang.Integer[] getMarkPriorities()
        Gets an array of all marking priorities of this program.
        Returns:
        An array with all marking priorities of this program.
        Since:
        4.2.2
      • hasFieldValue

        boolean hasFieldValue​(ProgramFieldType type)
        checks if the given field has a non-null value. use this method if you don't need the value of the field, but only the knowledge about existence
        Parameters:
        type - field type
        Returns:
        field is set
        Since:
        3.0