TrackerMinerOnline: Tracker Miner Library Reference Manual

## TrackerMinerOnline TrackerMinerOnline — Abstract base class for miners connecting to online resources |

## Functions

TrackerNetworkType | tracker_miner_online_get_network_type ()

## Types and Values

struct | TrackerMinerOnline
struct | TrackerMinerOnlineClass

## Includes

    #include <libtracker-miner/tracker-miner.h>

## Description

TrackerMinerOnline is an abstract base class for miners retrieving data from online resources. It's a very thin layer above TrackerMiner that additionally handles network connection status.

TrackerMinerOnline implementations can implement the `connected` vmethod in order to tell the miner whether a connection is valid to retrieve data or not. The miner data extraction still must be dictated through the TrackerMiner vmethods.

## Functions

### tracker_miner_online_get_network_type ()

    TrackerNetworkType
    tracker_miner_online_get_network_type (TrackerMinerOnline *miner);

Get the type of network this data `miner` uses to index content.

#### Parameters

miner | a TrackerMinerOnline. |

#### Returns

a TrackerNetworkType on success or TRACKER_NETWORK_TYPE_NONE on error.

Since: 0.18.

## Types and Values

### struct TrackerMinerOnline

    struct TrackerMinerOnline {
    	TrackerMiner parent_instance;
    };

Abstract miner object for data requiring connectivity.

### struct TrackerMinerOnlineClass

    struct TrackerMinerOnlineClass {
    	TrackerMinerClass parent_class;

    	/* vmethods */
    	gboolean (* connected)    (TrackerMinerOnline *miner,
    	                           TrackerNetworkType  network);
    	void     (* disconnected) (TrackerMinerOnline *miner);

    	/* <Private> */
    	gpointer padding[10];
    };

Virtual methods that can be overridden.

#### Members

`connected` () | called when there is a network connection, or a new default route, returning TRUE starts/resumes indexing. |
`disconnected` () | called when there is no network connection. |
gpointer `padding`[10]; | Reserved for future API improvements. |

Since: 0.18.