Lizmap Web Client Master

qgisProject
in package

Table of Contents

Properties

$allProj4  : array<string|int, mixed>
$cachedProperties  : array<string|int, mixed>
$canvasColor  : string
$data  : array<string|int, mixed>
$layers  : array<string|int, array<string|int, mixed>>
$path  : string
$qgisProjectVersion  : int
Version of QGIS which wrote the project.
$relations  : array<string|int, mixed>
$themes  : array<string|int, mixed>
$useLayerIDs  : bool
$WMSInformation  : array<string|int, mixed>
$xml  : SimpleXMLElement

Methods

__construct()  : mixed
constructor.
clearCache()  : mixed
Clear the project cache.
findLayersByKeyword()  : array<string|int, qgisMapLayer>|array<string|int, qgisVectorLayer>
getAllProj4()  : array<string|int, mixed>
Get All Proj4 definition from QGIS Project.
getCanvasColor()  : string
Get QGIS project Canvas color.
getData()  : null|mixed
getLayer()  : null|qgisMapLayer|qgisVectorLayer
getLayerByKeyword()  : null|qgisMapLayer|qgisVectorLayer
getLayerDefinition()  : null|array<string|int, mixed>
getPath()  : string
Get QGIS project path.
getProj4()  : null|string
Get Proj4 definition from QGIS Project.
getQgisProjectVersion()  : int
Get version of QGIS which wrote the project.
getRelations()  : array<string|int, mixed>
Get relations information.
getThemes()  : array<string|int, mixed>
Get list of themes.
getWMSInformation()  : array<string|int, mixed>
Get WMS info.
getXmlLayer()  : array<string|int, SimpleXMLElement>
getXmlLayerByKeyword()  : array<string|int, SimpleXMLElement>
getXmlLayers()  : array<string|int, SimpleXMLElement>
getXmlRelation()  : array<string|int, SimpleXMLElement>
getXml()  : SimpleXMLElement
temporary function to read xml for some methods that relies on xml data that are not yet stored in the cache.
readAllProj4()  : array<string|int, mixed>
readCanvasColor()  : string
readLayers()  : array<string|int, array<string|int, mixed>>
readRelations()  : null|array<string|int, array<string|int, mixed>>
readThemes()  : null|array<string|int, array<string|int, mixed>>
readUseLayerIDs()  : bool
readWMSInformation()  : array<string|int, mixed>
readXmlProject()  : mixed
Read the qgis files.

Properties

$allProj4

protected array<string|int, mixed> $allProj4 = array()

authid => proj4

$cachedProperties

protected array<string|int, mixed> $cachedProperties = array('WMSInformation', 'canvasColor', 'allProj4', 'relations', 'themes', 'useLayerIDs', 'layers', 'data', 'qgisProjectVersion')

List of cached properties

$layers

protected array<string|int, array<string|int, mixed>> $layers = array()

list of layers. Each item is a list of layer properties

$qgisProjectVersion

Version of QGIS which wrote the project.

protected int $qgisProjectVersion

$relations

protected array<string|int, mixed> $relations = array()

for each referenced layer, there is an item with referencingLayer, referencedField, referencingField keys. There is also a 'pivot' key

$WMSInformation

protected array<string|int, mixed> $WMSInformation

contains WMS info

Methods

__construct()

constructor.

public __construct(string $file) : mixed
Parameters
$file : string

: the QGIS project path

getAllProj4()

Get All Proj4 definition from QGIS Project.

public getAllProj4() : array<string|int, mixed>
Return values
array<string|int, mixed>

getCanvasColor()

Get QGIS project Canvas color.

public getCanvasColor() : string
Return values
string

getData()

public getData(string $key) : null|mixed
Parameters
$key : string
Return values
null|mixed

getLayerDefinition()

public getLayerDefinition(string $layerId) : null|array<string|int, mixed>
Parameters
$layerId : string
Return values
null|array<string|int, mixed>

getPath()

Get QGIS project path.

public getPath() : string
Return values
string

getProj4()

