PyANGKernel.GKContents

class GKContents

A set of GKContents .

Details

Implemented as a map so that retrieve a GKContent by GKContent::Type is easy ; some convenient features from QSet are implemented.

Synopsis

Methods

Static functions

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

__init__()

Builds empty GKContents .

__init__(content)
Parameters:

contentGKContent

Builds a GKContents containing the specified content.

__getitem__()
__len__()
__setitem__()
bucket_count()
Return type:

int

capacity()
Return type:

int

clear()
contains(content)
Parameters:

contentGKContent

Return type:

bool

contains(other)
Parameters:

otherGKContents

Return type:

bool

contains(key)
Parameters:

key – str

Return type:

bool

count()
Return type:

int

count(key)
Parameters:

key – str

Return type:

int

description([ignoredTypes=QSet<GKContent.Type>()[, separator=" - "]])
Parameters:
  • ignoredTypes – .QSetQString

  • separator – str

Return type:

str

Gives a UI description of the GKContents . * UnknownCommand ignoredTypes contains a set of GKContent::Type that won’t be included in the description * (for example, if you don’t want the originator to appear). * UnknownCommand separator Separator between types.

empty()
Return type:

bool

static fromString(str)
Parameters:

str – str

Return type:

GKContents

Builds a GKContents from an identifying QString of the same format as used in toString .

insert(hash)
Parameters:

hash – Dictionary with keys of type .QString and values of type GKContent.

intersect(other)
Parameters:

otherGKContents

Return type:

GKContents

Removes any GKContent that is not also contained in ‘other’, and returns a reference to ‘this’.

isEmpty()
Return type:

bool

isSharedWith(other)
Parameters:

other – Dictionary with keys of type .QString and values of type GKContent.

Return type:

bool

key(value)
Parameters:

valueGKContent

Return type:

str

key(value, defaultKey)
Parameters:
Return type:

str

keys()
Return type:

.list of QString

keys(value)
Parameters:

valueGKContent

Return type:

.list of QString

load_factor()
Return type:

float

static max_bucket_count()
Return type:

int

static max_load_factor()
Return type:

float

__add__(other)
Parameters:

otherGKContent

Return type:

GKContents

Returns the union with the other GKContent . If there are two GKContent of same type, the one from ‘other’ is used.

__add__(other)
Parameters:

otherGKContents

Return type:

GKContents

Returns the union with the other GKContents . If there are two GKContent of same type, the one from ‘other’ is used.

__lshift__(value)
Parameters:

valueGKContent

Return type:

GKContents

Adds the specified GKContent . If a GKContent of same type already exists, replaces it.

__lshift__(other)
Parameters:

otherGKContents

Return type:

GKContents

Adds the specified GKContents . If a GKContent of same type already exists, replaces it.

operator(key)
Parameters:

key – str

Return type:

GKContent

remove(key)
Parameters:

key – str

Return type:

bool

reserve(size)
Parameters:

size – int

size()
Return type:

int

squeeze()
subtract(other)
Parameters:

otherGKContents

Return type:

GKContents

Removes any GKContent that is also contained in ‘other’, and returns a reference to ‘this’.

swap(other)
Parameters:

other – Dictionary with keys of type .QString and values of type GKContent.

take(key)
Parameters:

key – str

Return type:

GKContent

toString()
Return type:

str

Builds a unique identifying QString.

trimmed()
Return type:

GKContents

Returns a copy of the GKContents without any empty GKContent .

unite(other)
Parameters:

otherGKContents

value(arg__1)
Parameters:

arg__1 – str

Return type:

GKContent

values()
Return type:

.list of GKContent