6.1.1.4.1.2. thyrsis.meshlayer.meshdataprovider module

class thyrsis.meshlayer.meshdataprovider.MeshDataProvider(uri='', providerOptions=<qgis._core.QgsDataProvider.ProviderOptions object>, flags=None)

Bases : qgis._core.QgsDataProvider

base class for mesh data providers, please note that this class is called in a multithreaded context

PROVIDER_KEY = 'mesh_provider'
classmethod createProvider(uri, providerOptions)
crs()

Return crs attribute

Renvoie

crs

Type renvoyé

QgsCoordinateReferenceSystem

dataChanged
dataSourceUri(expandAuthConfig=False)

Return data provider uri

Renvoie

uri

Type renvoyé

string

date()

return a current date

Renvoie

dates list

Type renvoyé

list

dates()

return a list of dates in case node values vary with time

Renvoie

dates list

Type renvoyé

list

classmethod description()

Returns the mesh provider description

elementValues()

return values at elements

Renvoie

values at nodes

Type renvoyé

ndarray

isValid()

Return true if data provider is valid

Renvoie

valid

Type renvoyé

bool

name()

Return data provider name attribute

Renvoie

name

Type renvoyé

string

nodeCoord()

return a list of coordinates

Renvoie

return a list of coordinates

Type renvoyé

ndarray

nodeValues()

return values at nodes

Renvoie

values at nodes

Type renvoyé

ndarray

classmethod providerKey()

Returns the mesh provider key

readXml(node, rwcontext)

Function to read mesh legend information from project

Paramètres
  • node (QDomElement) – base element of the xml

  • rwcontext (QgsReadWriteContext) – QgsReadWriteContext

setCrs(coordRef)

Set Qgs

setDate(didx)

Set current date index

Paramètres

didx (integer) – date index

setDates(dates)

set list of dates in case node values vary with time

Paramètres

dates (list) – dates list

triangles()

return a list of triangles described by node indices, watch out: indices start at zero

Renvoie

return a list of coordinates

Type renvoyé

ndarray

uri()

Return data provider name attribute

Renvoie

uri

Type renvoyé

QgsDataSourceUri

valueAtElement()

return if mesh is elements based (True) or nodes based (False)

Renvoie

flag

Type renvoyé

bool

writeXml(node, doc, rwcontext)

Function to write mesh legend information from project

Paramètres
  • node (QDomElement) – base element of the xml

  • doc (QDomDocument) – document

  • rwcontext (QgsReadWriteContext) – QgsReadWriteContext

xmlLoaded