Get Proj4 definition from QGIS Project.

public getProj4(mixed $authId) : null|string
Parameters
$authId : mixed
Return values
null|string

getQgisProjectVersion()

Get version of QGIS which wrote the project.

public getQgisProjectVersion() : int
Return values
int

getRelations()

Get relations information.

public getRelations() : array<string|int, mixed>

For each referenced layer, there is an item with referencingLayer, referencedField, referencingField keys. There is also a 'pivot' key.

Return values
array<string|int, mixed>

getThemes()

Get list of themes.

public getThemes() : array<string|int, mixed>
Return values
array<string|int, mixed>

getWMSInformation()

Get WMS info.

public getWMSInformation() : array<string|int, mixed>
Return values
array<string|int, mixed>

getXmlLayer()

public getXmlLayer(mixed $layerId) : array<string|int, SimpleXMLElement>
Parameters
$layerId : mixed
Tags
FIXME:

remove this method. Be sure it is not used in other projects. Data provided by the returned xml element should be extracted and encapsulated into an object. Xml should not be used by callers

Return values
array<string|int, SimpleXMLElement>

getXmlLayerByKeyword()

public getXmlLayerByKeyword(mixed $key) : array<string|int, SimpleXMLElement>
Parameters
$key : mixed
Tags
FIXME:

remove this method. Be sure it is not used in other projects Data provided by the returned xml element should be extracted and encapsulated into an object. Xml should not be used by callers

Return values
array<string|int, SimpleXMLElement>

getXmlLayers()

public getXmlLayers() : array<string|int, SimpleXMLElement>
Tags
FIXME:

remove this method. Be sure it is not used in other projects. Data provided by the returned xml element should be extracted and encapsulated into an object. Xml should not be used by callers

Return values
array<string|int, SimpleXMLElement>

getXmlRelation()

public getXmlRelation(mixed $relationId) : array<string|int, SimpleXMLElement>
Parameters
$relationId : mixed
Tags
FIXME:

remove this method. Be sure it is not used in other projects. Data provided by the returned xml element should be extracted and encapsulated into an object. Xml should not be used by callers

Return values
array<string|int, SimpleXMLElement>

getXml()

temporary function to read xml for some methods that relies on xml data that are not yet stored in the cache.

protected getXml() : SimpleXMLElement
Return values
SimpleXMLElement

readAllProj4()

protected readAllProj4(SimpleXMLElement $xml) : array<string|int, mixed>
Parameters
$xml : SimpleXMLElement
Return values
array<string|int, mixed>

readCanvasColor()

protected readCanvasColor(SimpleXMLElement $xml) : string
Parameters
$xml : SimpleXMLElement
Return values
string

readLayers()

protected readLayers(SimpleXMLElement $xml) : array<string|int, array<string|int, mixed>>
Parameters
$xml : SimpleXMLElement
Tags
throws
Exception
Return values
array<string|int, array<string|int, mixed>>

list of layers. Each item is a list of layer properties

readRelations()

protected readRelations(SimpleXMLElement $xml) : null|array<string|int, array<string|int, mixed>>
Parameters
$xml : SimpleXMLElement
Return values
null|array<string|int, array<string|int, mixed>>

readThemes()

protected readThemes(SimpleXMLElement $xml) : null|array<string|int, array<string|int, mixed>>
Parameters
$xml : SimpleXMLElement
Return values
null|array<string|int, array<string|int, mixed>>

readUseLayerIDs()

protected readUseLayerIDs(SimpleXMLElement $xml) : bool
Parameters
$xml : SimpleXMLElement
Return values
bool

readWMSInformation()

protected readWMSInformation(SimpleXMLElement $qgsLoad) : array<string|int, mixed>
Parameters
$qgsLoad : SimpleXMLElement
Return values
array<string|int, mixed>

readXmlProject()

Read the qgis files.

protected readXmlProject(mixed $qgs_path) : mixed
Parameters
$qgs_path : mixed
Tags
throws
Exception

        
On this page

Search results