## OobsService

OobsService — Object that represents an individual init.d service

## Synopsis

    enum                OobsServiceStatus;
                        OobsService;
    void                oobs_service_set_runlevel_configuration
                                                            (OobsService *service,
                                                             OobsServicesRunlevel *runlevel,
                                                             OobsServiceStatus status,
                                                             gint priority);
    void                oobs_service_get_runlevel_configuration
                                                            (OobsService *service,
                                                             OobsServicesRunlevel *runlevel,
                                                             OobsServiceStatus *status,
                                                             gint *priority);
    const gchar*        oobs_service_get_name               (OobsService *service);

## Object Hierarchy

      GObject
       +----OobsObject
             +----OobsService

## Properties

      "name"                     gchar*                : Read / Write / Construct Only

## Description

## Details

### enum OobsServiceStatus

    typedef enum
    {
      OOBS_SERVICE_START,
      OOBS_SERVICE_STOP,
      /* For services not listed in that runlevel */
      OOBS_SERVICE_IGNORE
    } OobsServiceStatus;

### OobsService

    typedef struct _OobsService OobsService;

### oobs_service_set_runlevel_configuration ()

    void                oobs_service_set_runlevel_configuration
                                                            (OobsService *service,
                                                             OobsServicesRunlevel *runlevel,
                                                             OobsServiceStatus status,
                                                             gint priority);

Sets the configuration of a service for a given runlevel.

`service` : | An OobsService.
`runlevel` : | A OobsServicesRunlevel.
`status` : | status for the service in the given runlevel
`priority` : | priority for the service in the given runlevel. Use 0 to either keep the previous priority, or get the default value in case the script is new.

### oobs_service_get_runlevel_configuration ()

    void                oobs_service_get_runlevel_configuration
                                                            (OobsService *service,
                                                             OobsServicesRunlevel *runlevel,
                                                             OobsServiceStatus *status,
                                                             gint *priority);

Gets the status and priority of a service in a given runlevel.

`service` : | An OobsService.
`runlevel` : | An OobsServiceRunlevel.
`status` : | return value for the current service status.
`priority` : | return value for the current service priority.

### oobs_service_get_name ()

    const gchar*        oobs_service_get_name               (OobsService *service);

Returns the service name

`service` : | An OobsService.
Returns : | A pointer to the service name as a string. This string must not be freed, modified or stored.

## Property Details

### The `"name"` property

      "name"                     gchar*                : Read / Write / Construct Only

Name of the service.

Default value: NULL

## See Also

OobsServicesConfig