## ide-source-location

ide-source-location

## Functions

IdeSourceLocation * | ide_source_location_ref ()
void | ide_source_location_unref ()
IdeSourceLocation * | ide_source_location_new ()
guint | ide_source_location_get_line ()
guint | ide_source_location_get_line_offset ()
guint | ide_source_location_get_offset ()
IdeFile * | ide_source_location_get_file ()
IdeUri * | ide_source_location_get_uri ()

## Description

## Functions

### ide_source_location_ref ()

    IdeSourceLocation *
    ide_source_location_ref (IdeSourceLocation *self);

Increments the reference count of `self` by one.

#### Returns

self.

[transfer full]

### ide_source_location_unref ()

    void
    ide_source_location_unref (IdeSourceLocation *self);

Decrements the reference count of `self` by one. If the reference count reaches zero, then the structure is freed.

### ide_source_location_new ()

    IdeSourceLocation *
    ide_source_location_new (IdeFile *file,
                             guint line,
                             guint line_offset,
                             guint offset);

Creates a new IdeSourceLocation, using the file, line, column, and character offset provided.

#### Parameters

file | an IdeFile |
line | the line number starting from zero |
line_offset | the character offset within the line |
offset | the character offset in the file |

#### Returns

A newly allocated IdeSourceLocation.

[transfer full]

### ide_source_location_get_line ()

    guint
    ide_source_location_get_line (IdeSourceLocation *self);

Retrieves the target line number starting from 0.

#### Returns

A guint containing the target line.

### ide_source_location_get_line_offset ()

    guint
    ide_source_location_get_line_offset (IdeSourceLocation *self);

Retrieves the character offset within the line.

#### Returns

A guint containing the offset within the line.

### ide_source_location_get_offset ()

    guint
    ide_source_location_get_offset (IdeSourceLocation *self);

Retrieves the character offset within the file.

#### Returns

A guint containing the character offset within the file.

### ide_source_location_get_file ()

    IdeFile *
    ide_source_location_get_file (IdeSourceLocation *self);

The file represented by this source location.

#### Returns

An IdeFile.

[transfer none]

### ide_source_location_get_uri ()

    IdeUri *
    ide_source_location_get_uri (IdeSourceLocation *self);

#### Parameters

self | A IdeSourceLocation. | [in]

#### Returns

A newly allocated IdeUri.

[transfer full]

## Types and Values