Foundry.VcsDiffHunk

g Foundry.VcsDiffHunk Foundry.VcsDiffHunk GObject.Object GObject.Object GObject.Object->Foundry.VcsDiffHunk

Subclasses:

Foundry.GitDiffHunk

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

dup_header ()

get_new_lines ()

get_new_start ()

get_old_lines ()

get_old_start ()

list_lines ()

Virtual Methods

Inherited:

GObject.Object (7)

do_dup_header ()

do_get_new_lines ()

do_get_new_start ()

do_get_old_lines ()

do_get_old_start ()

do_list_lines ()

Properties

Name

Type

Flags

Short Description

header

str

r

new-lines

int

r

new-start

int

r

old-lines

int

r

old-start

int

r

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent_instance

GObject.Object

r

Class Details

class Foundry.VcsDiffHunk(**kwargs)
Bases:

GObject.Object

Abstract:

Yes

Structure:

Foundry.VcsDiffHunkClass

dup_header()
Return type:

str or None

The header for the hunk which is the part after the second “@@”.

New in version 1.1.

get_new_lines()
Returns:

the number of lines in the new file

Return type:

int

Gets the number of lines in the new file for this hunk.

New in version 1.1.

get_new_start()
Returns:

the starting line number in the new file

Return type:

int

Gets the starting line number in the new file for this hunk.

New in version 1.1.

get_old_lines()
Returns:

the number of lines in the old file

Return type:

int

Gets the number of lines in the old file for this hunk.

New in version 1.1.

get_old_start()
Returns:

the starting line number in the old file

Return type:

int

Gets the starting line number in the old file for this hunk.

New in version 1.1.

list_lines()
Returns:

a [class`Dex`.Future] that resolves to an [iface`Gio`.ListModel] of [class`Foundry`.VcsDiffLine].

Return type:

Dex.Future

List the lines within a hunk.

do_dup_header() virtual
Return type:

str or None

The header for the hunk which is the part after the second “@@”.

New in version 1.1.

do_get_new_lines() virtual
Returns:

the number of lines in the new file

Return type:

int

Gets the number of lines in the new file for this hunk.

New in version 1.1.

do_get_new_start() virtual
Returns:

the starting line number in the new file

Return type:

int

Gets the starting line number in the new file for this hunk.

New in version 1.1.

do_get_old_lines() virtual
Returns:

the number of lines in the old file

Return type:

int

Gets the number of lines in the old file for this hunk.

New in version 1.1.

do_get_old_start() virtual
Returns:

the starting line number in the old file

Return type:

int

Gets the starting line number in the old file for this hunk.

New in version 1.1.

do_list_lines() virtual
Returns:

a [class`Dex`.Future] that resolves to an [iface`Gio`.ListModel] of [class`Foundry`.VcsDiffLine].

Return type:

Dex.Future

List the lines within a hunk.

Property Details

Foundry.VcsDiffHunk.props.header
Name:

header

Type:

str

Default Value:

None

Flags:

READABLE

Foundry.VcsDiffHunk.props.new_lines
Name:

new-lines

Type:

int

Default Value:

0

Flags:

READABLE

Foundry.VcsDiffHunk.props.new_start
Name:

new-start

Type:

int

Default Value:

0

Flags:

READABLE

Foundry.VcsDiffHunk.props.old_lines
Name:

old-lines

Type:

int

Default Value:

0

Flags:

READABLE

Foundry.VcsDiffHunk.props.old_start
Name:

old-start

Type:

int

Default Value:

0

Flags:

READABLE